Hello guys, I am new to RPYC and I have the following problem and I don't 
know how to implement:

I have a server:

*class MyService(rpyc.Service):*
*    def exposed_DoSomethingThatTakesTime(self):*
*          ... code that takes time to execute...*
*          ...*
*          ...*
*          return 1   # return value so the client will know that the 
service didn't finish*

And I have the same client, running on multiple computers:


*proxy = rpyc.connect('TMD4701G', 18862, config={'allow_public_attrs': 
True})*

*if proxy.root.DoSomethingThatTakesTime == 1:*
*      print(Service finished running for this computer)*


Now my problem is, and what I wan't to achieve is that the if a *Client 
*already 
called the exposed Service, and the Service is running, the *second Client 
*which 
also calls the Service, should wait for the *first* one to finish --> 
Something like a task handling for the services exposed in the Server:


example:

*Client 1* calls *DoSomethingThatTakesTime()*                               
     *Server* executes for *Client1*
*Client 2* calls *DoSomethingThatTakesTime()*                               
     Waits for *Server* to finish executing to *Client1*
*Client 3* calls *DoSomethingThatTakesTime()*                               
     Waits for *Server* to finish executing to *Client1* and *Client2*

-- 

--- 
You received this message because you are subscribed to the Google Groups 
"rpyc" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to