Class DefaultQueryBusSpanFactory.Builder
java.lang.Object
org.axonframework.messaging.queryhandling.tracing.DefaultQueryBusSpanFactory.Builder
- Enclosing class:
DefaultQueryBusSpanFactory
Builder class to instantiate a
DefaultQueryBusSpanFactory. The default values are:
distributedInSameTracedefaults totrue
spanFactory is a required field and should be provided.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()Initializes aDefaultQueryBusSpanFactoryas specified through this Builder.distributedInSameTrace(boolean distributedInSameTrace) Sets whether the distributed query should be in the same trace as the parent.spanFactory(SpanFactory spanFactory) Sets theSpanFactoryto use to create the spans.protected voidvalidate()Validates whether the fields contained in this builder are set accordingly.
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
spanFactory
Sets theSpanFactoryto use to create the spans. This is a required field.- Parameters:
spanFactory- TheSpanFactoryto use to create the spans.- Returns:
- The current Builder instance, for fluent interfacing.
-
distributedInSameTrace
Sets whether the distributed query should be in the same trace as the parent. Defaults totrue.- Parameters:
distributedInSameTrace- whether the distributed query should be in the same trace as the parent.- Returns:
- The current Builder instance, for fluent interfacing.
-
validate
protected void validate()Validates whether the fields contained in this builder are set accordingly. -
build
Initializes aDefaultQueryBusSpanFactoryas specified through this Builder.- Returns:
- The
DefaultQueryBusSpanFactoryas specified through this Builder.
-