Sync subscriptions - #338
Merged
Merged
Conversation
Merged
…nc option Subscriptions can now be processed sync after an aggregate has been saved, filtered by ids and groups, while the rest is still handled by the worker. Catch up and throw on error only apply to this sync run and no longer decorate the global subscription engine used by the worker and commands.
DavidBadura
force-pushed
the
sync-subscriptions
branch
from
October 3, 2026 15:36
d568cfa to
1132252
Compare
DanielBadura
approved these changes
Oct 3, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Until now the subscription engine was either run in a worker or reconfigured for dev to run everything after an aggregate was saved. This replaces
catch_up,throw_on_errorandrun_after_aggregate_savewith a singlesyncoption, so both modes can be combined.With
sync: trueall subscriptions run directly after saving an aggregate, which is what you want in dev and test. In prod you can limit it withidsandgroups, e.g.groups: ['sync'], and everything else stays async in the worker. The worker still processes sync subscriptions too, so failed ones get retried.Catch up is always active for the sync run and can be limited with
catch_up_limit. Catch up andthrow_on_errornow only wrap a dedicated sync engine instead of decorating the global one, so the worker and console commands are no longer affected.Docs are updated and the upgrade guide got a section for the new option.