Galactic: for_each_callback_group backport#1741
Conversation
clalancette
left a comment
There was a problem hiding this comment.
I left a preliminary round of review. I would also suggest rebasing all of the individual commits into a single commit, adding a useful commit message, and signing it properly (which will make the DCO bot happy).
f779270 to
6971111
Compare
…se.hpp, updated the for_each_callback_group wrapper method in lifecycle_node and node.cpp, added a thread safe global map of mutexes in node_base. Implemented the suggestions in preliminary review. Signed-off-by: Aditya Pande <aditya050995@gmail.com>
6971111 to
2fbc5ce
Compare
|
Changes:
TODO
|
…ixes Signed-off-by: Aditya Pande <aditya050995@gmail.com>
Signed-off-by: Aditya Pande <aditya050995@gmail.com>
…_cb_group Signed-off-by: Aditya Pande <aditya050995@gmail.com>
…each_cb_group Signed-off-by: Aditya Pande <aditya050995@gmail.com>
ivanpauno
left a comment
There was a problem hiding this comment.
I have a bunch of questions/comments.
58174d0 to
e6733bf
Compare
Signed-off-by: Aditya Pande <aditya050995@gmail.com>
Signed-off-by: Aditya Pande <aditya050995@gmail.com>
…ointer cast Signed-off-by: Aditya Pande <aditya050995@gmail.com>
clalancette
left a comment
There was a problem hiding this comment.
Overall, I think this is getting close. I've left a few more things to think about.
…_mutexes Signed-off-by: Aditya Pande <aditya050995@gmail.com>
clalancette
left a comment
There was a problem hiding this comment.
I have a bunch of nits inline. Once those are all fixed, I think this is good to go from my perspective, though I'd like to get @ivanpauno 's final thoughts before we run CI on this.
Signed-off-by: Aditya Pande <aditya050995@gmail.com>
clalancette
left a comment
There was a problem hiding this comment.
This looks good to me with three things:
- Green CI.
- Running
abi-compliance-checkerbefore and after this PR to make sure we aren't changing ABI. - An approval from @ivanpauno and @cottsay
cottsay
left a comment
There was a problem hiding this comment.
Looks good from an ABI compatibility perspective. I had a couple of other comments inline, but nothing critical.
Signed-off-by: Aditya Pande <aditya050995@gmail.com>
Signed-off-by: Aditya Pande <aditya050995@gmail.com>
|
@cottsay How should we handle the unstable windows CI ? The failures are in |
If you're confident that they aren't a regression caused by this PR, then I think it's OK to ignore the test failures. It might be worth triggering a baseline build to be sure, though. |
I can't tell if those failures are related or not, +1 to compare with a baseline build. |
So this CI was run by changing the branch of rclcpp to |
LGTM! |
Added thread safe for_each_callback_group method Signed-off-by: Aditya Pande <aditya050995@gmail.com>
…ick-1741 Galactic: for_each_callback_group backport (ros2#1741)

This PR aims takle ros-simulation/gazebo_ros_pkgs#1296 by backporting #1723 to galactic without breaking ABI. To do this, I added a new non virtual function in node_base class, and added static members to it to keep track of a global map of mutexes. This map stores the mutexes for each node_base instance. However, while using the new
for_each_callback_groupmethod, the pointer of typeNodeBaseInterfacehas to be typecasted toNodeBase. The global map of mutexes is written as a separate class and access to it is protected by an internal mutex.TODO
static_executor_entities_collector