Module: check_mk
Branch: master
Commit: 40ca710aabe8166472846fa28555521a2c258d33
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=40ca710aabe816…
Author: Lars Michelsen <lm(a)mathias-kettner.de>
Date: Fri Sep 7 14:06:51 2018 +0200
6553 FIX Fix "Error running .../MKEVENTD 'set' 'on'" error in case of config errors during update
This error message could occur during the "omd update" procedure when the configuration is
detected to have some issues. This message is now being suppressed while the configuration
error is still be printed to the user.
Change-Id: I1b23ab20a1c94ff8979cdbc307b7ee85e141ea40
---
.werks/6553 | 13 +++++++++++++
omd/packages/check_mk/MKEVENTD.hook | 4 +++-
2 files changed, 16 insertions(+), 1 deletion(-)
diff --git a/.werks/6553 b/.werks/6553
new file mode 100644
index 0000000..520ac2a
--- /dev/null
+++ b/.werks/6553
@@ -0,0 +1,13 @@
+Title: Fix "Error running .../MKEVENTD 'set' 'on'" error in case of config errors during update
+Level: 1
+Component: core
+Class: fix
+Compatible: compat
+Edition: cre
+State: unknown
+Version: 1.6.0i1
+Date: 1536321907
+
+This error message could occur during the "omd update" procedure when the configuration is
+detected to have some issues. This message is now being suppressed while the configuration
+error is still be printed to the user.
diff --git a/omd/packages/check_mk/MKEVENTD.hook b/omd/packages/check_mk/MKEVENTD.hook
index fbc4521..4f5e759 100755
--- a/omd/packages/check_mk/MKEVENTD.hook
+++ b/omd/packages/check_mk/MKEVENTD.hook
@@ -26,6 +26,8 @@ case "$1" in
> $OMD_ROOT/etc/check_mk/multisite.d/mkeventd.mk
echo -e "# Set by OMD hook MKEVENTD, do not change here!\nmkeventd_enabled = $enabled" \
> $OMD_ROOT/etc/check_mk/conf.d/mkeventd.mk
- cmk -U >/dev/null 2>&1
+ # Try to update the core config to make the Microcore/Livestatus know whether or not the
+ # Event Console is enabled. Totally ignore configuration validation errors here. Be silent.
+ cmk -U >/dev/null 2>&1 || true
;;
esac
Module: check_mk
Branch: master
Commit: d70c6c1cb41e6da793fa04a3ed814a1225e96ad6
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=d70c6c1cb41e6d…
Author: Lars Michelsen <lm(a)mathias-kettner.de>
Date: Mon Sep 10 07:51:28 2018 +0200
6556 Tactical overview and host matrix snapins can be customized
Based on the changes of werk #6555 the Tactical overview snapin can now be
configured to show statistics about custom sets of hosts / services / events.
It can also be configured to show or not show stale objects and failed
notifications.
It is now also possible to create custom copies of the host matrix snapin to
set arbitrary host filters for them which make them able to visualize different
collections of hosts.
Change-Id: I5dd0225339b7d074c7ae7ea7bc67260cd4e94be7
---
.werks/6556 | 17 +++++++++++++++++
1 file changed, 17 insertions(+)
diff --git a/.werks/6556 b/.werks/6556
new file mode 100644
index 0000000..d5b5d7d
--- /dev/null
+++ b/.werks/6556
@@ -0,0 +1,17 @@
+Title: Tactical overview and host matrix snapins can be customized
+Level: 2
+Component: multisite
+Compatible: compat
+Edition: cre
+Version: 1.6.0i1
+Date: 1536558591
+Class: feature
+
+Based on the changes of werk #6555 the Tactical overview snapin can now be
+configured to show statistics about custom sets of hosts / services / events.
+It can also be configured to show or not show stale objects and failed
+notifications.
+
+It is now also possible to create custom copies of the host matrix snapin to
+set arbitrary host filters for them which make them able to visualize different
+collections of hosts.
Module: check_mk
Branch: master
Commit: 3325b759a6bce01daa7839a4ca7e5f68ee15507d
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=3325b759a6bce0…
Author: Lars Michelsen <lm(a)mathias-kettner.de>
Date: Mon Sep 10 07:49:49 2018 +0200
6555 Snapins can now be customized
It is now possible to create customized copies of the default sidebar snapins.
To make this possible the snapin developer needs to prepare the snapin for this
feature. The developer needs to specify which parameters can be customized by
the users and make the snapin use the user configuration.
The user can then navigate to "Add snapin page > Custom snapins" to manage his
custom snapins. When editing such a custom snapin the attributes of the snapin
can be edited. The snapins can be shared with other users of the installation.
The sharing logic is equal to the bookmarks, reports and so on.
Once a custom snapin has been created, the user can choose the new dashlet from
the "add snapin page" for adding it to his dashboard.
Change-Id: If0966d9697102f8a1f883bd18908f5ab633a9c6c
---
.werks/6555 | 22 ++++++++++++++++++++++
1 file changed, 22 insertions(+)
diff --git a/.werks/6555 b/.werks/6555
new file mode 100644
index 0000000..d74b233
--- /dev/null
+++ b/.werks/6555
@@ -0,0 +1,22 @@
+Title: Snapins can now be customized
+Level: 2
+Component: multisite
+Compatible: compat
+Edition: cre
+Version: 1.6.0i1
+Date: 1536558291
+Class: feature
+
+It is now possible to create customized copies of the default sidebar snapins.
+
+To make this possible the snapin developer needs to prepare the snapin for this
+feature. The developer needs to specify which parameters can be customized by
+the users and make the snapin use the user configuration.
+
+The user can then navigate to "Add snapin page > Custom snapins" to manage his
+custom snapins. When editing such a custom snapin the attributes of the snapin
+can be edited. The snapins can be shared with other users of the installation.
+The sharing logic is equal to the bookmarks, reports and so on.
+
+Once a custom snapin has been created, the user can choose the new dashlet from
+the "add snapin page" for adding it to his dashboard.
Module: check_mk
Branch: master
Commit: 11e1aeed71e5c3efd678af51f6d79c56bef432c0
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=11e1aeed71e5c3…
Author: Lars Michelsen <lm(a)mathias-kettner.de>
Date: Fri Sep 7 17:34:52 2018 +0200
Fixed merge issues and other problems in recent commits
Change-Id: I33baf1dfbd8fb3f2298cc152083f77b54f3c749d
---
cmk/gui/plugins/sidebar/tactical_overview.py | 8 ++++----
cmk/gui/sidebar.py | 12 ++----------
2 files changed, 6 insertions(+), 14 deletions(-)
diff --git a/cmk/gui/plugins/sidebar/tactical_overview.py b/cmk/gui/plugins/sidebar/tactical_overview.py
index 729a09b..328cd30 100644
--- a/cmk/gui/plugins/sidebar/tactical_overview.py
+++ b/cmk/gui/plugins/sidebar/tactical_overview.py
@@ -155,14 +155,14 @@ class TacticalOverviewSnapin(CustomizableSidebarSnapin):
def _show_rows(self):
rows = self._get_rows()
- if bool(r for r in rows if r.stats is None):
+ if bool([r for r in rows if r.stats is None]):
html.center(_("No data from any site"))
return
html.open_table(class_=["content_center", "tacticaloverview"], cellspacing=2, cellpadding=0, border=0)
show_stales = self.parameters()["show_stale"] and config.user.may("general.see_stales_in_tactical_overview")
- has_stale_objects = bool(r for r in rows if r.what != "events" and r.stats[-1])
+ has_stale_objects = bool([r for r in rows if r.what != "events" and r.stats[-1]])
for row in rows:
if row.what == "events":
@@ -423,7 +423,7 @@ class TacticalOverviewSnapin(CustomizableSidebarSnapin):
if not self.parameters()["show_failed_notifications"]:
return
- failed_notifications = self._get_failed_notification_stats()[0]
+ failed_notifications = self._get_failed_notification_stats()
if not failed_notifications:
return
@@ -445,7 +445,7 @@ class TacticalOverviewSnapin(CustomizableSidebarSnapin):
return notifications.load_failed_notifications(
after=notifications.acknowledged_time(),
stat_only=True,
- )
+ )[0]
except livestatus.MKLivestatusNotFoundError:
return None
diff --git a/cmk/gui/sidebar.py b/cmk/gui/sidebar.py
index c075bf1..dd23e93 100644
--- a/cmk/gui/sidebar.py
+++ b/cmk/gui/sidebar.py
@@ -428,7 +428,7 @@ class SidebarRenderer(object):
html.open_div(id_="snapin_container_%s" % name, class_="snapin")
self._render_snapin_styles(snapin_instance)
# When not permitted to open/close snapins, the snapins are always opened
- if snapin.visibility == SnapinVisibility.OPEN or not config.user.may("general.configure_sidebar"):
+ if snapin.visible == SnapinVisibility.OPEN or not config.user.may("general.configure_sidebar"):
style = None
minimaxi = "mini"
else:
@@ -445,15 +445,7 @@ class SidebarRenderer(object):
"onmousedown" : "snapinStartDrag(event)",
"onmouseup" : "snapinStopDrag(event)"}
- html.open_div(class_=["head", snapin.visibility.value], **head_actions)
-
- if config.user.may("general.configure_sidebar"):
- # Icon for mini/maximizing
- html.open_div(class_="minisnapin")
- html.icon_button(url=None, help=_("Toggle this snapin"), icon="%ssnapin" % minimaxi,
- onclick="toggle_sidebar_snapin(this, '%s')" % toggle_url)
-
- html.open_div(class_=["head", snapin.visibility.value], **head_actions)
+ html.open_div(class_=["head", snapin.visible.value], **head_actions)
if config.user.may("general.configure_sidebar"):
# Icon for mini/maximizing
Module: check_mk
Branch: master
Commit: 092bb7bb6c68588e1bf1f5aaf938bbf2be968147
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=092bb7bb6c6858…
Author: Lars Michelsen <lm(a)mathias-kettner.de>
Date: Fri Aug 24 13:49:12 2018 +0200
Snapins can now be customized
* The snapin developer can make a default snapin customizable
by subclassing from CustomizableSidebarSnapin.
* The user can then navigate to "Add snapin page > Custom snapins"
to manage his custom snapins.
* When editing such a custom snapin the attributes of the snapin
can be edited. The user can also choose to share this dashlet
with other users.
* Once a custom snapin has been created, the user can choose the
new dashlet from the "add snapin page" for adding it to his
dashboard.
* As first dashlet, the Tactical Overview snapin can now be configured
to show statistics about custom sets of hosts / services / events.
It can also be configured to show or not show stale objects and
failed notifications.
CMK-856
Change-Id: I9e32736d90cd21c6c4aaa08f778ff21970dd1a28
---
cmk/gui/plugins/sidebar/__init__.py | 1 +
cmk/gui/plugins/sidebar/tactical_overview.py | 490 +++++++++++++++++----------
cmk/gui/plugins/sidebar/utils.py | 98 ++++++
cmk/gui/sidebar.py | 162 +++++++--
tests/unit/web/test_sidebar.py | 1 +
5 files changed, 548 insertions(+), 204 deletions(-)
Diff: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commitdiff;h=092bb7bb6c…