Class AnnotatedSagaManager.Builder<T>

java.lang.Object
org.axonframework.modelling.saga.AbstractSagaManager.Builder<T>
org.axonframework.modelling.saga.AnnotatedSagaManager.Builder<T>
Type Parameters:
T - a generic specifying the Saga type managed by this AbstractSagaManager implementation
Enclosing class:
AnnotatedSagaManager<T>

public static class AnnotatedSagaManager.Builder<T> extends AbstractSagaManager.Builder<T>
Builder class to instantiate a AnnotatedSagaManager.

The sagaFactory is defaulted to a sagaType.newInstance() call throwing a SagaInstantiationException if it fails, the SpanFactory defaults to a NoOpSpanFactory, and the ListenerInvocationErrorHandler is defaulted to a LoggingErrorHandler.

This Builder either allows directly setting a SagaModel of generic type T, or it will generate one based of the required sagaType field of type Class. Thus, either the SagaModel or the sagaType should be provided. All Sagas managed by this instances must be instanceOf this saga type. Additionally, the SagaRepository and sagaType are hard requirements and as such should be provided.