Sha256: 2e46ddc8924fb6ce921da605f26abf876ea79d11f12b0d0319f2acacfffa93ac

Contents?: true

Size: 672 Bytes

Versions: 12

Compression:

Stored size: 672 Bytes

Contents

module Skylight
  module Normalizers
    module ActionDispatch
      class RouteSet < Normalizer
        register "route_set.action_dispatch"

        CAT = "rack.app".freeze

        def normalize(trace, _name, _payload)
          trace.endpoint = router_class_name
          [CAT, trace.endpoint, nil]
        end

        private

        def router_class_name
          "ActionDispatch::Routing::RouteSet"
        end

        def process_meta_options(_payload)
          # provide hints to override default source_location behavior
          super.merge(source_location_hint: [:own_instance_method, router_class_name, "call"])
        end
      end
    end
  end
end

Version data entries

12 entries across 12 versions & 1 rubygems

Version Path
skylight-5.3.5 lib/skylight/normalizers/action_dispatch/route_set.rb
skylight-5.3.4 lib/skylight/normalizers/action_dispatch/route_set.rb
skylight-5.3.3 lib/skylight/normalizers/action_dispatch/route_set.rb
skylight-5.3.2 lib/skylight/normalizers/action_dispatch/route_set.rb
skylight-5.3.1 lib/skylight/normalizers/action_dispatch/route_set.rb
skylight-5.3.0 lib/skylight/normalizers/action_dispatch/route_set.rb
skylight-5.2.0 lib/skylight/normalizers/action_dispatch/route_set.rb
skylight-5.2.0.beta2 lib/skylight/normalizers/action_dispatch/route_set.rb
skylight-5.2.0.beta lib/skylight/normalizers/action_dispatch/route_set.rb
skylight-5.1.1 lib/skylight/normalizers/action_dispatch/route_set.rb
skylight-5.1.0.beta3 lib/skylight/normalizers/action_dispatch/route_set.rb
skylight-5.1.0.beta2 lib/skylight/normalizers/action_dispatch/route_set.rb