Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ReceiveRecover and IEvent #2

Open
varghesep opened this issue Jun 28, 2015 · 1 comment
Open

ReceiveRecover and IEvent #2

varghesep opened this issue Jun 28, 2015 · 1 comment

Comments

@varghesep
Copy link

First of all, I want to say that this is an awesome example that I have seen in the area of CQRS with AKKA.NET.

In lines 64 to 67 in the ReceiveRecover method, I see that ReceiveRecover can get an event other than the SnapshotOffer and it will update the state. I don't see a case that can happen other than it receives an event like RecoveryCompleted which should not update the state.

Could you please clarify when it is necessary to update the state in a ReceiveRecover method?

@Horusiath
Copy link
Owner

IEvent is custom marker interface defined for purpose of the project here. Each domain event used in this sample implements it. This sets a barrier on programmer preventing from accidentally trying to update the state of an aggregate from objects other than domain events.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants