lib/ddtrace/contrib/http/patcher.rb in ddtrace-0.29.1 vs lib/ddtrace/contrib/http/patcher.rb in ddtrace-0.30.0
- old
+ new
@@ -10,22 +10,16 @@
module Patcher
include Contrib::Patcher
module_function
- def patched?
- done?(:http)
+ def target_version
+ Integration.version
end
# patch applies our patch if needed
def patch
- do_once(:http) do
- begin
- ::Net::HTTP.send(:include, Instrumentation)
- rescue StandardError => e
- Datadog::Tracer.log.error("Unable to apply net/http integration: #{e}")
- end
- end
+ ::Net::HTTP.send(:include, Instrumentation)
end
end
end
end
end