Class: Backups::Listeners::Notify::Datadog
- Inherits:
-
Backups::Listener
- Object
- Backups::Listener
- Backups::Listeners::Notify::Datadog
- Defined in:
- lib/backups/listeners/notify/datadog.rb
Instance Method Summary collapse
-
#initialize(config) ⇒ Datadog
constructor
A new instance of Datadog.
Methods inherited from Backups::Listener
Constructor Details
#initialize(config) ⇒ Datadog
Returns a new instance of Datadog.
8 9 10 11 12 13 14 15 16 17 18 19 |
# File 'lib/backups/listeners/notify/datadog.rb', line 8 def initialize config @config = config api_key = @config.fetch("api_key") app_key = @config.fetch("app_key") @dog = Dogapi::Client.new(api_key, app_key) $LOGGER.debug "Datadog listener started" Events::on :start, :done, :error do |params| _notify params end end |