Class: Deimos::Status::Manager
- Inherits:
-
Object
- Object
- Deimos::Status::Manager
- Defined in:
- lib/deimos/status/manager.rb
Instance Attribute Summary collapse
-
#checks ⇒ Object
readonly
Returns the value of attribute checks.
Instance Method Summary collapse
Instance Attribute Details
#checks ⇒ Object (readonly)
Returns the value of attribute checks.
5 6 7 |
# File 'lib/deimos/status/manager.rb', line 5 def checks @checks end |
Instance Method Details
#add(name, &block) ⇒ Object
10 11 12 13 14 |
# File 'lib/deimos/status/manager.rb', line 10 def add(name, &block) Deimos.logger.info "Status: Reporting #{name} status..." checks[name] = block || Proc.new { true } end |
#run! ⇒ Object
16 17 18 |
# File 'lib/deimos/status/manager.rb', line 16 def run! Deimos::Status::Runner.new(checks) end |