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

Passed stream headers to aggregate factory #25

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Passed stream headers to aggregate factory #25

wants to merge 1 commit into from

Conversation

aleksandrov
Copy link

I propose to change interface IConstructAggregates to pass to factory stream headers.

That's convenient - load aggregate by interface (for example IOwner), but stored events were generated by interface implementation (and stream header AggregateType points to concrete implementation of interface IOwner).

If my explanation is unclear, I'll provide more detailed example.

Regards,
Dmitry

@gaevoy
Copy link

gaevoy commented Sep 12, 2013

+1 Helpful feature to load aggregate by some interface.

var entity = repo.GetById<IAggregateCloneable>(cmd.Id);
var clone = entity.Clone(cmd.CloneId);
repo.Save(clone);

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

Successfully merging this pull request may close these issues.

2 participants