Feature #2710

Allow synchronous RPC-calls to timeout

Added by A. Neumann over 7 years ago. Updated over 6 years ago.

Status:ResolvedStart date:02/09/2017
Priority:NormalDue date:
Assignee:J. Moringen% Done:


Target version:rsb-0.17


Currently, it is not possible to call an RPC function 'synchronously' with a timeout. This means all calls executed this way will block forever if the RPC call is not answered.

Since the synchronous call is more or less a wrapper for the async version, it would be useful to add the timeout keyword to call of RemoteMethod:

# patterns/__init__.py

class RemoteMethod (Method):
    def __call__(self, arg = None, timeout = 0):
         return self.async(arg).get(timeout)

This current workaround with server.method.async(arg).get(timeout) is a bit tedious.

Best regards!

Associated revisions

Revision cd7d7cf1
Added by J. Moringen over 6 years ago

RemoteMethod.__call__ accepts timeout parameter in rsb/patterns/__init__.py

fixes #2710

  • rsb/patterns/__init__.py (header): updated copyright
    (RemoteMethod.__call__): accept timeout parameter; pass to
    Future.get; updated documentation
  • test/patterns_test.py (RoundTripTest.testRoundTrip): tests
    synchronous call with timeout


#1 Updated by J. Moringen over 6 years ago

  • Assignee changed from J. Wienke to J. Moringen
  • Target version set to rsb-0.17

#2 Updated by J. Moringen over 6 years ago

  • Subject changed from Allow synchronous RSP-calls to timeout to Allow synchronous RPC-calls to timeout
  • Status changed from New to In Progress

#3 Updated by J. Moringen over 6 years ago

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

Also available in: Atom PDF