Class: Skylight::Core::Probes::Excon::Middleware Private
- Inherits:
-
Excon::Middleware::Base
- Object
- Excon::Middleware::Base
- Skylight::Core::Probes::Excon::Middleware
- Includes:
- Util::Logging
- Defined in:
- lib/skylight/core/probes/excon/middleware.rb
Overview
This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.
Middleware for Excon that instruments requests
Instance Method Summary collapse
- #error_call(datum) ⇒ Object private
-
#initialize ⇒ Middleware
constructor
private
A new instance of Middleware.
-
#request_call(datum) ⇒ Object
private
TODO: - Consider whether a LIFO queue would be sufficient - Check that errors can’t be called without a request.
- #response_call(datum) ⇒ Object private
Methods included from Util::Logging
#config_for_logging, #debug, #error, #fmt, #info, #log, #log_context, #log_env_prefix, #raise_on_error?, #t, #trace, #trace?, #warn
Constructor Details
#initialize ⇒ Middleware
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Returns a new instance of Middleware.
13 14 15 16 |
# File 'lib/skylight/core/probes/excon/middleware.rb', line 13 def initialize(*) @requests = {} super end |
Instance Method Details
#error_call(datum) ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
33 34 35 36 37 |
# File 'lib/skylight/core/probes/excon/middleware.rb', line 33 def error_call(datum) super ensure end_instrumentation(datum) end |
#request_call(datum) ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
TODO:
-
Consider whether a LIFO queue would be sufficient
-
Check that errors can’t be called without a request
22 23 24 25 |
# File 'lib/skylight/core/probes/excon/middleware.rb', line 22 def request_call(datum) begin_instrumentation(datum) super end |
#response_call(datum) ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
27 28 29 30 31 |
# File 'lib/skylight/core/probes/excon/middleware.rb', line 27 def response_call(datum) super ensure end_instrumentation(datum) end |