|
Hi was looking trough the examples and saw stated the folowing. and i wondered why it is that way : in here (guestlist projector ) we pass on the repo, and do the saving within the projector in the invitation projector itself. we return the model, and do the saving outside the projecter. why are these handled differently? and what are the determing factors to use either one. |
Answered by
maxekman
Jan 21, 2021
Replies: 2 comments
|
In general when there is a one-to-one relationship between an aggregate ID and projected entity ID a projector should be used. The GuestListProjector is an example of a different kind of projector which is not one-to-one with the event IDs, it uses a fixed ID (for the duration of the test/run) in this case which is used as a statistic collector. |
0 replies
Answer selected by
maxekman
|
thank you for clarifying, it makes sense now! |
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
In general when there is a one-to-one relationship between an aggregate ID and projected entity ID a projector should be used.
The GuestListProjector is an example of a different kind of projector which is not one-to-one with the event IDs, it uses a fixed ID (for the duration of the test/run) in this case which is used as a statistic collector.