Class: Skylight::Normalizers::Coach::MiddlewareFinish Private

Inherits:
Normalizer show all
Defined in:
lib/skylight/normalizers/coach/middleware_finish.rb

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.

Constant Summary collapse

CAT =

This constant is part of a private API. You should avoid using this constant if possible, as it may be removed or be changed in the future.

"app.coach.middleware".freeze

Instance Attribute Summary

Attributes inherited from Normalizer

#config

Instance Method Summary collapse

Methods inherited from Normalizer

#initialize, #normalize_after, #normalize_with_meta, register

Methods included from Util::Logging

#config_for_logging, #debug, #error, #fmt, #info, #log, #log_context, #raise_on_error?, #t, #trace, #trace?, #warn

Constructor Details

This class inherits a constructor from Skylight::Normalizers::Normalizer

Instance Method Details

#normalize(trace, _name, payload) ⇒ 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.

Called whenever a new middleware is executed. We can expect this to happen within a Coach::Handler.

We can expect the payload to have the :middleware key.



26
27
28
29
# File 'lib/skylight/normalizers/coach/middleware_finish.rb', line 26

def normalize(trace, _name, payload)
  trace.endpoint = payload[:middleware]
  [CAT, payload[:middleware], nil]
end