Sha256: 2808488b77832d6721798aa7a88ec94061dd551cf6a3753136bb056bf52f568d
Contents?: true
Size: 521 Bytes
Versions: 6
Compression:
Stored size: 521 Bytes
Contents
require 'action_dispatch' module Appsignal class Listener def initialize(app, options = {}) @app, @options = app, options end def call(env) Appsignal::Transaction.create(env['action_dispatch.request_id'], env) @app.call(env) rescue Exception => exception unless Appsignal.is_ignored_exception?(exception) Appsignal::Transaction.current.add_exception(exception) end raise exception ensure Appsignal::Transaction.current.complete! end end end
Version data entries
6 entries across 6 versions & 1 rubygems