ROS2: non-reentrant callbacks, ignored callbacks
Hi, I use MultiThreadExecutor. I make a subscriber callback wait and it seems that while it happens any further calls of this exact callback are silently ignored until the first one returns? Is it really so? If yes, can it be changed?
It might be a fine default, but otherwise, even if a callback method returns shortly, such a behaviour may lead to occasional losses, glitches, whatever (scheduling grain, unexpectedly long preemption, high frequency dispatch, to name a few causes). Any mechanism of assuring a 100% reception?
I have seen a Python example with ReentrantCallbackGroup, but find . -iname "*Reentrant*"
on my copy of ROS2 source tree yields nothing. I have found rclcpp::callback_group::CallbackGroupType::Reentrant
, but I wonder, should each timer/subscriber have its own group like that in order to be independent, or can can several of them share such a group and still be mutually inclusive?