Class: Bipbip::Plugin::Command
- Inherits:
-
Bipbip::Plugin
- Object
- Bipbip::Plugin
- Bipbip::Plugin::Command
- Defined in:
- lib/bipbip/plugin/command.rb
Instance Attribute Summary collapse
-
#schema ⇒ Object
Returns the value of attribute schema.
Attributes inherited from Bipbip::Plugin
#config, #frequency, #metric_group, #name, #tags
Instance Method Summary collapse
Methods inherited from Bipbip::Plugin
factory, factory_from_plugin, #initialize, #metrics_names, #run, #source_identifier
Methods included from InterruptibleSleep
#interrupt_sleep, #interruptible_sleep
Constructor Details
This class inherits a constructor from Bipbip::Plugin
Instance Attribute Details
#schema ⇒ Object
Returns the value of attribute schema.
6 7 8 |
# File 'lib/bipbip/plugin/command.rb', line 6 def schema @schema end |
Instance Method Details
#metrics_schema ⇒ Object
8 9 10 |
# File 'lib/bipbip/plugin/command.rb', line 8 def metrics_schema @schema ||= find_schema end |
#monitor ⇒ Object
12 13 14 |
# File 'lib/bipbip/plugin/command.rb', line 12 def monitor Hash[command_output.map { |metric, value| [metric, metric_value(value)] }] end |