<div>Hello,</div><div><br></div>No, getTcpKeepAlive will only tell you if SO_KEEPALIVE is enabled. It&#39;s setTcpKeepAlive you want. If it&#39;s enabled, once the keepalive times out on a half-open scenario, the connectionLost method will be triggered. You can read the API docs here:<div>
<br></div><div><a href="http://twistedmatrix.com/documents/8.2.0/api/twisted.internet.tcp.Connection.html#getTcpKeepAlive">http://twistedmatrix.com/documents/8.2.0/api/twisted.internet.tcp.Connection.html#getTcpKeepAlive</a></div>
<div><a href="http://twistedmatrix.com/documents/8.2.0/api/twisted.internet.tcp.Connection.html#setTcpKeepAlive">http://twistedmatrix.com/documents/8.2.0/api/twisted.internet.tcp.Connection.html#setTcpKeepAlive</a></div><div>
<br></div><div>Best Regards,</div><div>Alvin</div><div><br><div><br><div class="gmail_quote">On Wed, Feb 17, 2010 at 1:06 AM, gary clark <span dir="ltr">&lt;<a href="mailto:burslem2001@yahoo.com">burslem2001@yahoo.com</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">I have to poll at the twisted server &quot;getTcpKeepAlive&quot; for the state of the keep alive.<br>
<br>
<br>
Thanks,<br>
Garyc<br>
<br>
--- On Tue, 2/16/10, gary clark &lt;<a href="mailto:burslem2001@yahoo.com">burslem2001@yahoo.com</a>&gt; wrote:<br>
<br>
&gt; From: gary clark &lt;<a href="mailto:burslem2001@yahoo.com">burslem2001@yahoo.com</a>&gt;<br>
&gt; Subject: [Twisted-Python] Pulling the ethernet cable out<br>
<div class="im">&gt; To: &quot;Twisted general discussion&quot; &lt;<a href="mailto:twisted-python@twistedmatrix.com">twisted-python@twistedmatrix.com</a>&gt;<br>
</div>&gt; Date: Tuesday, February 16, 2010, 10:15 AM<br>
<div><div></div><div class="h5">&gt; Hello,<br>
&gt;<br>
&gt; I&#39;m tested my client server model. The server being a<br>
&gt; twisted server.<br>
&gt; I am using the class NetstringReceiver. When I close down<br>
&gt; the client the appropriate call to close the connection is<br>
&gt; made &quot;connectionLost&quot;. However when I just pull the client<br>
&gt; connection cable from the network. I would expect the call<br>
&gt; to be made to indicate a connection is lost at the twisted<br>
&gt; server. I dont see this.<br>
&gt;<br>
&gt; I am going through a local hub and not sure what at the<br>
&gt; moment to think of this. I am using ssl to communicate.<br>
&gt;<br>
&gt; If somebody could shed some light on this that would be<br>
&gt; great.<br>
&gt;<br>
&gt; Thanks,<br>
&gt; Garyc<br>
&gt;<br>
&gt;<br>
&gt;<br>
&gt;<br>
&gt; _______________________________________________<br>
&gt; Twisted-Python mailing list<br>
&gt; <a href="mailto:Twisted-Python@twistedmatrix.com">Twisted-Python@twistedmatrix.com</a><br>
&gt; <a href="http://twistedmatrix.com/cgi-bin/mailman/listinfo/twisted-python" target="_blank">http://twistedmatrix.com/cgi-bin/mailman/listinfo/twisted-python</a><br>
&gt;<br>
<br>
<br>
_______________________________________________<br>
Twisted-Python mailing list<br>
<a href="mailto:Twisted-Python@twistedmatrix.com">Twisted-Python@twistedmatrix.com</a><br>
<a href="http://twistedmatrix.com/cgi-bin/mailman/listinfo/twisted-python" target="_blank">http://twistedmatrix.com/cgi-bin/mailman/listinfo/twisted-python</a><br>
</div></div></blockquote></div><br><br clear="all"><br>-- <br><a href="http://www.alvinatorsplayground.blogspot.com/">http://www.alvinatorsplayground.blogspot.com/</a><br>
</div></div>