Method: Oxidized::Node#serialize
- Defined in:
- lib/oxidized/node.rb
#serialize ⇒ Object
102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 |
# File 'lib/oxidized/node.rb', line 102 def serialize h = { name: @name, full_name: @name, ip: @ip, group: @group, model: @model.class.to_s, last: nil, vars: @vars, mtime: @stats.mtime } h[:full_name] = [@group, @name].join('/') if @group if @last h[:last] = { start: @last.start, end: @last.end, status: @last.status, time: @last.time } end h end |