Class EventSourcingSpanAttributesProviderConfigurationEnhancer
java.lang.Object
org.axonframework.eventsourcing.tracing.configuration.EventSourcingSpanAttributesProviderConfigurationEnhancer
- All Implemented Interfaces:
ConfigurationEnhancer
@Internal
@RegistrationScope("Contribute the providers once at the root; do not re-invoke in child module registries. The registry decorator is copied down on its own - re-invoking per nesting level would register the same providers multiple times, duplicating span attributes.")
public final class EventSourcingSpanAttributesProviderConfigurationEnhancer
extends Object
implements ConfigurationEnhancer
ConfigurationEnhancer contributing the built-in event-sourcing
SpanAttributesProviders to the
SpanAttributesProviderRegistry. Discovered automatically via ServiceLoader.
The EventTagsSpanAttributesProvider requires a TagResolver - a framework-registered component - so
it is only contributed when one is present in the configuration. Contribution is a decorator on the registry
component, so both the EventSourcingTracingSettings.spanAttributesProviders() toggle and the
TagResolver presence are evaluated when the registry is resolved - right before the
SpanFactory consuming it is constructed, once all component
registrations are known.
- Since:
- 5.3.0
- Author:
- Mateusz Nowak
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidenhance(ComponentRegistry registry) intorder()Returns the relative order this enhancer should be invoked in, compared to other instances.
-
Constructor Details
-
EventSourcingSpanAttributesProviderConfigurationEnhancer
public EventSourcingSpanAttributesProviderConfigurationEnhancer()
-
-
Method Details
-
enhance
Description copied from interface:ConfigurationEnhancer- Specified by:
enhancein interfaceConfigurationEnhancer- Parameters:
registry- The registry instance to enhance.
-
order
public int order()Description copied from interface:ConfigurationEnhancerReturns the relative order this enhancer should be invoked in, compared to other instances.Use lower (negative) values for enhancers providing sensible defaults, and higher values for enhancers that should be able to override values potentially previously set. Defaults to
0when not set.- Specified by:
orderin interfaceConfigurationEnhancer- Returns:
- The order in which this enhancer should be invoked.
-