Class: PhusionPassenger::AdminTools::MemoryStats::Process
- Inherits:
-
Object
- Object
- PhusionPassenger::AdminTools::MemoryStats::Process
- Defined in:
- lib/phusion_passenger/admin_tools/memory_stats.rb
Overview
Information about a single process.
Instance Attribute Summary (collapse)
-
- (Object) cpu
Returns the value of attribute cpu.
-
- (Object) name
Returns the value of attribute name.
-
- (Object) pid
Returns the value of attribute pid.
-
- (Object) ppid
Returns the value of attribute ppid.
-
- (Object) private_dirty_rss
in KB.
-
- (Object) rss
in KB in KB.
-
- (Object) threads
Returns the value of attribute threads.
-
- (Object) vm_size
Returns the value of attribute vm_size.
Instance Method Summary (collapse)
Instance Attribute Details
- (Object) cpu
Returns the value of attribute cpu
37 38 39 |
# File 'lib/phusion_passenger/admin_tools/memory_stats.rb', line 37 def cpu @cpu end |
- (Object) name
Returns the value of attribute name
38 39 40 |
# File 'lib/phusion_passenger/admin_tools/memory_stats.rb', line 38 def name @name end |
- (Object) pid
Returns the value of attribute pid
32 33 34 |
# File 'lib/phusion_passenger/admin_tools/memory_stats.rb', line 32 def pid @pid end |
- (Object) ppid
Returns the value of attribute ppid
33 34 35 |
# File 'lib/phusion_passenger/admin_tools/memory_stats.rb', line 33 def ppid @ppid end |
- (Object) private_dirty_rss
in KB
39 40 41 |
# File 'lib/phusion_passenger/admin_tools/memory_stats.rb', line 39 def private_dirty_rss @private_dirty_rss end |
- (Object) rss
in KB in KB
36 37 38 |
# File 'lib/phusion_passenger/admin_tools/memory_stats.rb', line 36 def rss @rss end |
- (Object) threads
Returns the value of attribute threads
34 35 36 |
# File 'lib/phusion_passenger/admin_tools/memory_stats.rb', line 34 def threads @threads end |
- (Object) vm_size
Returns the value of attribute vm_size
35 36 37 |
# File 'lib/phusion_passenger/admin_tools/memory_stats.rb', line 35 def vm_size @vm_size end |
Instance Method Details
- (Object) private_dirty_rss_in_mb
49 50 51 52 53 54 55 |
# File 'lib/phusion_passenger/admin_tools/memory_stats.rb', line 49 def private_dirty_rss_in_mb if private_dirty_rss.is_a?(Numeric) return sprintf("%.1f MB", private_dirty_rss / 1024.0) else return "?" end end |
- (Object) rss_in_mb
45 46 47 |
# File 'lib/phusion_passenger/admin_tools/memory_stats.rb', line 45 def rss_in_mb return sprintf("%.1f MB", rss / 1024.0) end |
- (Object) to_a
57 58 59 |
# File 'lib/phusion_passenger/admin_tools/memory_stats.rb', line 57 def to_a return [pid, ppid, vm_size_in_mb, private_dirty_rss_in_mb, rss_in_mb, name] end |
- (Object) vm_size_in_mb
41 42 43 |
# File 'lib/phusion_passenger/admin_tools/memory_stats.rb', line 41 def vm_size_in_mb return sprintf("%.1f MB", vm_size / 1024.0) end |