Module: Hinoki::Events
- Defined in:
- lib/hinoki/events.rb
Class Method Summary collapse
-
.all ⇒ Object
Lists all events.
-
.for_client(client) ⇒ Object
Returns events associated with the given client.
-
.resolve(client, check) ⇒ Object
Clears an event from Sensu.
Class Method Details
.all ⇒ Object
Lists all events
9 10 11 |
# File 'lib/hinoki/events.rb', line 9 def self.all return Hinoki.conn.get('/events') end |
.for_client(client) ⇒ Object
Returns events associated with the given client
14 15 16 |
# File 'lib/hinoki/events.rb', line 14 def self.for_client(client) return Hinoki.conn.get("/events/#{client}") end |
.resolve(client, check) ⇒ Object
Clears an event from Sensu
19 20 21 |
# File 'lib/hinoki/events.rb', line 19 def self.resolve(client, check) return Hinoki.conn.delete("/events/#{client}/#{check}") end |