lib/instrumental/agent.rb in instrumental_agent-0.12.6 vs lib/instrumental/agent.rb in instrumental_agent-0.12.7

- old
+ new

@@ -336,10 +336,10 @@ logger.info "connected to collector at #{host}:#{port}" hello_options = { "version" => "ruby/instrumental_agent/#{VERSION}", "hostname" => HOSTNAME, "pid" => Process.pid, - "runtime" => "#{RUBY_ENGINE}/#{RUBY_VERSION}p#{RUBY_PATCHLEVEL}", + "runtime" => "#{defined?(RUBY_ENGINE) ? RUBY_ENGINE : "ruby"}/#{RUBY_VERSION}p#{RUBY_PATCHLEVEL}", "platform" => RUBY_PLATFORM }.to_a.flatten.map { |v| v.to_s.gsub(/\s+/, "_") }.join(" ") send_with_reply_timeout "hello #{hello_options}" send_with_reply_timeout "authenticate #{@api_key}"