[Twisted-Python] Shutdown empty reactor?
Phillip J. Eby
pje at telecommunity.com
Fri Jul 11 10:18:42 MDT 2003
Hi. I've recently had an inquiry from a PEAK user who wants their reactor
loop to shut down automatically when there are no selectables or pending
calls. There doesn't appear to be any way to do this without breaking
reactor encapsulation, as there is no (for example) 'getSelectables()' method.
Is this something that could be added, or is there any general interest in
having idle reactors shut down? In principle, there is no way for a
running-on-empty reactor to do any further useful work, and no way for it
to be shut down, either. (If one is using threads, then there is always a
"waker" selectable present, which means that by definition a reactor using
threads is never "running on empty".)
Thanks.
More information about the Twisted-Python
mailing list