Enhance DDD and Functional Programming with
faggregate
.
faggregate
offers Java developers tools and abstractions to streamline building scalable and robust software. Ideal for any developer level, it maximizes Domain Driven Design Aggregates and functional programming.
The library provides a simple and flexible way to define Aggregates:
- define the data structure of the aggregate's state
- define the commands and events which change the state
- define the side effects : initialization, storing, loading, destroying
- and finally bundle everything with the help of a nice builder
Empower Your Development with DDD Aggregates & Functional Programming - Learn with this Tutorial!
The library handle the transactional part of the Outbox Pattern.
The todo-infra-quarkus example demonstrates the usage of MongoDB to store the state and the domain events of an Aggregate.
The library is designed to be integrated directly into a Native Image.
The todo-infra-quarkus example provides an E2E example leveraging on Quarkus.
The library emphases some functional programing concepts like immutable structures.
The todo-core example provides an implementation leveraging on the Immutables Java library to easily and nicely force the immutable structures of the Aggregate state.
The todo-core module is also used by todo-infra-quarkus. Therefore, it demonstrates Immutables can be used also within common Framework and Native Images.
The library provides a tiny framework (core-scenario) to drive and validate the implementation of side effects.
The todo-core example provides an implementation of scenarios suite.
The todo-infra-quarkus example proves its correctness executing the scenarios suite as an Integration Test.
The library provides an implementation: faggregate-core-simple
.
Its usage can be done manually or via Service Loader.
The artifacts are deployed on GitHub. Therefore, a custom configuration is required to resolve the artifacts, please review Working with the Apache Maven registry.
<dependency>
<groupId>io.morin.faggregate</groupId>
<artifactId>faggregate-core-simple</artifactId>
<version>VERSION</version>
</dependency>
<dependency>
<groupId>io.morin.faggregate</groupId>
<artifactId>faggregate-spi-simple</artifactId>
<version>VERSION</version>
</dependency>
<dependency>
<groupId>io.morin.faggregate</groupId>
<artifactId>faggregate-core-scenario</artifactId>
<version>VERSION</version>
</dependency>
Dependencies upgrade
./mvnw versions:display-dependency-updates
Release
./mvnw --batch-mode release:clean \
&& ./mvnw --batch-mode release:prepare \
-DreleaseVersion=X.Y.Z \
-DdevelopmentVersion=Y.X.Z-SNAPSHOT