diff options
author | Michael Lumish <mlumish@google.com> | 2016-10-27 17:35:19 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2016-10-27 17:35:19 -0700 |
commit | b78062dc0d646ff8e25b2ab714cfa578da5392da (patch) | |
tree | 90433191b216c4902b3f4b2f14e967e8a5fd4e95 | |
parent | c293f7215fa77e2d1132a7bcc0e0610c8d054044 (diff) | |
parent | 04d2829fe60adbcead1efe1ff8b5da70898329d0 (diff) |
Merge pull request #8544 from murgatroid99/node_perf_investigation
Disable Nagle's algorithm in libuv endpoints
-rw-r--r-- | src/core/lib/iomgr/tcp_uv.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/core/lib/iomgr/tcp_uv.c b/src/core/lib/iomgr/tcp_uv.c index 05d6eeb240..3860fe3e9b 100644 --- a/src/core/lib/iomgr/tcp_uv.c +++ b/src/core/lib/iomgr/tcp_uv.c @@ -315,6 +315,9 @@ grpc_endpoint *grpc_tcp_create(uv_tcp_t *handle, char *peer_string) { gpr_log(GPR_DEBUG, "Creating TCP endpoint %p", tcp); } + /* Disable Nagle's Algorithm */ + uv_tcp_nodelay(handle, 1); + memset(tcp, 0, sizeof(grpc_tcp)); tcp->base.vtable = &vtable; tcp->handle = handle; |