Class: OsCtld::CpuScheduler::PackageInfo
- Inherits:
-
Struct
- Object
- Struct
- OsCtld::CpuScheduler::PackageInfo
- Defined in:
- lib/osctld/cpu_scheduler.rb
Instance Attribute Summary collapse
-
#container_count ⇒ Object
Returns the value of attribute container_count.
-
#cpu_mask ⇒ Object
Returns the value of attribute cpu_mask.
-
#enabled ⇒ Object
Returns the value of attribute enabled.
-
#id ⇒ Object
Returns the value of attribute id.
-
#usage_score ⇒ Object
Returns the value of attribute usage_score.
Instance Method Summary collapse
Instance Attribute Details
#container_count ⇒ Object
Returns the value of attribute container_count
45 46 47 |
# File 'lib/osctld/cpu_scheduler.rb', line 45 def container_count @container_count end |
#cpu_mask ⇒ Object
Returns the value of attribute cpu_mask
45 46 47 |
# File 'lib/osctld/cpu_scheduler.rb', line 45 def cpu_mask @cpu_mask end |
#enabled ⇒ Object
Returns the value of attribute enabled
45 46 47 |
# File 'lib/osctld/cpu_scheduler.rb', line 45 def enabled @enabled end |
#id ⇒ Object
Returns the value of attribute id
45 46 47 |
# File 'lib/osctld/cpu_scheduler.rb', line 45 def id @id end |
#usage_score ⇒ Object
Returns the value of attribute usage_score
45 46 47 |
# File 'lib/osctld/cpu_scheduler.rb', line 45 def usage_score @usage_score end |
Instance Method Details
#container_count_per_cpu ⇒ Object
57 58 59 |
# File 'lib/osctld/cpu_scheduler.rb', line 57 def container_count_per_cpu container_count / cpu_mask.size.to_f end |
#usage_score_per_cpu ⇒ Object
53 54 55 |
# File 'lib/osctld/cpu_scheduler.rb', line 53 def usage_score_per_cpu usage_score / cpu_mask.size.to_f end |