rosbridge_suite icon indicating copy to clipboard operation
rosbridge_suite copied to clipboard

Subscriptions stop working after longer periods of time

Open lkeselman opened this issue 1 year ago • 4 comments

Description Periodically after relatively long periods of time, my Javascript client webpage no longer receives messages from subscriptions.

  • I can echo the messages using rostopic echo so they are in fact published.

  • When refreshing the webpage, the rosbridge logs indicate a successful subscription is made.

  • No messages from any subscriptions are received - so it's not just 1 broken one.

  • Services and parameters continue to work

  • Refreshing the webpage doesn't do anything

  • The only fix is to restart rosbridge server which works immediately.

  • Library Version: ros-noetic

  • ROS Version: Noetic

  • Platform / OS: Ubuntu 20

Thanks for the help, I'm not sure how to go about debugging this one.

lkeselman avatar Dec 16 '22 00:12 lkeselman

Can you reliably reproduce this? Did you find a solution? We are sporadically experiencing the same issue.

remod avatar Jul 14 '23 14:07 remod

Can you reliably reproduce this? Did you find a solution? We are sporadically experiencing the same issue.

Unfortunately not reliably. I did try to create a minimal scenario and stress test it but could not reproduce it after a couple weeks of continuous running.

My only solution has been to add some automation that allowed the JavaScript client to restart rosbridge when it notices the issue.

lkeselman avatar Jul 14 '23 15:07 lkeselman

Hi folks, not sure if it is relevant to you, but you might be interested in checking out foxglove_bridge which is more performant and more actively maintained. There is a JS/TS client library you can use to interact with it from a webpage (or just use Foxglove Studio which supports it natively).

jtbandes avatar Jul 14 '23 19:07 jtbandes

Thank you! I've had a first success with setting queue_length to 1 instead of 0 which is the default when a topic is created it roslibjs. This helped me to solve an "entangled connection status" between two clients: When one client disconnected (e.g. disable WiFi), the other client stopped receiving messages as well. Not exactly the issue here, but related.

remod avatar Jul 20 '23 07:07 remod