All Classes and Interfaces

Class
Description
Strategy for when an aggregate snapshot should be added
 
Common interface that all concrete (classical) Aggregate's must implement.
 
A specialized and opinionated mutable Aggregate design
This AggregateRoot is designed to work with Class based Event's that inherit from Event.
This design is deliberate and will manage a lot of things for you as a developer at the cost of some flexibility.
A modern opinionated interpretation of the classic AggregateRoot design, where the Event's are mutable.
The modern interpretation doesn't specify any requirement on the design of the Events, they can be Java 17+ records or simple POJO's.

Note: The AggregateRoot works best in combination with the StatefulAggregateRepository that's configured to use the StatefulAggregateInstanceFactory.reflectionBasedAggregateRootFactory(), because the AggregateRoot needs to be provided its aggregated id through the AggregateRoot(Object) constructor!

The modern AggregateRoot supports keeping the state projection and EventHandler annotated methods within the AggregateRoot instance or within an AggregateState instance.
If you wish to keep the state projection and EventHandler annotated methods within an AggregateState instance, then you only need to implement the WithState interface:
Variant of the AggregateRoot pattern where the aggregate's state and all EventHandler annotated methods are placed within the concrete AggregateState object.
When the AggregateRootWithState is combined with AggregateState, then the AggregateRootWithState will contain the command methods and the AggregateState contains the state fields and the EventHandler annotated methods.
Strategy for which historic aggregate snapshots (i.e.
Strategy that deletes any historic aggregate snapshots when a new snapshot is persisted
Strategy that keeps all or a specific number of historic aggregate snapshots
Repository storing and updating Aggregate instance snapshots
Base class for the state object associated with AggregateRootWithState.
When this is combined with the AggregateRootWithState when the AggregateRootWithState will contain the command methods and the AggregateState contains the state fields and the EventHandler annotated methods.
Aggregate state object associated with a given AggregateRoot instance (see AggregateState.getAggregate())
Example:
AggregateSnapshot.aggregateSnapshot value that's returned from AggregateSnapshotRepository in case the Aggregate snapshot couldn't be deserialized
Delegating AggregateSnapshotRepository which directly delegates all operations to the provided delegateRepository, except for AggregateSnapshotRepository.aggregateUpdated(Object, AggregateEventStream), AggregateSnapshotRepository.deleteSnapshots(AggregateType, Object, Class, List), which are performed asynchronously in the background.
This ensures that expensive update/clean-up for aggregate snapshots in the database don't affect aggregate persistence performance.
Based Event type that's built to work in combination with AggregateRoot
All you need to do is to inherit from this class when building your own Event types.
Methods annotated with this Annotation will automatically be called when an event is being applied or rehydrated on to an Aggregate instance
Wrapper object that captures the results of any command handling (e.g.
Simple, easy and opinionated aggregate that allows you to apply events that don't have any requirements with regards to inheritance (i.e.
Opinionated FlexAggregate Repository that's built to persist and load a specific FlexAggregate type in combination with EventStore, EventStoreUnitOfWorkFactory and a FlexAggregateRepository.
 
 
 
 
A stateful Aggregate is the most common form of Aggregate design in Object Oriented languages.
What makes an Aggregate stateful is the fact that any changes, i.e.
Aggregate specific InMemoryProjector
Note: An in memory projection is never associated with a UnitOfWork and any changes to the aggregate won't automatically be persisted.
Factory that helps the StatefulAggregateRepository/StatefulAggregateInMemoryProjector to create an instance of a given Aggregate.
StatefulAggregateInstanceFactory that uses Objenesis to create a new instance of the Aggregate
Please note: Objenesis doesn't initialize fields nor call any constructors, so you Aggregate design needs to take this into consideration.
All concrete aggregates that extends AggregateRoot have been prepared to be initialized by Objenesis
StatefulAggregateInstanceFactory that calls the default no-arguments constructor on the concrete Aggregate type to create a new instance of the Aggregate
Opinionated Aggregate Repository that's built to persist and load a specific StatefulAggregate type in combination with EventStore, UnitOfWorkFactory and a StatefulAggregateInstanceFactory.
You can use the StatefulAggregateRepository.from(ConfigurableEventStore, AggregateEventStreamConfiguration, StatefulAggregateInstanceFactory, Class) to create a new StatefulAggregateRepository instance that supports the most common repository method.
Alternatively you can extend from the StatefulAggregateRepository.DefaultStatefulAggregateRepository and add your own special methods
Default StatefulAggregateRepository implementation.
Marker interface that indicates that all state and all EventHandler annotated methods will be hosted with the AggregateState object.