From ff04af396b9d7b740a08ae308d2e9edc2dd660c8 Mon Sep 17 00:00:00 2001 From: Gunnar Beutner Date: Mon, 1 Jul 2013 14:09:54 +0200 Subject: [PATCH] Add missing validator for flapping_threshold. --- lib/icinga/icinga-type.conf | 6 ++++++ lib/icinga/service.cpp | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/lib/icinga/icinga-type.conf b/lib/icinga/icinga-type.conf index bd89463ff..08ae85a54 100644 --- a/lib/icinga/icinga-type.conf +++ b/lib/icinga/icinga-type.conf @@ -59,6 +59,8 @@ type Host { %attribute number "notification_interval", %attribute name(TimePeriod) "notification_period", + %attribute number "flapping_threshold", + %attribute array "servicegroups" { %attribute name(ServiceGroup) "*" }, @@ -143,6 +145,8 @@ type Host { %attribute number "notification_interval", %attribute name(TimePeriod) "notification_period", + %attribute number "flapping_threshold", + %attribute number "notification_type_filter", %attribute number "notification_state_filter", @@ -199,6 +203,8 @@ type Service { %attribute number "notification_interval", %attribute name(TimePeriod) "notification_period", + %attribute number "flapping_threshold", + %attribute array "hostdependencies" { %attribute name(Host) "*" }, diff --git a/lib/icinga/service.cpp b/lib/icinga/service.cpp index 33ca1deb8..2b8c9a38e 100644 --- a/lib/icinga/service.cpp +++ b/lib/icinga/service.cpp @@ -91,7 +91,7 @@ Service::Service(const Dictionary::Ptr& serializedObject) RegisterAttribute("flapping_negative", Attribute_Replicated, &m_FlappingNegative); RegisterAttribute("flapping_lastchange", Attribute_Replicated, &m_FlappingLastChange); RegisterAttribute("flapping_threshold", Attribute_Config, &m_FlappingThreshold); - RegisterAttribute("enable_flapping", Attribute_Config, &m_EnableFlapping); + RegisterAttribute("enable_flapping", Attribute_Replicated, &m_EnableFlapping); SetSchedulingOffset(rand()); -- 2.50.1