Hello,

I have a question about the "best practices" on making callbacks and making 
sure you don't hog the reactor.

So you pass a deferred to a client, who attaches a chain of callbacks that 
might probably do some CPU intensive stuff. How should one guard for that? The 
obvious solution to me for the server part would be to do

reactor.callLater(0, d.callback, arg)

insted of

d.callback(arg)


What about the client part? What would be the best way to have a chain of 
callbacks executed in such a way that the reactor isn't blocking during that 
time?

Thanks,
Orestis


_______________________________________________
Twisted-Python mailing list
Twisted-Python@twistedmatrix.com
http://twistedmatrix.com/cgi-bin/mailman/listinfo/twisted-python

Reply via email to