[icinga-checkins] icinga.org: icinga2/master: Add log message if notifications are forced ( i.e. filters are not checked)

git at icinga.org git at icinga.org
Thu Aug 11 16:24:08 CEST 2016


Module: icinga2
Branch: master
Commit: f5d5eaf344564b2aacc923ab0d2e14e1d1e4c632
URL:    https://git.icinga.org/?p=icinga2.git;a=commit;h=f5d5eaf344564b2aacc923ab0d2e14e1d1e4c632

Author: Michael Friedrich <michael.friedrich at netways.de>
Date:   Thu Aug 11 16:23:58 2016 +0200

Add log message if notifications are forced (i.e. filters are not checked)

fixes #12404

---

 lib/icinga/notification.cpp |    7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/lib/icinga/notification.cpp b/lib/icinga/notification.cpp
index ca2db2b..4e702f9 100644
--- a/lib/icinga/notification.cpp
+++ b/lib/icinga/notification.cpp
@@ -352,6 +352,9 @@ void Notification::BeginExecuteNotification(NotificationType type, const CheckRe
 				return;
 			}
 		}
+	} else {
+		Log(LogNotice, "Notification")
+		    << "Not checking notification filters for notification object '" << GetName() << "': Notification was forced.";
 	}
 
 	{
@@ -488,6 +491,10 @@ bool Notification::CheckNotificationUserFilters(NotificationType type, const Use
 				return false;
 			}
 		}
+	} else {
+		Log(LogNotice, "Notification")
+		    << "Not checking notification filters for notification object '"
+		    << GetName() << "' and user '" << user->GetName() << "': Notification was forced.";
 	}
 
 	return true;



More information about the icinga-checkins mailing list