Aggregate Persistence Support
Introduction
Persisting business data in a database is required in most of the common use cases within a domain service. Making use of DDD concepts like Aggregates or Root Entities is usually a good fit to represent items that should be persisted.
Aggregate Persistence Support in IBM Industry Solutions Workbench
The Aggregate Persistence Support extension offers various capabilities to support in the modelling and implementation of persisting business data.
The extension is available for the following stacks:
- Java Spring Boot Stack 2.0.0 and later
- Supports both MongoDB and DB2 (RDBMS) as database type
- Java Spring Boot Stack 1.0.0 (only for Domain services and always enabled)
- Supports both MongoDB and DB2 (RDBMS) as database type
- NodeJS TypeScript Stack (only for Domain services and always enabled)
- Supports only MongoDB as database type
The extension is only available if Domain Modelling Extension is enabled as well.
Aggregate Persistence Support provides the possibility to model root entities and external entities in domain namespaces, offering the capability to store data in a database. Besides that, the root entities come with the possibility to define commands, which are used to represent business logic that describe the behavior of an aggregate. To learn more about the modelling please inspect the related articels around Root Entities, Commands and Database Collections.
The Aggregate Persistence Support extension also offers convenient functionality while implementation. It takes care that all necessary dependencies are added to the project and also ensures that the connection to the chosen database is established automatically. Besides that, it allows to easily persist aggregates in the database through implementing commands while staying compliant with the domain model. It also offers further capabilities around accessing the data in the database through an automatically generated Repository. To find out more about the implementation capabilities please check Java Spring Boot Implementation and NodeJS TypeScript Implementation.