mirror of
https://github.com/Icinga/icinga2.git
synced 2025-07-26 15:14:07 +02:00
parent
aade27ab70
commit
c4bfff27c7
@ -19,6 +19,7 @@
|
|||||||
|
|
||||||
#include "notification/notificationcomponent.hpp"
|
#include "notification/notificationcomponent.hpp"
|
||||||
#include "icinga/service.hpp"
|
#include "icinga/service.hpp"
|
||||||
|
#include "icinga/icingaapplication.hpp"
|
||||||
#include "base/dynamictype.hpp"
|
#include "base/dynamictype.hpp"
|
||||||
#include "base/objectlock.hpp"
|
#include "base/objectlock.hpp"
|
||||||
#include "base/logger_fwd.hpp"
|
#include "base/logger_fwd.hpp"
|
||||||
@ -74,6 +75,9 @@ void NotificationComponent::NotificationTimerHandler(void)
|
|||||||
BOOST_FOREACH(const Notification::Ptr& notification, DynamicType::GetObjects<Notification>()) {
|
BOOST_FOREACH(const Notification::Ptr& notification, DynamicType::GetObjects<Notification>()) {
|
||||||
Checkable::Ptr checkable = notification->GetCheckable();
|
Checkable::Ptr checkable = notification->GetCheckable();
|
||||||
|
|
||||||
|
if (!IcingaApplication::GetInstance()->GetEnableNotifications() || !checkable->GetEnableNotifications())
|
||||||
|
continue;
|
||||||
|
|
||||||
if (notification->GetInterval() <= 0 && notification->GetLastProblemNotification() > checkable->GetLastHardStateChange())
|
if (notification->GetInterval() <= 0 && notification->GetLastProblemNotification() > checkable->GetLastHardStateChange())
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user