Filtering Events Using Metadata Before Processing #482
Replies: 1 comment
-
The docs explain how to implement business rules in the aggregate, before
recording the event. In projectors you type hint in the method signature
which event you want the method to handle. You are then free to do what you
want with the event and data based on any conditions or logic you require,
but at that point the event has already been recorded.
…On Sun, Aug 25, 2024, 2:35 PM Bouba ***@***.***> wrote:
I'm interested in the possibility of filtering events based on metadata
before they reach projections or aggregates in
spatie/laravel-event-sourcing. Specifically:
Is there a built-in mechanism to filter events based on their metadata
before they are processed by projections or aggregates? For example, only
processing MoneyAdded events where the amount is greater than 1000.
—
Reply to this email directly, view it on GitHub
<#482>, or
unsubscribe
<https://github.com/notifications/unsubscribe-auth/ALHJ6SA3MUE6WSAPJWPXEATZTIPYXAVCNFSM6AAAAABNCYLFECVHI2DSMVQWIX3LMV43ERDJONRXK43TNFXW4OZXGA4TGOJYGA>
.
You are receiving this because you are subscribed to this thread.Message
ID: ***@***.***>
|
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
b-barry
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I'm interested in the possibility of filtering events based on metadata before they reach projections or aggregates in spatie/laravel-event-sourcing. Specifically:
Is there a built-in mechanism to filter events based on their metadata before they are processed by projections or aggregates? For example, only processing MoneyAdded events where the amount is greater than 1000.
Beta Was this translation helpful? Give feedback.
All reactions