-
Notifications
You must be signed in to change notification settings - Fork 5
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
[Experimental] Stream Store #620
Conversation
a8a9b71
to
8759f9a
Compare
Hello 👋 here is the most recent benchmark result:
This comment gets update everytime a new commit comes in! |
8759f9a
to
767302d
Compare
fd3b5ff
to
d2f82b8
Compare
src/Console/OutputStyle.php
Outdated
private function streamName(AggregateHeader|StreamHeader $header): string | ||
{ | ||
if ($header instanceof AggregateHeader) { | ||
return StreamNameTranslator::streamName($header->aggregateName, $header->aggregateId); | ||
} | ||
|
||
return $header->streamName; | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
maybe this should go into the StreamNameTranslator
itself? Since this is done in another places in a different style
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Then we have an dependency aggregate->message
.
Currently, the aggregate knows nothing about messages. (Except for the AggregateHeader
, which will be removed in the long term)
In 4.0, StreamNameTranslator
can also be removed again; it is mainly needed as a BC layer.
I want to solve this with metadata.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You mean domain wise? I mean, the Translator could also be moved into Store
, which is imho even a better place, no?
I know that this translator acts as a BC layer, if the remove the "old" store in favor of the new StreamStore
. I'm fine keeping it as is right now, but if we encounter a third place, i would vote for getting this more centralized.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How the stream name is composed is the task of the Aggregate/Repository domain. The store should not know anything about aggregate. In the future, only the repository will create this string. So, this is not a BC layer for the store, but a BC layer for the repository/aggregate which store it can work with.
I don't know if the Aggregate namespace is the right place. Maybe repository? But in my opinion, definitely not store.
One last thing: Maybe we should add somewhere a note what to expect from a experimental feature? Like no BC compliance etc? |
We should generally communicate how we handle our versions. Which versions are still supported, etc. I opened an issue: #622 |
This pull request introduces an event store that is decoupled from the aggregate root. This means that the columns
aggregate
andaggregateId
have been merged intostream
. Playhead is also optional in this store.fix: #535