Class AggregateRolledBackException
java.lang.Object
java.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
org.axonframework.common.AxonException
org.axonframework.modelling.command.AggregateRolledBackException
- All Implemented Interfaces:
Serializable
Exception indicating that an aggregate has been part of a Unit of Work that was rolled back and that the validity of
its state cannot be guaranteed.
This typically occurs when multiple nested Units of Work operate on the same Aggregate instance, and that one of these Units of Work has been rolled back. In such case, the parent Unit of Work cannot guarantee that the state of the Aggregate is correct, and should (in such case) be rolled back.
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionAggregateRolledBackException(String aggregateIdentifier) Initialize the exception for an aggregate with givenaggregateIdentifier. -
Method Summary
Modifier and TypeMethodDescriptionReturns the identifier of the compromised aggregate.Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
Constructor Details
-
AggregateRolledBackException
Initialize the exception for an aggregate with givenaggregateIdentifier.- Parameters:
aggregateIdentifier- The identifier of the compromised aggregate
-
-
Method Details
-
getAggregateIdentifier
Returns the identifier of the compromised aggregate.- Returns:
- the identifier of the compromised aggregate
-