lib/one_apm/inst/nosql/redis.rb in oneapm_rpm-1.1.3 vs lib/one_apm/inst/nosql/redis.rb in oneapm_rpm-1.2.0

- old
+ new

@@ -12,11 +12,11 @@ executes do OneApm::Manager.logger.info 'Installing Redis Instrumentation' end executes do - require 'one_apm/agent/datastores' + require 'one_apm/agent/datastore' ::Redis::Client.class_eval do # Support older versions of Redis::Client that used the method # +raw_call_command+. @@ -26,11 +26,11 @@ method_name = args[0].is_a?(Array) ? args[0][0] : args[0] callback = proc do |result, metric, elapsed| _send_to_one_apm(args, elapsed) end - OneApm::Agent::Datastores.wrap("Redis", method_name, nil, callback) do + OneApm::Agent::Datastore.wrap("Redis", method_name, nil, callback) do call_without_oneapm_trace(*args, &blk) end end alias_method :call_without_oneapm_trace, call_method @@ -55,11 +55,11 @@ # No-op, just getting them as placeholders in the trace tree end end end - OneApm::Agent::Datastores.wrap("Redis", "pipelined", nil, callback) do + OneApm::Agent::Datastore.wrap("Redis", "pipelined", nil, callback) do call_pipelined_without_oneapm_trace commands, *rest end end alias_method :call_pipelined_without_oneapm_trace, :call_pipelined @@ -74,10 +74,10 @@ else [arg.first] + ["?"] * (arg.count - 1) end end end - OneApm::Agent::Datastores.notice_statement(args.inspect, elapsed) + OneApm::Agent::Datastore.notice_statement(args.inspect, elapsed) end end end end