<html><body><div style="color:#000; background-color:#fff; font-family:times new roman, new york, times, serif;font-size:12pt"><div><span>Let me think about it.</span></div><div><br></div>  <div style="font-family: 'times new roman', 'new york', times, serif; font-size: 12pt;"> <div style="font-family: 'times new roman', 'new york', times, serif; font-size: 12pt;"> <div dir="ltr"> <font size="2" face="Arial"> <hr size="1">  <b><span style="font-weight:bold;">From:</span></b> Glyph &lt;glyph@twistedmatrix.com&gt;<br> <b><span style="font-weight: bold;">To:</span></b> A Desai &lt;ardesai@yahoo.com&gt; <br><b><span style="font-weight: bold;">Cc:</span></b> Twisted Web World &lt;twisted-web@twistedmatrix.com&gt; <br> <b><span style="font-weight: bold;">Sent:</span></b> Wednesday, March 13, 2013 11:33 AM<br> <b><span style="font-weight: bold;">Subject:</span></b> Re: [Twisted-web] Setting of TCP Receive buffer size and Flow Control in producer/consumer<br>
 </font> </div> <br><div id="yiv681358593"><div><div>On Mar 12, 2013, at 9:04 PM, A Desai &lt;<a rel="nofollow" ymailto="mailto:ardesai@yahoo.com" target="_blank" href="mailto:ardesai@yahoo.com">ardesai@yahoo.com</a>&gt; wrote:</div><div><br><blockquote type="cite"><div style="background-color: rgb(255, 255, 255); font-family: 'times new roman', 'new york', times, serif; font-size: 12pt;">Using the protocol's transport object, I can fetch the SO_RCVBUF value on the 'accepted' connection and even set the SO_SNDBUF value.&nbsp; However, since TCP Window scaling is enabled by default, it is my understanding that the SO_RCVBUF has to be set before the listen() call is invoked.&nbsp; The .tac file passes the TCPServer object to application/service framework, which in turn calls the listener.&nbsp; So I am wondering if I have to derive a subclass of TCPServer and somehow set the SO_RCVBUF value before the application framework invokes listen();&nbsp; i.e.
 drill down to the Port
 object where it calls createInternetSocket()?<br></div></blockquote><br></div><div>You'd need to actually subclass tcp.Server, an implementation mechanism that we would really like to deprecate :).</div><div><br></div><div>Really, the right way to do this is to contribute a fix to the ticket I linked, and do it directly next to the listen() call within Twisted :).</div><div><br></div><div>-glyph</div><div><br></div></div></div><br><br> </div> </div>  </div></body></html>