-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
Camunda 7 scripting - race conditions across process-instances while setting a variable #4449
Comments
Hi @DumboJetEngine, Thank you for your interest in our product.
In case you need to upload more data relevant to the investigation of the issue, please create a simple repository or upload files as gist in GitHub. Thank you in advance for that. Best, |
Hello.
I might try to hit your API without this client, to see if that changes anything, but I honestly don't think it will. |
That might be the case, I just wanted to lay out all of the options. |
Hello again. Here is the bpmn file I've used: I don't see asynchronous continuations affecting anything (when it comes to errors at least). |
Hi @DumboJetEngine, Unfortunately, I am still not able to reproduce the issue. I see some flows have missing conditions in the latest bpmn process. Could you please simplify the example further?
Yes, h2 database should not be used in production. You can pick some of the other supported environments: https://docs.camunda.org/manual/7.21/introduction/supported-environments/#databases |
@yanavasileva |
I am not sure, probably not. In case you want to use h2 in production or test pre-production environment, please switch to another database. |
Environment (Required on creation)
( I have customized pretty much nothing on Camunda. It uses the default H2 database, as far as I understand. Isn't that database a valid production candidate? )
Description (Required on creation; please attach any relevant screenshots, stacktraces, log files, etc. to the ticket)
I have a Camunda 7 workflow with a sub-process that accesses parent variables.
Specifically, the parent does this in a script task (groovy code):
And the sub-process calls the setSuccess() and setError("sth") functions.
The workflow does not contain any user tasks, so once I start a process instance, it executes and it gets done/destroyed, after I get the result variables back.
All is working fine when I call the workflow once at a time. But when I bombard it with parallel calls (each time creating a new process instance), then I get weird errors revolving around variables.
This is the C# code that calls the workflow in parallel (using the latest
Camunda.Api.Client
nuget package):When MaxDegreeOfParallelism is bigger than 1, I get all kinds of unexpected errors, like:
Here are some stack traces (they were too long to post here): https://mega.nz/file/cR0VSLDA#W1f_a4Xxs6OI0hREfAc1SBwx0nzvDrQb3Jn1qPDoGpE
And here is the workflow file: https://mega.nz/file/NM1kDDxK#zsiqoi-7meHYLV4cYl7Qa9CAmQdtyFAW3aMf4cNAKA0
Steps to reproduce (Required on creation)
Camunda.Api.Client
nuget package to the project.actionNames
, make sure there are many (> 100) strings.MaxDegreeOfParallelism = 1
and then withMaxDegreeOfParallelism = 10
, to see the difference.Observed Behavior (Required on creation)
When using
MaxDegreeOfParallelism = 10
various errors related to setting or getting the variables appear, coming from the execution engine.Expected behavior (Required on creation)
Not getting any error, no matter what degree of parallelism you use, since a process instance is supposed to be isolated from other process instance.
Root Cause (Required on prioritization)
Solution Ideas
Hints
Links
Breakdown
Pull Requests
Dev2QA handover
The text was updated successfully, but these errors were encountered: