Class: HealthMode::CPUMetric
Class Attribute Summary collapse
-
.cpu_idle ⇒ Object
Returns the value of attribute cpu_idle.
-
.cpu_iowait ⇒ Object
Returns the value of attribute cpu_iowait.
-
.cpu_irq ⇒ Object
Returns the value of attribute cpu_irq.
-
.cpu_nice ⇒ Object
Returns the value of attribute cpu_nice.
-
.cpu_softirq ⇒ Object
Returns the value of attribute cpu_softirq.
-
.cpu_system ⇒ Object
Returns the value of attribute cpu_system.
-
.cpu_user ⇒ Object
Returns the value of attribute cpu_user.
-
.system_metrics ⇒ Object
Returns the value of attribute system_metrics.
Class Method Summary collapse
Class Attribute Details
.cpu_idle ⇒ Object
Returns the value of attribute cpu_idle.
4 5 6 |
# File 'lib/metrics/cpu_metric.rb', line 4 def cpu_idle @cpu_idle end |
.cpu_iowait ⇒ Object
Returns the value of attribute cpu_iowait.
4 5 6 |
# File 'lib/metrics/cpu_metric.rb', line 4 def cpu_iowait @cpu_iowait end |
.cpu_irq ⇒ Object
Returns the value of attribute cpu_irq.
4 5 6 |
# File 'lib/metrics/cpu_metric.rb', line 4 def cpu_irq @cpu_irq end |
.cpu_nice ⇒ Object
Returns the value of attribute cpu_nice.
4 5 6 |
# File 'lib/metrics/cpu_metric.rb', line 4 def cpu_nice @cpu_nice end |
.cpu_softirq ⇒ Object
Returns the value of attribute cpu_softirq.
4 5 6 |
# File 'lib/metrics/cpu_metric.rb', line 4 def cpu_softirq @cpu_softirq end |
.cpu_system ⇒ Object
Returns the value of attribute cpu_system.
4 5 6 |
# File 'lib/metrics/cpu_metric.rb', line 4 def cpu_system @cpu_system end |
.cpu_user ⇒ Object
Returns the value of attribute cpu_user.
4 5 6 |
# File 'lib/metrics/cpu_metric.rb', line 4 def cpu_user @cpu_user end |
.system_metrics ⇒ Object
Returns the value of attribute system_metrics.
4 5 6 |
# File 'lib/metrics/cpu_metric.rb', line 4 def system_metrics @system_metrics end |
Class Method Details
.current_state ⇒ Object
13 14 15 16 17 18 19 20 21 22 23 24 |
# File 'lib/metrics/cpu_metric.rb', line 13 def current_state refresh_state { "cpu_user" => @cpu_user, "cpu_nice" => @cpu_nice, "cpu_system" => @cpu_system, "cpu_iowait" => @cpu_iowait, "cpu_irq" => @cpu_irq, "cpu_idle" => @cpu_idle, "cpu_softirq" => @cpu_softirq } end |