Class: Chronos::Core::RuntimeInfo

Inherits:
Object
  • Object
show all
Defined in:
lib/chronos/core/runtime_info.rb

Overview

Collects low-cost runtime identifiers for an event.

Examples:

Chronos::Core::RuntimeInfo.new.call

Instance Method Summary collapse

Instance Method Details

#callObject



16
17
18
19
20
21
22
23
24
25
26
27
# File 'lib/chronos/core/runtime_info.rb', line 16

def call
  {
    :runtime => {
      "ruby_version" => RUBY_VERSION,
      "ruby_engine" => ruby_engine,
      "platform" => RUBY_PLATFORM
    },
    :host => safe_hostname,
    :process => {"pid" => Process.pid},
    :thread => {"id" => Thread.current.object_id.to_s}
  }
end