Provide separate arguments for publish and subscribe topic globs.
Currently you can pass the "--topics_globs" which is then provided for both the Publish and Subsrciber glob.
https://github.com/RobotWebTools/rosbridge_suite/blob/c1bfc2ff451069b2a40544581e2910d20efc3f62/rosbridge_server/scripts/rosbridge_websocket.py#L274
https://github.com/RobotWebTools/rosbridge_suite/blob/c1bfc2ff451069b2a40544581e2910d20efc3f62/rosbridge_server/scripts/rosbridge_websocket.py#L323 https://github.com/RobotWebTools/rosbridge_suite/blob/c1bfc2ff451069b2a40544581e2910d20efc3f62/rosbridge_server/scripts/rosbridge_websocket.py#L325
And the same for the "--services_glob" which is provided for both advertise and call service globs.
The idea is that this should provide a fine-grained control whether it is possible to publish or suscribe to a certain topic.
This is a good idea, if you're willing to help implement it.
Also semi-related, I notice there is no actions_glob either. Guess I didn't add that when I made the action support feature 😬
For sure! I will make a PR with it!
The new args could be:
- subscribe_topics_glob
- publish_topics_glob (for publishing and advertising)
- call_services_glob
- advertise_services_glob (advertising, unadvertising)
- client_action_glob
- advertise_action_glob
Do you want to keep the topics_glob and services_glob arguments, which would not be breaking compatibility. And providing value to the topics_glob arg would allow for both publishing and subscribing.
Hmm... probably the most "correct" thing to do is whatever doesn't break compatibility. But I also don't think having a redundant interface is desired.
I would say just replace it, so long as all the defaults are the same as before.
But maybe others have more opinions?
I would like to +1 this feature request. I have implemented a local change that allows some of this. I agree a redundant interface isn't great but it will break backwards compatibility. Maybe keep the redundant interface for existing versions and remove it on new ROS releases going forwards?