Skip to content

Snapshot mode throws away transient local topics when the buffer is full (in other words, tf_static is lost) #1886

@doisyg

Description

@doisyg

Description

Not completely a bug, but due to the current design of MessageCacheCircularBuffer, all incoming topics are using the same buffer regardless of their QoS.
Hence, when the buffer is full, when we start erasing older messages, we could be erasing messages with transient local that would have been useful to keep.
An example is the /tf_static topic, that will be typically received by the snapshot bag recorder at the very beginning and hence throw away as soon as the buffer is full. And this topic will be missing when replaying the bag.

Expected Behavior

Support the /tf_static use case, i.e. save and replay /tf_static properly (and other transient local messages)

Actual Behavior

Cannot replay /tf_static

To Reproduce

  1. Start a snapshot bag record with transient local topics, like /tf_static.
  2. Wait long enough for the buffer to be full.
  3. Trigger the snapshot.
  4. Stop everything and try to replay the bag. /tf_static will be missing.

System (please complete the following information)

  • Same behavior under Iron and Jazzy

Additional context

I will push a draft PR to discuss how to fix this asap.
Edit: here #1887

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions