Class: Skylight::Core::Normalizers::ActiveJob::Perform Private
- Inherits:
-
Normalizer
- Object
- Normalizer
- Skylight::Core::Normalizers::ActiveJob::Perform
- Defined in:
- lib/skylight/core/normalizers/active_job/perform.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.job.perform".freeze
Instance Attribute Summary
Attributes inherited from Normalizer
Instance Method Summary collapse
- #normalize(trace, _name, payload) ⇒ Object private
- #normalize_after(trace, _span, _name, payload) ⇒ Object private
Methods inherited from Normalizer
Constructor Details
This class inherits a constructor from Skylight::Core::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.
9 10 11 12 13 14 15 16 17 |
# File 'lib/skylight/core/normalizers/active_job/perform.rb', line 9 def normalize(trace, _name, payload) title = normalize_title(payload[:job]) adapter_name = normalize_adapter_name(payload[:adapter]) desc = "{ adapter: '#{adapter_name}', queue: '#{payload[:job].queue_name}' }" trace.endpoint = title if assign_endpoint?(trace, payload) [ CAT, title, desc ] end |
#normalize_after(trace, _span, _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.
19 20 21 22 23 |
# File 'lib/skylight/core/normalizers/active_job/perform.rb', line 19 def normalize_after(trace, _span, _name, payload) return unless config.enable_segments? && assign_endpoint?(trace, payload) trace.endpoint += "<sk-segment>#{payload[:job].queue_name}</sk-segment>" end |