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

Overdue deterministic fix #1819

Draft
wants to merge 4 commits into
base: master
Choose a base branch
from
Draft

Overdue deterministic fix #1819

wants to merge 4 commits into from

Conversation

pierre
Copy link
Member

@pierre pierre commented Dec 12, 2022

See discussion here.

When running the OverdueStateApplicator logic, a lot of actions
can be triggered on different sub-systems:

* Cancellation of subscriptions
* Transition into / out of AUTO_INVOICE_OFF
* New blocking states set

These actions potentially send events on the bus that invoice will
react to, and the timing of these actions can make the resulting
invoice(s) non-deterministic.

This patch:

* Delays sending AUTO_INVOICE_OFF events until after the new blocking states are set
* Sets and unsets AUTO_INVOICE_OFF around the whole overdue logic when cancelling subscriptions

Signed-off-by: Pierre-Alexandre Meyer <pierre@mouraf.org>
Make sure that in case of rollbacks (potentially wrong) mappings are not cached.

Signed-off-by: Pierre-Alexandre Meyer <pierre@mouraf.org>
Signed-off-by: Pierre-Alexandre Meyer <pierre@mouraf.org>
Signed-off-by: Pierre-Alexandre Meyer <pierre@mouraf.org>
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.

None yet

2 participants