-
Notifications
You must be signed in to change notification settings - Fork 37
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 intra process tracepoint #30
Add intra process tracepoint #30
Conversation
Thanks for the PR @ymski! We'll start by reviewing the |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I fixed some mistakes and tried to make everything more consistent with the rest of the instrumentation.
It would be great if you could update the design document to add a new Flow description subsection about the intra-process instrumentation. For example, see the Message publishing section and the Subscriptions callback section. You could probably create a single section for intra process publishing and intra process callbacks with a single diagram. I think you already have some diagrams here, although they might need to be updated or adapted: ros2/rclcpp#2091 (comment).
Ideally, adding a Python test for this instrumentation would also be great, see here: https://github.com/ros2/ros2_tracing/tree/rolling/test_tracetools/test. However, I understand if you don't want to do it right away in this PR.
Also, after applying the suggestions, can you rebase on rolling
and fix the conflicts?
@christophebedard
I was also concerned about consistency with existing code. Thank you for fixing it.
I will create this one.
OK. If you have any concerns about the code I have created, please let me know.
|
There are some suggestions left. Also, if you look at the changes, this PR introduces a lot of changes that are already on |
b1c77fb
to
5907532
Compare
The errors pointed out have been corrected and the branch has been rebased. Please wait a little longer for the test code and documentation. |
Let me know if you need help with the tests or documentation. The Python tests in |
The pub-sub test in inter-process involves a single topic communication and checking the fields and order of the events. In the intra-process test case, Here is one question. Do you want to test against all recorded communications? Or is it sufficient to test on events excluding the |
Yeah, you can definitely exclude messages like parameter event and only validate the trace data resulting from the single topic. However, it might be a good idea to validate using more than 1 message. I think 2 messages would be fine (e.g., two consecutive messages on the same topic). The goal is to validate that you can indeed link the published message to the received message using the trace data, and that it works with more than just 1 random message. ( |
@ymski FYI the feature freeze for Iron is next week, on April 17th. Since it would be nice to get this in for the upcoming release, if you don't think you can finish writing the test in the next few days, just let me know and I can probably help out. |
@christophebedard I added documentation and tests.
There is one thing I would like to discuss. I am not sure where to put the explanation of the tracepoint for I added two tests as follows:
I have one question at the end. I think it's necessary to add a copyright notice to the new files I added this time, but is it okay if I put the name of the company I work for? |
14be1a8
to
0a70ca2
Compare
Thank you for the update and the new changes! I made some minor changes quickly (see below) and rebased on
Great! I made some minor fixes. The description in the "Intra-process callback" section wasn't quite right, but the sequence diagram is good.
You can just put it in the "IntraProcessBuffer creation" section.
Thank you, that looks good. I only made some very minor fixes.
Yes of course! That is how it usually works. One last thing popped into my mind: tracepoint names usually start with the name of the corresponding layer, e.g., |
Also, you should create a pull request to add a release note for Iron to mention the intra-process instrumentation. See for example this PR: ros2/ros2_documentation#3414 |
@christophebedard |
eec9240
to
118dc31
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
After some final minor fixes, this looks good to me! Thank you again so much for this new instrumentation!
I'll wait until someone else reviews the rclcpp
PR. Then I'll run CI and squash+merge eventually.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
just minor comment for design doc.
Signed-off-by: Kodai Yamasaki <114902604+ymski@users.noreply.github.com> Co-authored-by: Christophe Bedard <christophe.bedard@apex.ai>
2564702
to
944fbfb
Compare
CI for this PR and ros2/rclcpp#2091, testing |
Alright, CI looks good. I'll merge this and ask someone to merge the |
Hi, I'm a member of CARET development team. We would like to officially support some tracepoints added by caret in the rclcpp fork and LD_PRELOAD. I am thinking about adding tracepoints to evaluate the time from
publish
tosubscription callback
when using intra-process communication. The following link discusses this topic.action-ros-ci-repos-override: https://gist.githubusercontent.com/christophebedard/e6525cda7d3f79d419374eb833fa328d/raw/b241df85e837804804adb32907c3900ace45a205/ros2.repos