Class: OpenTelemetry::Instrumentation::Rack::Instrumentation
- Inherits:
-
Base
- Object
- Base
- OpenTelemetry::Instrumentation::Rack::Instrumentation
- Defined in:
- lib/opentelemetry/instrumentation/rack/instrumentation.rb
Overview
The Instrumentation class contains logic to detect and install the Rack instrumentation
Instance Method Summary collapse
-
#middleware_args ⇒ Array
Temporary Helper for Sinatra and ActionPack middleware to use during installation.
Instance Method Details
#middleware_args ⇒ Array
Temporary Helper for Sinatra and ActionPack middleware to use during installation
42 43 44 45 46 47 48 |
# File 'lib/opentelemetry/instrumentation/rack/instrumentation.rb', line 42 def middleware_args if config.fetch(:use_rack_events, false) == true && defined?(OpenTelemetry::Instrumentation::Rack::Middlewares::EventHandler) [::Rack::Events, [OpenTelemetry::Instrumentation::Rack::Middlewares::EventHandler.new]] else [OpenTelemetry::Instrumentation::Rack::Middlewares::TracerMiddleware] end end |