Beispiel #1
0
class SomeAuxService(ServiceBase):
    __aux__ = SyncAuxProc() # change this to SyncAuxProc to see the difference

    @srpc(Integer)
    def block(seconds):
        """Blocks the reactor for given number of seconds."""
        logging.info("Auxiliary sleeping for %d seconds." % (seconds * 2))
        time.sleep(seconds * 2)
Beispiel #2
0
        class AuxService(ServiceBase):
            __aux__ = SyncAuxProc()

            @srpc(String)
            def call(s):
                data.append(s)