Why is EventSourcingHandler (in aggregate object) needed?
问题 Fair warning: I have no idea what I'm doing, so even the asking of this question may go awry. I'm wanting to update state on a simple object (the Aggregate) and then provide the UI with a projection of the changed object. Here's my aggregate object (command handler exists, but not shown here). @Aggregate public class Widget { @AggregateIdentifier private String id; private String color; ... @EventSourcingHandler public void on(ChangeColorEvt evt) { color = evt.getColor(); } ... } ...and here