lib/ddtrace/contrib/rails/action_view.rb in ddtrace-0.7.2 vs lib/ddtrace/contrib/rails/action_view.rb in ddtrace-0.8.0

- old
+ new

@@ -5,11 +5,11 @@ module Rails # TODO[manu]: write docs module ActionView def self.instrument # patch Rails core components - Datadog::RailsPatcher.patch_renderer() + Datadog::RailsRendererPatcher.patch_renderer() # subscribe when the template rendering starts ::ActiveSupport::Notifications.subscribe('start_render_template.action_view') do |*args| start_render_template(*args) end @@ -81,11 +81,11 @@ span.set_tag(Datadog::Ext::Errors::TYPE, error[0]) span.set_tag(Datadog::Ext::Errors::MSG, error[1]) end ensure span.start_time = start - span.finish_at(finish) + span.finish(finish) end rescue StandardError => e Datadog::Tracer.log.error(e.message) end @@ -109,10 +109,10 @@ span.set_tag(Datadog::Ext::Errors::TYPE, error[0]) span.set_tag(Datadog::Ext::Errors::MSG, error[1]) end ensure span.start_time = start - span.finish_at(finish) + span.finish(finish) end rescue StandardError => e Datadog::Tracer.log.error(e.message) end end