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
Multiple triggered interrupting boundary events can deadlock process instance #9233
Comments
Love that you use zdb @korthout :) I guess this also applies to interrupting event sub processes. |
Perhaps |
Let's look into a bug fix for this issue, and create a follow-up issue for the bigger scope of considering our termination logic, to "quicken" the termination process as discussed in the team meeting, i.e. preventing new "actions" to happen in a process instance. |
AnalyzeIt is a general issue with boundary events. We write the I can reproduce the issue if the top level process has an interrupting boundary event on the call activity or an interrupting event subprocess. |
9293: [Backport 1.3] Trigger boundary events only if the flow scope is active r=saig0 a=saig0 ## Description Backport of #9281 Only one additional change compared to the origin PR for downgrading the test code to Java 11. ## Related issues relates to #9233 Co-authored-by: Philipp Ossler <philipp.ossler@gmail.com>
9293: [Backport 1.3] Trigger boundary events only if the flow scope is active r=saig0 a=saig0 ## Description Backport of #9281 Only one additional change compared to the origin PR for downgrading the test code to Java 11. ## Related issues relates to #9233 Co-authored-by: Philipp Ossler <philipp.ossler@gmail.com>
9293: [Backport 1.3] Trigger boundary events only if the flow scope is active r=saig0 a=saig0 ## Description Backport of #9281 Only one additional change compared to the origin PR for downgrading the test code to Java 11. ## Related issues relates to #9233 Co-authored-by: Philipp Ossler <philipp.ossler@gmail.com>
9293: [Backport 1.3] Trigger boundary events only if the flow scope is active r=saig0 a=saig0 ## Description Backport of #9281 Only one additional change compared to the origin PR for downgrading the test code to Java 11. ## Related issues relates to #9233 Co-authored-by: Philipp Ossler <philipp.ossler@gmail.com>
9293: [Backport 1.3] Trigger boundary events only if the flow scope is active r=saig0 a=saig0 ## Description Backport of #9281 Only one additional change compared to the origin PR for downgrading the test code to Java 11. ## Related issues relates to #9233 Co-authored-by: Philipp Ossler <philipp.ossler@gmail.com>
9293: [Backport 1.3] Trigger boundary events only if the flow scope is active r=saig0 a=saig0 ## Description Backport of #9281 Only one additional change compared to the origin PR for downgrading the test code to Java 11. ## Related issues relates to #9233 Co-authored-by: Philipp Ossler <philipp.ossler@gmail.com>
Describe the bug
When multiple interrupting boundary events are triggered simultaneously for a process instance, the process instance may not be able to finish terminating. Such an instance can no longer be canceled from outside either.
This was discovered in a scenario with a parent process that calls a child process that in turn calls another child process (see To-Reproduce section). Each call activity has an interrupting message boundary event that subscribes to the same message (i.e. the same message name and correlation key). When the message is published both call activities are simultaneously interrupted and terminated. However, this can lead to a deadlock in the termination logic:
The child cannot complete the message boundary event and take the sequence flow because its flow scope (the called instance) is set to terminating by the other boundary event. But the called instance cannot terminate because there is still an active flow.
Note that there may exist other ways to hit this bug using other events than messages (likely) and perhaps it also exists with nested embedded subprocesses (unlikely). I have not tested these cases.
To Reproduce
zbctl create instance Level_1
zbctl --insecure publish message msg --correlationKey='msg'
zdb log print -p=/tmp/data/raft-partition/partitions/1/ | jq '.records[].entries[]? | select(.recordType == "COMMAND_REJECTION") | select(.intent == "COMPLETE_ELEMENT")'
Expected behavior
The process instance should terminate.
Log/Stacktrace
Full Stacktrace
Environment:
The text was updated successfully, but these errors were encountered: