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

Create concept of PublishedEvent #5

Open
pilloPl opened this issue Mar 28, 2019 · 2 comments
Open

Create concept of PublishedEvent #5

pilloPl opened this issue Mar 28, 2019 · 2 comments

Comments

@pilloPl
Copy link
Member

pilloPl commented Mar 28, 2019

So currently the all of the domain events have information about business facts.

If we want to publish them we need to add metadata like:

causationID,
corellationID,
uniqueMessageID
etc

so PublishedEvent becomes DomainEvent + metadata

@ghost
Copy link

ghost commented Apr 17, 2019

So, if I understand correctly, do you mean that

public interface EventsStorage {

    void save(DomainEvent event);

    List<DomainEvent> toPublish();

    void published(List<DomainEvent> events);
}

should be more like

public interface EventsStorage {

    void save(DomainEvent event);

    List<DomainEvent> toPublish();

    void published(List<PublishedEvent> events);
}

@pilloPl
Copy link
Member Author

pilloPl commented May 8, 2019

I mean that PublishedEvent should keep DomainEvent inside :)

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

1 participant