lib/plain_apm/agent.rb in plain_apm-0.2.8 vs lib/plain_apm/agent.rb in plain_apm-0.2.9
- old
+ new
@@ -1,9 +1,10 @@
# frozen_string_literal: true
require "singleton"
require "json"
+require "socket"
module PlainApm
class Agent
include Singleton
@@ -28,9 +29,10 @@
end
event.merge!(
"version" => PlainApm::VERSION,
"collected_at" => Time.now.utc.to_f,
+ "hostname" => Socket.gethostname,
"pid" => Process.pid,
"thread_id" => Thread.current.object_id.to_s,
)
@events << event