[Twisted-Python] transport.loseConnection problems

Alvin Delagon adelagon at gmail.com
Tue Mar 18 03:31:17 MDT 2008


I have a server application that do forced disconnects to clients on certain
conditions by using self.transport.loseConnection() method. On random cases
the method that I'm using fails to disconnect the client on the fly. The
socket connection that is supposed to be disconnected immediately get
disconnected at random times (10-30mins) with an error of:

*Connection closed: [Failure instance: Traceback (failure with no frames):
twisted.internet.error.ConnectionLost: Connection to the other side was lost
in a non-clean fashion.
*
Can anyone explain why is this happening? I checked the API docs of the
loseConnection() and it says there that:

*"**Note that if there is a registered producer on a transport it will not
be closed until the producer has been unregistered."*

I have no idea what is a producer. By the way I'm using
twisted.words.xmlstream that implements Protocol and epoll as my reactor.
Thanks in advance. :)

----
Alvin
-------------- next part --------------
An HTML attachment was scrubbed...
URL: </pipermail/twisted-python/attachments/20080318/38a2aeb4/attachment.html>


More information about the Twisted-Python mailing list