Bug #1937

Connection refused issues

Added by J. Wienke about 7 years ago. Updated about 6 years ago.

Status:ResolvedStart date:08/13/2014
Priority:HighDue date:
Assignee:J. Moringen% Done:

100%

Category:Python Client API
Target version:Robotics Service Bus - rsb-0.13

Description

It seems the waiting time for the bag binary is too low when using the python API. I constantly receive connect refused errors.

I think a good solution for making this reliable is to let the binary output a ready-message to the stdout one the RSB communication is available. The python library can wait for this message before establishing the connection.

Associated revisions

Revision 6ce7bc1f
Added by J. Wienke about 6 years ago

Reliably synchronize with called bag process

Use the newly implemented features of the rsbag binary to synchronize the
creation of the socket server as well as the required RSB participants to
control the bag process so that the python client code exactly knows from the
bag output when a connection can be established.

This change requires a new version of the rsbag binary. Older version will now
fail the creation of a bag instance.

fixes #1937

Revision a522a568
Added by J. Moringen about 6 years ago

Mention fixed rsbag-python -> rsbag play connection in news.rst

refs #1937

  • news.rst (RSBag 0.13): mention fixed hacks and races in connection
    from rsbag-python client API library to rsbag play server

History

#1 Updated by J. Moringen about 7 years ago

It seems the waiting time for the bag binary is too low when using the python API. I constantly receive connect refused errors.

Does every attempt result in that error or does it only happen sometimes?

In the latter case, the general is problem is that the rsbag binary provides the server for the communication. Otherwise we could use an event-based protocol to indicate readiness. As a consequence, maybe the client should act as server. Then the rsbag binary could send a readiness indication event immediately after connecting.

#2 Updated by J. Wienke about 7 years ago

Happens every second time or so.

Both solutions should work. I am not sure about the performance of the python server since for batch processing getting the maximum speed should be desirable.

#3 Updated by J. Moringen about 7 years ago

  • Subject changed from Connection refues issues to Connection refused issues

#4 Updated by J. Wienke about 6 years ago

I am experiencing this again. Locally, I can increase the timeout, but having a more reliable solution would be much better.

#5 Updated by J. Moringen about 6 years ago

  • Priority changed from Normal to High

Other user experience these problems as well.

@Johannes: do you have time to try and come up with a proper solution?

#6 Updated by J. Wienke about 6 years ago

  • Status changed from New to In Progress
  • Target version set to rsb-0.13
  • % Done changed from 0 to 60

I have commits to fix the issue as discussed orally. Once the bag binary is adapted in the master version, I can push these changes.

#7 Updated by J. Wienke about 6 years ago

  • Status changed from In Progress to Resolved
  • % Done changed from 60 to 100

Also available in: Atom PDF