Draft: Add delayed modes for recorder and replay services#2330
Draft
carlos-apex wants to merge 4 commits intoros2:rollingfrom
Draft
Draft: Add delayed modes for recorder and replay services#2330carlos-apex wants to merge 4 commits intoros2:rollingfrom
carlos-apex wants to merge 4 commits intoros2:rollingfrom
Conversation
ddbbdc5 to
d1a8192
Compare
29de30e to
3fcd8e8
Compare
Adds a timestamp member for the following services: - rosbag2_interfaces/srv/Record.srv - rosbag2_interfaces/srv/Resume.srv - rosbag2_interfaces/srv/SplitBagfile.srv A helper RecorderDelayedActionRunner is implemented to runs delayed tasks. It is implemented as a worker thread and time-based priority queue containing actions (callbacks) Signed-off-by: Carlos San Vicente <carlos.sanvicente@apex.ai>
…to use it in Player - Rename files and RecorderDelayedActionTaskRunner, RecorderDelayedActionTaskRunnerImpl classes to the DelayedActionTaskRunner - Minor fixes such as updating error log messages and addressing race condition for the ScheduledActionTask::sequence_id Signed-off-by: Carlos San Vicente <carlos.sanvicente@apex.ai>
Adds the following split modes: - node_time: timer-based splitting (already implemented) - publish_time: message publish (or send) time based splitting - receive_time: message receive (or log) time based splitting Signed-off-by: Carlos San Vicente <carlos.sanvicente@apex.ai>
3fcd8e8 to
9f534cb
Compare
Contributor
|
@carlos-apex Can you please take a look at the test failure? /tmp/ws/src/rosbag2/rosbag2_transport/test/rosbag2_transport/test_play.cpp:471
Value of: player->wait_for_playback_to_start(10s)
Actual: false
Expected: trueIt seems relevant to the changes. |
Author
|
@MichaelOrlov I would say the failure is unrelated to the changes, the player behavior is not changed in this PR. I tried to reproduce the failure locally and it only failed after many many repetitions. |
Contributor
Okay, good, I will try to reproduce it to see what it could cause the failure. Meanwhile, can you please sign your commits? Please see https://github.com/ros2/rosbag2/pull/2330/checks?check_run_id=63499982511 fro details. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
node_time,publish_time,receive_time) with tracking topic support and pending split semantics.Is this user-facing behavior change?
Yes. Service behavior and request/response fields changed.
Recorder services
rosbag2_interfaces/srv/SplitBagfilenode_time,publish_time,receive_time.split_timenow supports scheduling; past/zero executes immediately.tracking_topic_nameoptionally scopes publish/receive‑time evaluation.return_code/error_string(e.g., not recording, invalid mode/topic, split failed).rosbag2_interfaces/srv/Recordstart_timeallows scheduling a future start; past/zero starts immediately.return_code/error_stringon failure.rosbag2_interfaces/srv/Resumeresume_timeallows scheduling a future resume; past/zero resumes immediately.Player services
rosbag2_interfaces/srv/Playstart_timeallows scheduling playback in the future; past/zero starts immediately.return_code/error_stringwith explicit enum values.rosbag2_interfaces/srv/Resumeresume_timeallows scheduling a future resume; past/zero resumes immediately.Did you use Generative AI?
Yes. OpenAI Codex (GPT‑5) was used to adapt patches from internal changes.
Additional Information