|
Monitoring System 0.1.0
System resource monitoring with pluggable collectors and alerting
|
Sends alerts to multiple notifiers. More...
#include <alert_notifiers.h>


Public Member Functions | |
| multi_notifier (std::string notifier_name) | |
| Construct with name. | |
| void | add_notifier (std::shared_ptr< alert_notifier > notifier) |
| Add a child notifier. | |
| std::string | name () const override |
| Get notifier name. | |
| common::VoidResult | notify (const alert &a) override |
| Send a notification for an alert. | |
| common::VoidResult | notify_group (const alert_group &group) override |
| Send a notification for an alert group. | |
| bool | is_ready () const override |
| Check if notifier is ready. | |
Public Member Functions inherited from kcenon::monitoring::alert_notifier | |
| virtual | ~alert_notifier ()=default |
Static Private Member Functions | |
| static std::string | join_strings (const std::vector< std::string > &strings, const std::string &delimiter) |
Private Attributes | |
| std::string | name_ |
| std::mutex | mutex_ |
| std::vector< std::shared_ptr< alert_notifier > > | notifiers_ |
Sends alerts to multiple notifiers.
Wraps multiple notifiers and sends alerts to all of them. Collects results from all notifiers.
Definition at line 365 of file alert_notifiers.h.
|
inlineexplicit |
Construct with name.
Definition at line 370 of file alert_notifiers.h.
|
inline |
Add a child notifier.
Definition at line 376 of file alert_notifiers.h.
References mutex_, and notifiers_.
|
inlineoverridevirtual |
Check if notifier is ready.
Implements kcenon::monitoring::alert_notifier.
Definition at line 423 of file alert_notifiers.h.
References mutex_, and notifiers_.
|
inlinestaticprivate |
Definition at line 429 of file alert_notifiers.h.
Referenced by notify(), and notify_group().

|
inlineoverridevirtual |
Get notifier name.
Implements kcenon::monitoring::alert_notifier.
Definition at line 381 of file alert_notifiers.h.
References name_.
|
inlineoverridevirtual |
Send a notification for an alert.
| a | Alert to notify about |
Implements kcenon::monitoring::alert_notifier.
Definition at line 383 of file alert_notifiers.h.
References join_strings(), mutex_, notifiers_, and kcenon::monitoring::operation_failed.

|
inlineoverridevirtual |
Send a notification for an alert group.
| group | Alert group to notify about |
Implements kcenon::monitoring::alert_notifier.
Definition at line 403 of file alert_notifiers.h.
References join_strings(), mutex_, notifiers_, and kcenon::monitoring::operation_failed.

|
mutableprivate |
Definition at line 440 of file alert_notifiers.h.
Referenced by add_notifier(), is_ready(), notify(), and notify_group().
|
private |
Definition at line 439 of file alert_notifiers.h.
Referenced by name().
|
private |
Definition at line 441 of file alert_notifiers.h.
Referenced by add_notifier(), is_ready(), notify(), and notify_group().