Permalink
Browse files

Turn on TCP_NODELAY to address the following performance issue:

The combination of Negel algorithm at client side and delayed ack
at server side causes large latencies for sending small packets.
  • Loading branch information...
1 parent 72ad61c commit 193c594af4d9f862ee2a5fca4753b332112f1f7d @tatsuya6502 tatsuya6502 committed with norton Oct 27, 2011
Showing with 1 addition and 0 deletions.
  1. +1 −0 priv/python/pyebf.py
View
@@ -21,6 +21,7 @@ def __init__(self,host=socket.gethostname(), port=7580):
self.SocketError = SocketError()
try:
self.sock = socket.socket(socket.AF_INET,socket.SOCK_STREAM)
+ self.sock.setsockopt(socket.IPPROTO_TCP, socket.TCP_NODELAY, 1)
except socket.error, msg:
raise SocketError, 'Error in Socket Object Creation!!'

0 comments on commit 193c594

Please sign in to comment.