spring-projects / spring-projects/spring-data-commons

Improve support for immutability for @AfterEventPublication [DATACMNS-1644]

Open
#2,069 0 comments 0 reactions 1 assignee View on GitHub

@odrotbohm is already working on this.

Since Dec 30, 2020.

in: core in: repository in: web type: enhancement
Dominant language
Java
Stars
838
Forks
730
PR merge metrics
No merged PRs in 30d

Description

Oliver Drotbohm opened DATACMNS-1644 and commented

The support to publish domain events from aggregates leverages @AfterDomainEventPublication to trigger event resets in the aggregate. Implementations usually wipe out a collection which assumes mutability of the aggregate.

We could change that by inspecting the return type of the method annotated and use the value returned if it is assignable to the aggregate type


No further details from DATACMNS-1644

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.