Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
slapos
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kwabena Antwi-Boasiako
slapos
Commits
5cf4cf1f
Commit
5cf4cf1f
authored
Mar 26, 2018
by
Julien Muchembled
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ERP5: enable TCP_NODELAY for ZEO
parent
fb5d114a
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
48 additions
and
1 deletion
+48
-1
component/egg-patch/ZEO4/TCP_NODELAY.patch
component/egg-patch/ZEO4/TCP_NODELAY.patch
+39
-0
software/neoppod/software-common.cfg
software/neoppod/software-common.cfg
+6
-1
software/neoppod/software-zodb5.cfg
software/neoppod/software-zodb5.cfg
+3
-0
No files found.
component/egg-patch/ZEO4/TCP_NODELAY.patch
0 → 100644
View file @
5cf4cf1f
From 8b31ccec54584a287cc61501948283d7d6ee7073 Mon Sep 17 00:00:00 2001
From: Julien Muchembled <jm@nexedi.com>
Date: Mon, 26 Mar 2018 20:39:07 +0200
Subject: [PATCH] Enable TCP_NODELAY for inet(6) sockets
See commit 3d886d426243655b9f5a2528636e42b5c7662c19.
---
src/ZEO/zrpc/client.py | 2 ++
src/ZEO/zrpc/server.py | 1 +
2 files changed, 3 insertions(+)
diff --git a/src/ZEO/zrpc/client.py b/src/ZEO/zrpc/client.py
index 32a7a877..669f5962 100644
--- a/src/ZEO/zrpc/client.py
+++ b/src/ZEO/zrpc/client.py
@@ -568,6 +568,8 @@
def __init__(self, domain, addr, mgr, client):
self.close()
return
self.sock.setblocking(0)
+ if domain in (socket.AF_INET, socket.AF_INET6):
+ self.sock.setsockopt(socket.IPPROTO_TCP, socket.TCP_NODELAY, 1)
self.state = "opened"
def connect_procedure(self):
diff --git a/src/ZEO/zrpc/server.py b/src/ZEO/zrpc/server.py
index b83cc004..af91e3e4 100644
--- a/src/ZEO/zrpc/server.py
+++ b/src/ZEO/zrpc/server.py
@@ -66,6 +66,7 @@
def _open_socket(self):
socket.IPPROTO_IPV6, socket.IPV6_V6ONLY, True)
else:
self.create_socket(socket.AF_INET, socket.SOCK_STREAM)
+ self.socket.setsockopt(socket.IPPROTO_TCP, socket.TCP_NODELAY, 1)
else:
self.create_socket(socket.AF_UNIX, socket.SOCK_STREAM)
self.set_reuse_addr()
--
2.14.1
software/neoppod/software-common.cfg
View file @
5cf4cf1f
...
@@ -48,6 +48,11 @@ eggs = neoppod[admin, ctl, master, storage-mysqldb]
...
@@ -48,6 +48,11 @@ eggs = neoppod[admin, ctl, master, storage-mysqldb]
ZODB
ZODB
zope.testing
zope.testing
zodbtools
zodbtools
patch-binary = ${patch:location}/bin/patch
ZEO-patch-options = -p1
ZEO-patches =
${:_profile_base_location_}/../../component/egg-patch/ZEO4/TCP_NODELAY.patch#b07288522d5c6857738240d948321df6
[slapos-deps-eggs]
[slapos-deps-eggs]
recipe = zc.recipe.egg
recipe = zc.recipe.egg
...
@@ -161,7 +166,7 @@ zodburi = 2.3.0
...
@@ -161,7 +166,7 @@ zodburi = 2.3.0
# Required by:
# Required by:
# zodburi==2.0
# zodburi==2.0
# ZEO 5 requires transaction >= 2
# ZEO 5 requires transaction >= 2
ZEO = 4.3.1
ZEO = 4.3.1
+SlapOSPatched001
# Required by:
# Required by:
# zodburi==2.0
# zodburi==2.0
...
...
software/neoppod/software-zodb5.cfg
View file @
5cf4cf1f
[buildout]
[buildout]
extends = software.cfg
extends = software.cfg
[neoppod]
ZEO-patches =
[versions]
[versions]
ZODB = 5.3.0
ZODB = 5.3.0
ZEO = 5.1.0
ZEO = 5.1.0
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment