Skip to content

Instantly share code, notes, and snippets.

@darkhelmet
Created July 28, 2013 21:08
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save darkhelmet/6100243 to your computer and use it in GitHub Desktop.
Save darkhelmet/6100243 to your computer and use it in GitHub Desktop.
require 'new_relic/agent/instrumentation/sinatra'
module NewRelic
module Agent
module Instrumentation
module Sinatra
def ignore_apdex?
skip = self.response.status.to_i == 404
if skip
env.delete('sinatra.error')
NewRelic::Agent::Transaction.current.exceptions.clear
end
skip
end
end
end
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment