ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
0

What is a "ROS2 Process" with regards to DDS Participants?

asked 2022-11-24 17:37:14 -0500

bchurch8 gravatar image

On "The ROS_DOMAIN_ID" page of the ROS2 Foxy docs, it says the following:

"For each ROS 2 process running on a computer, one DDS “participant” is created. Since each DDS participant takes up two ports on the computer, running more than 120 ROS 2 processes on one computer may spill over into other domain IDs or the ephemeral ports."

What exactly is considered a ROS 2 process? Is it every node? Every sub/pub? Or each time you call rclcpp::init()?

I have an application that uses ROS for some features and looking into using different domain IDs in each instance of the app to ensure that the two instances do not interfere. However, I would like to know if there is any possibility of the two instances' ports overlapping.

edit retag flag offensive close merge delete

1 Answer

Sort by » oldest newest most voted
1

answered 2022-11-25 18:43:52 -0500

A process can be a node, if launched as independent systems, or as a collection of nodes if using manual or dynamic node composition. Its not each sub/pub. The context contains the DDS participant which is a global for the process so any nodes in a given process share it (by default, I believe you may override if you choose).

edit flag offensive delete link more

Comments

Thanks for the answer!

Just to clarify my understanding, if I have an application that calls rclcpp::init() once on startup, and creates several nodes as the app runs, this counts as one DDS participant since they all belong to the global context?

bchurch8 gravatar image bchurch8  ( 2022-11-25 18:51:37 -0500 )edit

That is Correct!

stevemacenski gravatar image stevemacenski  ( 2022-11-28 12:07:18 -0500 )edit

Question Tools

2 followers

Stats

Asked: 2022-11-24 17:37:14 -0500

Seen: 198 times

Last updated: Nov 25 '22