class StackifyRubyAPM::Spies::ActionDispatchSpy
@api private
Public Instance Methods
install()
click to toggle source
# File lib/stackify_apm/spies/action_dispatch.rb, line 10 def install ::ActionDispatch::ShowExceptions.class_eval do alias_method 'render_exception_without_apm', 'render_exception' def render_exception(env, exception) # Creates exception log report # begin StackifyRubyAPM.report(exception) rescue Exception => e StackifyRubyAPM.agent.error '[ActionDispatchSpy] Error: repoting exception.' StackifyRubyAPM.agent.error "[ActionDispatchSpy] #{e.inspect}" end render_exception_without_apm env, exception end end end
render_exception(env, exception)
click to toggle source
# File lib/stackify_apm/spies/action_dispatch.rb, line 14 def render_exception(env, exception) # Creates exception log report # begin StackifyRubyAPM.report(exception) rescue Exception => e StackifyRubyAPM.agent.error '[ActionDispatchSpy] Error: repoting exception.' StackifyRubyAPM.agent.error "[ActionDispatchSpy] #{e.inspect}" end render_exception_without_apm env, exception end