Lately there came some new examples on how to use ros2 publisher/subscriptions with c++.
They suggest inheriting from a node and implementing your publisher in this inherited class. The reason given in the comments is:
We do not recommend this style anymore, because composition of multiple nodes in the same executable is not possible
I’ve read quite a lot of the rclcpp code and as far as I can see there is no reason why I couldn’t have multiple nodes with the “classic” version. Could you explain this to me?