diff --git a/doc/4.3-object-types.md b/doc/4.3-object-types.md index e980de29a..d2965b92d 100644 --- a/doc/4.3-object-types.md +++ b/doc/4.3-object-types.md @@ -112,9 +112,12 @@ Attributes: check\_period |**Optional.** The name of a time period which determines when this service should be checked. Not set by default. check\_interval |**Optional.** The check interval (in seconds). This interval is used for checks when the service is in a `HARD` state. Defaults to 5 minutes. retry\_interval |**Optional.** The retry interval (in seconds). This interval is used for checks when the service is in a `SOFT` state. Defaults to 1 minute. + enable\_notifications|**Optional.** Whether notifications are enabled. Defaults to true. enable\_active\_checks|**Optional.** Whether active checks are enabled. Defaults to true. enable\_passive\_checks|**Optional.** Whether passive checks are enabled. Defaults to true. enable\_event\_handler|**Optional.** Enables event handlers for this service. Defaults to true. + enable\_flap\_detection|**Optional.** Whether flap detection is enabled. Defaults to true. + enable\_perfdata|**Optional.** Whether performance data processing is enabled. Defaults to true. event\_command |**Optional.** The name of an event command that should be executed every time the service's state changes. flapping\_threshold|**Optional.** The flapping threshold in percent when a service is considered to be flapping. volatile |**Optional.** The volatile setting enables always `HARD` state types if `NOT-OK` state changes occur. diff --git a/lib/icinga/externalcommandprocessor.cpp b/lib/icinga/externalcommandprocessor.cpp index f0e9d1f6c..7b3fd46b2 100644 --- a/lib/icinga/externalcommandprocessor.cpp +++ b/lib/icinga/externalcommandprocessor.cpp @@ -25,6 +25,7 @@ #include "icinga/servicegroup.h" #include "icinga/pluginutility.h" #include "icinga/icingaapplication.h" +#include "icinga/eventcommand.h" #include "base/convert.h" #include "base/logger_fwd.h" #include "base/objectlock.h" @@ -190,6 +191,14 @@ void ExternalCommandProcessor::Initialize(void) RegisterCommand("DISABLE_HOST_EVENT_HANDLER", &ExternalCommandProcessor::DisableHostEventHandler); RegisterCommand("ENABLE_SVC_EVENT_HANDLER", &ExternalCommandProcessor::EnableSvcEventHandler); RegisterCommand("DISABLE_SVC_EVENT_HANDLER", &ExternalCommandProcessor::DisableSvcEventHandler); + RegisterCommand("CHANGE_HOST_EVENT_HANDLER", &ExternalCommandProcessor::ChangeHostEventHandler); + RegisterCommand("CHANGE_SVC_EVENT_HANDLER", &ExternalCommandProcessor::ChangeSvcEventHandler); + RegisterCommand("CHANGE_HOST_CHECK_COMMAND", &ExternalCommandProcessor::ChangeHostCheckCommand); + RegisterCommand("CHANGE_SVC_CHECK_COMMAND", &ExternalCommandProcessor::ChangeSvcCheckCommand); + RegisterCommand("CHANGE_MAX_HOST_CHECK_ATTEMPTS", &ExternalCommandProcessor::ChangeMaxHostCheckAttempts); + RegisterCommand("CHANGE_MAX_SVC_CHECK_ATTEMPTS", &ExternalCommandProcessor::ChangeMaxSvcCheckAttempts); + RegisterCommand("CHANGE_HOST_CHECK_TIMEPERIOD", &ExternalCommandProcessor::ChangeHostCheckTimeperiod); + RegisterCommand("CHANGE_SVC_CHECK_TIMEPERIOD", &ExternalCommandProcessor::ChangeSvcCheckTimeperiod); } void ExternalCommandProcessor::RegisterCommand(const String& command, const ExternalCommandProcessor::Callback& callback) @@ -1987,7 +1996,7 @@ void ExternalCommandProcessor::EnableSvcEventHandler(double time, const std::vec Service::Ptr service = Service::GetByNamePair(arguments[0], arguments[1]); if (!service) - BOOST_THROW_EXCEPTION(std::invalid_argument("Cannot enable event handlerfor non-existent service '" + arguments[1] + "' on host '" + arguments[0] + "'")); + BOOST_THROW_EXCEPTION(std::invalid_argument("Cannot enable event handler for non-existent service '" + arguments[1] + "' on host '" + arguments[0] + "'")); Log(LogInformation, "icinga", "Enabling event handler for service '" + arguments[1] + "'"); @@ -2006,7 +2015,7 @@ void ExternalCommandProcessor::DisableSvcEventHandler(double time, const std::ve Service::Ptr service = Service::GetByNamePair(arguments[0], arguments[1]); if (!service) - BOOST_THROW_EXCEPTION(std::invalid_argument("Cannot disable event handlerfor non-existent service '" + arguments[1] + "' on host '" + arguments[0] + "'")); + BOOST_THROW_EXCEPTION(std::invalid_argument("Cannot disable event handler for non-existent service '" + arguments[1] + "' on host '" + arguments[0] + "'")); Log(LogInformation, "icinga", "Disabling event handler for service '" + arguments[1] + "'"); @@ -2016,3 +2025,197 @@ void ExternalCommandProcessor::DisableSvcEventHandler(double time, const std::ve service->SetEnableEventHandler(false); } } + +void ExternalCommandProcessor::ChangeHostEventHandler(double time, const std::vector& arguments) +{ + if (arguments.size() < 2) + BOOST_THROW_EXCEPTION(std::invalid_argument("Expected 2 arguments.")); + + Host::Ptr host = Host::GetByName(arguments[0]); + + if (!host) + BOOST_THROW_EXCEPTION(std::invalid_argument("Cannot change event handler for non-existent host '" + arguments[0] + "'")); + + Service::Ptr hc = host->GetCheckService(); + + EventCommand::Ptr command = EventCommand::GetByName(arguments[2]); + + if (!command) + BOOST_THROW_EXCEPTION(std::invalid_argument("Event command '" + arguments[1] + "' does not exist.")); + + Log(LogInformation, "icinga", "Changing event handler for host '" + arguments[0] + "' to '" + arguments[1] + "'"); + + { + ObjectLock olock(hc); + + hc->SetEventCommand(command); + } +} + +void ExternalCommandProcessor::ChangeSvcEventHandler(double time, const std::vector& arguments) +{ + if (arguments.size() < 2) + BOOST_THROW_EXCEPTION(std::invalid_argument("Expected 3 arguments.")); + + Service::Ptr service = Service::GetByNamePair(arguments[0], arguments[1]); + + if (!service) + BOOST_THROW_EXCEPTION(std::invalid_argument("Cannot change event handler for non-existent service '" + arguments[1] + "' on host '" + arguments[0] + "'")); + + EventCommand::Ptr command = EventCommand::GetByName(arguments[2]); + + if (!command) + BOOST_THROW_EXCEPTION(std::invalid_argument("Event command '" + arguments[2] + "' does not exist.")); + + Log(LogInformation, "icinga", "Changing event handler for service '" + arguments[1] + "' to '" + arguments[2] + "'"); + + { + ObjectLock olock(service); + + service->SetEventCommand(command); + } +} + +void ExternalCommandProcessor::ChangeHostCheckCommand(double time, const std::vector& arguments) +{ + if (arguments.size() < 2) + BOOST_THROW_EXCEPTION(std::invalid_argument("Expected 2 arguments.")); + + Host::Ptr host = Host::GetByName(arguments[0]); + + if (!host) + BOOST_THROW_EXCEPTION(std::invalid_argument("Cannot change check command for non-existent host '" + arguments[0] + "'")); + + Service::Ptr hc = host->GetCheckService(); + + CheckCommand::Ptr command = CheckCommand::GetByName(arguments[2]); + + if (!command) + BOOST_THROW_EXCEPTION(std::invalid_argument("Check command '" + arguments[1] + "' does not exist.")); + + Log(LogInformation, "icinga", "Changing check command for host '" + arguments[0] + "' to '" + arguments[1] + "'"); + + { + ObjectLock olock(hc); + + hc->SetCheckCommand(command); + } +} + +void ExternalCommandProcessor::ChangeSvcCheckCommand(double time, const std::vector& arguments) +{ + if (arguments.size() < 2) + BOOST_THROW_EXCEPTION(std::invalid_argument("Expected 3 arguments.")); + + Service::Ptr service = Service::GetByNamePair(arguments[0], arguments[1]); + + if (!service) + BOOST_THROW_EXCEPTION(std::invalid_argument("Cannot change check command for non-existent service '" + arguments[1] + "' on host '" + arguments[0] + "'")); + + CheckCommand::Ptr command = CheckCommand::GetByName(arguments[2]); + + if (!command) + BOOST_THROW_EXCEPTION(std::invalid_argument("Check command '" + arguments[2] + "' does not exist.")); + + Log(LogInformation, "icinga", "Changing check command for service '" + arguments[1] + "' to '" + arguments[2] + "'"); + + { + ObjectLock olock(service); + + service->SetCheckCommand(command); + } +} + +void ExternalCommandProcessor::ChangeMaxHostCheckAttempts(double time, const std::vector& arguments) +{ + if (arguments.size() < 2) + BOOST_THROW_EXCEPTION(std::invalid_argument("Expected 2 arguments.")); + + Host::Ptr host = Host::GetByName(arguments[0]); + + if (!host) + BOOST_THROW_EXCEPTION(std::invalid_argument("Cannot change max check attempts for non-existent host '" + arguments[0] + "'")); + + Service::Ptr hc = host->GetCheckService(); + + int attempts = Convert::ToLong(arguments[2]); + + Log(LogInformation, "icinga", "Changing max check attempts for host '" + arguments[0] + "' to '" + arguments[1] + "'"); + + { + ObjectLock olock(hc); + + hc->SetMaxCheckAttempts(attempts); + } +} + +void ExternalCommandProcessor::ChangeMaxSvcCheckAttempts(double time, const std::vector& arguments) +{ + if (arguments.size() < 2) + BOOST_THROW_EXCEPTION(std::invalid_argument("Expected 3 arguments.")); + + Service::Ptr service = Service::GetByNamePair(arguments[0], arguments[1]); + + if (!service) + BOOST_THROW_EXCEPTION(std::invalid_argument("Cannot change max check attempts for non-existent service '" + arguments[1] + "' on host '" + arguments[0] + "'")); + + int attempts = Convert::ToLong(arguments[2]); + + Log(LogInformation, "icinga", "Changing max check attempts for service '" + arguments[1] + "' to '" + arguments[2] + "'"); + + { + ObjectLock olock(service); + + service->SetMaxCheckAttempts(attempts); + } +} + +void ExternalCommandProcessor::ChangeHostCheckTimeperiod(double time, const std::vector& arguments) +{ + if (arguments.size() < 2) + BOOST_THROW_EXCEPTION(std::invalid_argument("Expected 2 arguments.")); + + Host::Ptr host = Host::GetByName(arguments[0]); + + if (!host) + BOOST_THROW_EXCEPTION(std::invalid_argument("Cannot change check period for non-existent host '" + arguments[0] + "'")); + + Service::Ptr hc = host->GetCheckService(); + + TimePeriod::Ptr tp = TimePeriod::GetByName(arguments[2]); + + if (!tp) + BOOST_THROW_EXCEPTION(std::invalid_argument("Time period '" + arguments[1] + "' does not exist.")); + + Log(LogInformation, "icinga", "Changing check period for host '" + arguments[0] + "' to '" + arguments[1] + "'"); + + { + ObjectLock olock(hc); + + hc->SetCheckPeriod(tp); + } +} + +void ExternalCommandProcessor::ChangeSvcCheckTimeperiod(double time, const std::vector& arguments) +{ + if (arguments.size() < 2) + BOOST_THROW_EXCEPTION(std::invalid_argument("Expected 3 arguments.")); + + Service::Ptr service = Service::GetByNamePair(arguments[0], arguments[1]); + + if (!service) + BOOST_THROW_EXCEPTION(std::invalid_argument("Cannot change check period for non-existent service '" + arguments[1] + "' on host '" + arguments[0] + "'")); + + TimePeriod::Ptr tp = TimePeriod::GetByName(arguments[2]); + + if (!tp) + BOOST_THROW_EXCEPTION(std::invalid_argument("Time period '" + arguments[2] + "' does not exist.")); + + Log(LogInformation, "icinga", "Changing check period for service '" + arguments[1] + "' to '" + arguments[2] + "'"); + + { + ObjectLock olock(service); + + service->SetCheckPeriod(tp); + } +} \ No newline at end of file diff --git a/lib/icinga/externalcommandprocessor.h b/lib/icinga/externalcommandprocessor.h index 2216728a7..371eef800 100644 --- a/lib/icinga/externalcommandprocessor.h +++ b/lib/icinga/externalcommandprocessor.h @@ -141,6 +141,14 @@ private: static void DisableHostEventHandler(double time, const std::vector& arguments); static void EnableSvcEventHandler(double time, const std::vector& arguments); static void DisableSvcEventHandler(double time, const std::vector& arguments); + static void ChangeHostEventHandler(double time, const std::vector& arguments); + static void ChangeSvcEventHandler(double time, const std::vector& arguments); + static void ChangeHostCheckCommand(double time, const std::vector& arguments); + static void ChangeSvcCheckCommand(double time, const std::vector& arguments); + static void ChangeMaxHostCheckAttempts(double time, const std::vector& arguments); + static void ChangeMaxSvcCheckAttempts(double time, const std::vector& arguments); + static void ChangeHostCheckTimeperiod(double time, const std::vector& arguments); + static void ChangeSvcCheckTimeperiod(double time, const std::vector& arguments); }; } diff --git a/lib/icinga/icinga-type.conf b/lib/icinga/icinga-type.conf index 473f4b938..706b2d7cf 100644 --- a/lib/icinga/icinga-type.conf +++ b/lib/icinga/icinga-type.conf @@ -76,6 +76,7 @@ type Service { %attribute number "check_interval", %attribute number "retry_interval", + %attribute number "enable_notifications", %attribute number "enable_active_checks", %attribute number "enable_passive_checks", %attribute number "enable_event_handler", diff --git a/lib/icinga/service-check.cpp b/lib/icinga/service-check.cpp index 219086109..e2f68b468 100644 --- a/lib/icinga/service-check.cpp +++ b/lib/icinga/service-check.cpp @@ -47,12 +47,36 @@ boost::signals2::signal Service::OnFl CheckCommand::Ptr Service::GetCheckCommand(void) const { - return CheckCommand::GetByName(GetCheckCommandRaw()); + String command; + + if (!GetOverrideCheckCommand().IsEmpty()) + command = GetOverrideCheckCommand(); + else + command = GetCheckCommandRaw(); + + return CheckCommand::GetByName(command); +} + +void Service::SetCheckCommand(const CheckCommand::Ptr& command) +{ + SetOverrideCheckCommand(command->GetName()); } TimePeriod::Ptr Service::GetCheckPeriod(void) const { - return TimePeriod::GetByName(GetCheckPeriodRaw()); + String tp; + + if (!GetOverrideCheckPeriod().IsEmpty()) + tp = GetOverrideCheckPeriod(); + else + tp = GetCheckPeriodRaw(); + + return TimePeriod::GetByName(tp); +} + +void Service::SetCheckPeriod(const TimePeriod::Ptr& tp) +{ + SetOverrideCheckPeriod(tp->GetName()); } double Service::GetCheckInterval(void) const @@ -181,6 +205,19 @@ void Service::SetForceNextCheck(bool forced, const String& authority) OnForceNextCheckChanged(GetSelf(), forced, authority); } +int Service::GetMaxCheckAttempts(void) const +{ + if (!GetOverrideMaxCheckAttempts().IsEmpty()) + return GetOverrideMaxCheckAttempts(); + else + return GetMaxCheckAttemptsRaw(); +} + +void Service::SetMaxCheckAttempts(int attempts) +{ + SetOverrideMaxCheckAttempts(attempts); +} + void Service::ProcessCheckResult(const CheckResult::Ptr& cr, const String& authority) { double now = Utility::GetTime(); diff --git a/lib/icinga/service-event.cpp b/lib/icinga/service-event.cpp index d7b8d7806..ff5923400 100644 --- a/lib/icinga/service-event.cpp +++ b/lib/icinga/service-event.cpp @@ -41,7 +41,19 @@ void Service::SetEnableEventHandler(bool enabled) EventCommand::Ptr Service::GetEventCommand(void) const { - return EventCommand::GetByName(GetEventCommandRaw()); + String command; + + if (!GetOverrideEventCommand().IsEmpty()) + command = GetOverrideEventCommand(); + else + command = GetEventCommandRaw(); + + return EventCommand::GetByName(command); +} + +void Service::SetEventCommand(const EventCommand::Ptr& command) +{ + SetOverrideEventCommand(command->GetName()); } void Service::ExecuteEventHandler(void) diff --git a/lib/icinga/service-flapping.cpp b/lib/icinga/service-flapping.cpp index 144b165a5..67b7af938 100644 --- a/lib/icinga/service-flapping.cpp +++ b/lib/icinga/service-flapping.cpp @@ -42,12 +42,15 @@ double Service::GetFlappingCurrent(void) const bool Service::GetEnableFlapping(void) const { - return GetEnableFlappingRaw(); + if (!GetOverrideEnableFlapping().IsEmpty()) + return GetOverrideEnableFlapping(); + else + return GetEnableFlappingRaw(); } void Service::SetEnableFlapping(bool enabled, const String& authority) { - SetEnableFlappingRaw(enabled); + SetOverrideEnableFlapping(enabled); OnFlappingChanged(GetSelf(), enabled ? FlappingEnabled : FlappingDisabled); OnEnableFlappingChanged(GetSelf(), enabled, authority); diff --git a/lib/icinga/service-notification.cpp b/lib/icinga/service-notification.cpp index 0f32995d1..6128301c9 100644 --- a/lib/icinga/service-notification.cpp +++ b/lib/icinga/service-notification.cpp @@ -163,12 +163,15 @@ void Service::UpdateSlaveNotifications(void) bool Service::GetEnableNotifications(void) const { - return GetEnableNotificationsRaw(); + if (!GetOverrideEnableNotifications().IsEmpty()) + return GetOverrideEnableNotifications(); + else + return GetEnableNotificationsRaw(); } void Service::SetEnableNotifications(bool enabled, const String& authority) { - SetEnableNotificationsRaw(enabled); + SetOverrideEnableActiveChecks(enabled); OnEnableNotificationsChanged(GetSelf(), enabled, authority); } diff --git a/lib/icinga/service.cpp b/lib/icinga/service.cpp index 3a45529c2..4c909118b 100644 --- a/lib/icinga/service.cpp +++ b/lib/icinga/service.cpp @@ -260,25 +260,59 @@ std::set Service::GetParentServices(void) const return parents; } +bool Service::GetEnablePerfdata(void) const +{ + if (!GetOverrideEnablePerfdata().IsEmpty()) + return GetOverrideEnablePerfdata(); + else + return GetEnablePerfdataRaw(); +} + +void Service::SetEnablePerfdata(bool enabled, const String& authority) +{ + SetOverrideEnablePerfdata(enabled); +} + int Service::GetModifiedAttributes(void) const { int attrs = 0; + if (!GetOverrideEnableNotifications().IsEmpty()) + attrs |= ModAttrNotificationsEnabled; + if (!GetOverrideEnableActiveChecks().IsEmpty()) attrs |= ModAttrActiveChecksEnabled; if (!GetOverrideEnablePassiveChecks().IsEmpty()) attrs |= ModAttrPassiveChecksEnabled; + if (!GetOverrideEnableFlapping().IsEmpty()) + attrs |= ModAttrFlapDetectionEnabled; + if (!GetOverrideEnableEventHandler().IsEmpty()) attrs |= ModAttrEventHandlerEnabled; + if (!GetOverrideEnablePerfdata().IsEmpty()) + attrs |= ModAttrPerformanceDataEnabled; + if (!GetOverrideCheckInterval().IsEmpty()) attrs |= ModAttrNormalCheckInterval; if (!GetOverrideRetryInterval().IsEmpty()) attrs |= ModAttrRetryCheckInterval; + if (!GetOverrideEventCommand().IsEmpty()) + attrs |= ModAttrEventHandlerCommand; + + if (!GetOverrideCheckCommand().IsEmpty()) + attrs |= ModAttrCheckCommand; + + if (!GetOverrideMaxCheckAttempts().IsEmpty()) + attrs |= ModAttrMaxCheckAttempts; + + if (!GetOverrideCheckPeriod().IsEmpty()) + attrs |= ModAttrCheckTimeperiod; + // TODO: finish return attrs; @@ -286,20 +320,41 @@ int Service::GetModifiedAttributes(void) const void Service::SetModifiedAttributes(int flags) { + if ((flags & ModAttrNotificationsEnabled) == 0) + SetOverrideEnableNotifications(Empty); + if ((flags & ModAttrActiveChecksEnabled) == 0) SetOverrideEnableActiveChecks(Empty); if ((flags & ModAttrPassiveChecksEnabled) == 0) SetOverrideEnablePassiveChecks(Empty); + if ((flags & ModAttrFlapDetectionEnabled) == 0) + SetOverrideEnableFlapping(Empty); + if ((flags & ModAttrEventHandlerEnabled) == 0) SetOverrideEnableEventHandler(Empty); + if ((flags & ModAttrPerformanceDataEnabled) == 0) + SetOverrideEnablePerfdata(Empty); + if ((flags & ModAttrNormalCheckInterval) == 0) SetOverrideCheckInterval(Empty); if ((flags & ModAttrRetryCheckInterval) == 0) SetOverrideRetryInterval(Empty); + + if ((flags & ModAttrEventHandlerCommand) == 0) + SetOverrideEventCommand(Empty); + + if ((flags & ModAttrCheckCommand) == 0) + SetOverrideCheckCommand(Empty); + + if ((flags & ModAttrMaxCheckAttempts) == 0) + SetOverrideMaxCheckAttempts(Empty); + + if ((flags & ModAttrCheckTimeperiod) == 0) + SetOverrideCheckPeriod(Empty); } bool Service::ResolveMacro(const String& macro, const CheckResult::Ptr& cr, String *result) const diff --git a/lib/icinga/service.h b/lib/icinga/service.h index c11e0ea85..1680e2221 100644 --- a/lib/icinga/service.h +++ b/lib/icinga/service.h @@ -109,7 +109,10 @@ public: /* Checks */ shared_ptr GetCheckCommand(void) const; + void SetCheckCommand(const shared_ptr& command); + TimePeriod::Ptr GetCheckPeriod(void) const; + void SetCheckPeriod(const TimePeriod::Ptr& tp); double GetCheckInterval(void) const; void SetCheckInterval(double interval); @@ -117,6 +120,9 @@ public: double GetRetryInterval(void) const; void SetRetryInterval(double interval); + int GetMaxCheckAttempts(void) const; + void SetMaxCheckAttempts(int attempts); + long GetSchedulingOffset(void); void SetSchedulingOffset(long offset); @@ -235,7 +241,9 @@ public: /* Event Handler */ void ExecuteEventHandler(void); + shared_ptr GetEventCommand(void) const; + void SetEventCommand(const shared_ptr& command); bool GetEnableEventHandler(void) const; void SetEnableEventHandler(bool enabled); @@ -249,6 +257,10 @@ public: bool IsFlapping(void) const; void UpdateFlappingStatus(bool stateChange); + /* Performance data */ + bool GetEnablePerfdata(void) const; + void SetEnablePerfdata(bool enabled, const String& authority = String()); + protected: virtual void Start(void); diff --git a/lib/icinga/service.ti b/lib/icinga/service.ti index 134a41c61..ee693c706 100644 --- a/lib/icinga/service.ti +++ b/lib/icinga/service.ti @@ -34,7 +34,7 @@ class Service : DynamicObject [config] Array::Ptr service_dependencies; [config] Array::Ptr groups; [config, protected] String check_command (CheckCommandRaw); - [config] int max_check_attempts { + [config] int max_check_attempts (MaxCheckAttemptsRaw) { default {{{ return 3; }}} }; [config, protected] String check_period (CheckPeriodRaw); @@ -68,6 +68,15 @@ class Service : DynamicObject [config] bool enable_event_handler (EnableEventHandlerRaw) { default {{{ return true; }}} }; + [config] bool enable_notifications (EnableNotificationsRaw) { + default {{{ return true; }}} + }; + [config] bool enable_flapping (EnableFlappingRaw) { + default {{{ return true; }}} + }; + [config] bool enable_perfdata (EnablePerfdataRaw) { + default {{{ return true; }}} + }; [state] double next_check (NextCheckRaw); [state] int check_attempt { @@ -115,24 +124,22 @@ class Service : DynamicObject [state] Dictionary::Ptr downtimes { default {{{ return make_shared(); }}} }; - [state] bool enable_notifications (EnableNotificationsRaw) { - default {{{ return true; }}} - }; [state] bool force_next_notification (ForceNextNotificationRaw); [state] int flapping_positive; [state] int flapping_negative; [state] double flapping_last_change; - [state] bool enable_flapping (EnableFlappingRaw) { - default {{{ return true; }}} - }; - [state] bool enable_perfdata { - default {{{ return true; }}} - }; + [state] Value override_enable_notifications; [state] Value override_enable_active_checks; [state] Value override_enable_passive_checks; + [state] Value override_enable_flapping; + [state] Value override_enable_perfdata; [state] Value override_check_interval; [state] Value override_retry_interval; [state] Value override_enable_event_handler; + [state] Value override_event_command; + [state] Value override_check_command; + [state] Value override_max_check_attempts; + [state] Value override_check_period; }; }