ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange |
1 | initial version |
To answer part of the question, a rosmaster should easily function with hundreds of nodes. It does begin to perform worse if the nodes have bad connectivity as the master is required to contact nodes with updates.
The exceptions appear to be a red-herring. Because your node publishes and subscribes to the same topic, there's basically a race condition where the master informs the node that the subscriptions for a topic it subscribes to has changed -- the exception is printed just in case, but I don't think it's at the heart of the problem.
I attempted to write a test program that replicated your test node, but couldn't elicit the 100% CPU usage after 30 minutes of repeated running. I would need your actual test code to proceed any further.
I made a minor tweak to the rosmaster code as I look back over it. I don't think it fixes your issue, but you're welcome to try:
https://code.ros.org/trac/ros/changeset/16264