Sha256: f66b89793b08108a4e430431f0f526c2cca8affeb7a2d0703e96c535891a23c3
Contents?: true
Size: 858 Bytes
Versions: 3
Compression:
Stored size: 858 Bytes
Contents
# Messages While [formatters](/docs/formatters.md) are crucial to contextualizing alerts, it doesn't matter much if the alerts are never sent. This is where messages come in to play. ``nagios-herald`` provides a base Message class (``Message::Base``) from which all Message subclasses inherit. ``Message::Base`` knows that all messages have content and recipients; it's the job of the Message subclasses to define additional behavior (such as how to send a message). Three message types are defined in ``nagios-herald``: Email, Pager, and IRC. Feel free to cook up any new message types (i.e. CarrierPigeon, SmokeSignal) as you see fit. ## Getting Content into Messages Content generated by formatters is assigned to a message in ``Executor`` via the following code: ```ruby formatter.generate_message_content message.content = formatter.content ```
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
nagios-herald-0.0.4 | docs/messages.md |
nagios-herald-0.0.3 | docs/messages.md |
nagios-herald-0.0.2 | docs/messages.md |