Don't disable Nagle algorithm in HttpProtocol

0.18.3 evenlet by default disables Nagle algorithm for sockets using
http protocol [1]. It brought a regression to eventlet [2] and this
patch adds workaround that doesn't disable the algorithm.

[1] 40714b1ffa
[2] https://github.com/eventlet/eventlet/issues/301

Change-Id: I79a8583a5fe9812b6609bd4df5623f13c3b81df5
Closes-bug: 1546506
This commit is contained in:
Jakub Libosvar 2016-02-17 13:35:25 +00:00
parent 4bf2ebd9dd
commit 21d139d441
1 changed files with 6 additions and 0 deletions

View File

@ -373,6 +373,12 @@ class UnixDomainHTTPConnection(httplib.HTTPConnection):
class UnixDomainHttpProtocol(eventlet.wsgi.HttpProtocol):
# TODO(jlibosva): This is just a workaround not to set TCP_NODELAY on
# socket due to 40714b1ffadd47b315ca07f9b85009448f0fe63d evenlet change
# This should be removed once
# https://github.com/eventlet/eventlet/issues/301 is fixed
disable_nagle_algorithm = False
def __init__(self, request, client_address, server):
if client_address == '':
client_address = ('<local>', 0)