8 Aug
2007
8 Aug
'07
3:58 a.m.
Hi all, I run a reactor in my thread, so I will get many connection by twisted, and I run another thread for write back data to any connection. But I've found the data is in buffer, not sent back immediately. I traced the twisted, found it blocked in class SelectReactor.doSelect(): while 1: try: r, w, ignored = _select(reads.keys(), writes.keys(), [], timeout) break ... ... #do sth when the reactor is bloce by _select(), then my another thread modified the *writes* dictionary, but _select could not know if writes.keys() is changed, so when the thread want to write something, reactor won't do response. so, the problem is above. Is there any idea for this? thanks~ -- eSX