Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add tracing instrumentation using tracetools #294

Open
wants to merge 1 commit into
base: rolling
Choose a base branch
from

Conversation

christophebedard
Copy link
Member

@christophebedard christophebedard commented Oct 10, 2024

With this instrumentation, rmw_zenoh_cpp is supported out-of-the-box by tools that process ROS 2 trace data, such as Eclipse Trace Compass.

It's pretty straightforward except for a few things:

  1. Getting the rmw_publisher_t * for the rmw_publish tracepoint
    • Add it to PublisherData.
  2. Getting the source timestamp for the rmw_publish tracepoint
    • Getting the source timestamp of a message being published is needed for tracking messages from publisher to subscription.
    • Since Add timestamp to rmw_publish tracepoint ros2_tracing#74, we're getting the source timestamp for a published message from rmw. This means we don't need to instrument the underlying middleware itself, which we used to have to do.
    • I modified create_map_and_set_sequence_num() to be able to extract the source timestamp.
  3. Getting the/a subscription rmw GID for the rmw_subscription_init tracepoint
    • See the comment before the tracepoint.

I'm open to suggestions.

@christophebedard
Copy link
Member Author

christophebedard commented Oct 10, 2024

Oh, looks like this repo aims to support Iron, Jazzy, and Rolling on the rolling branch. I will deal with that after a first round of review.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant