Module: check_mk
Branch: master
Commit: 5eced094c9e7982c06c267159dbb4c199dae6b3e
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=5eced094c9e798…
Author: Lars Michelsen <lm(a)mathias-kettner.de>
Date: Fri Oct 26 09:47:31 2012 +0200
Max. number of queued connections on status sockets is configurable now
---
.bugs/869 | 8 ++++++++
ChangeLog | 1 +
mkeventd/bin/mkeventd | 4 ++--
mkeventd/web/plugins/wato/mkeventd.py | 16 ++++++++++++++++
4 files changed, 27 insertions(+), 2 deletions(-)
diff --git a/.bugs/869 b/.bugs/869
new file mode 100644
index 0000000..b3b84ec
--- /dev/null
+++ b/.bugs/869
@@ -0,0 +1,8 @@
+Title: number of rows in header is not updated during content reload
+Component: multisite
+State: open
+Date: 2012-10-26 09:34:50
+Targetversion: future
+Class: bug
+
+The "x rows" label does not seem to be updated after content reload of views.
diff --git a/ChangeLog b/ChangeLog
index 82270c7..2d3f64b 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -13,6 +13,7 @@
* New global option for enabling log entries for rule hits (debugging)
* New icon linking to event views for the event services
* check_mkevents outputs last worst line in service output
+ * Max. number of queued connections on status sockets is configurable now
Multisite:
* Enable automation login with _username= and _secret=, while
diff --git a/mkeventd/bin/mkeventd b/mkeventd/bin/mkeventd
index 9a63bfb..9027c47 100755
--- a/mkeventd/bin/mkeventd
+++ b/mkeventd/bin/mkeventd
@@ -1148,7 +1148,7 @@ class StatusServer:
os.remove(g_socket_path)
self._socket = socket.socket(socket.AF_UNIX, socket.SOCK_STREAM)
self._socket.bind(g_socket_path)
- self._socket.listen(10)
+ self._socket.listen(g_config['socket_queue_len'])
if g_config["remote_status"]:
try:
@@ -1161,7 +1161,7 @@ class StatusServer:
self._tcp_socket = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
self._tcp_socket.setsockopt(socket.SOL_SOCKET, socket.SO_REUSEADDR, 1)
self._tcp_socket.bind(("0.0.0.0", self._tcp_port))
- self._tcp_socket.listen(10)
+ self._tcp_socket.listen(g_config['socket_queue_len'])
log("Going to listen for status queries on TCP port %d" %
self._tcp_port)
except Exception, e:
if opt_debug:
diff --git a/mkeventd/web/plugins/wato/mkeventd.py
b/mkeventd/web/plugins/wato/mkeventd.py
index 1ec46b2..67b40c4 100644
--- a/mkeventd/web/plugins/wato/mkeventd.py
+++ b/mkeventd/web/plugins/wato/mkeventd.py
@@ -1248,6 +1248,22 @@ if mkeventd_enabled:
),
domain = "mkeventd")
+ register_configvar(group,
+ "socket_queue_len",
+ Integer(
+ title = _("Max. number of pending connections to the status
socket"),
+ help = _("When the Multisite GUI or the active check check_mkevents
connects "
+ "to the socket of the event daemon in order to retrieve
information "
+ "about current and historic events then its connection request
might "
+ "be queued before being processed. This defines the number of
unaccepted "
+ "connections to be queued before refusing new
connections."),
+ minvalue = 1,
+ default_value = 10,
+ label = "max.",
+ unit = "pending connections",
+ ),
+ domain = "mkeventd"
+ )
# Settings that should also be avaiable on distributed Sites that