How can I limit maximum workflow execution simultaneously? I mean, I don’t want to let users overuse server, so is there any possibility to limit simultaneously workflow number for spesific workflow?
Scenario: I will give a limit (example: 10) to a workflow. When system has 10 workflow running at the same time, new workflow waits until finish old ones.
(Btw: Our commercial license is on its way)
At most one workflow will be running (using system resource) in a single process. All executions will run one by one in a queue (unless the sync ones). And this is by design.
So, you may not need to care about the quota of running resource for now.
1 Like
Doesn’t “On going” mean they running simultaneously?
I meant running only 1 of the same workflow, not different workflows.
@mytharcher
Hi, what does mean “At most one workflow” ?
The meaning of “Running” is the workflow execution is processing in program. The executions in your list shows “On going” status, this is not meaning they are processing in program. But just meaning they are paused (not completed) due to some breaking nodes (like manual node) in your workflow, and need to be resumed.
I deliberately added a Delay command to the Workflow and created 4 records to the collection to see what will happen.
My goal is to prevent Workflows for these 4 records from running at the same time. Did I explain my question I asked fully?
How did you organize your 4 create in your workflow? I am not sure did you create 4 workflows or 4 create record nodes in one workflow?
I designed a form and the user uploads a file. I enabled Workflow to be triggered when the Save button is pressed.
By pressing the add button, the user selects a file and clicks save buton. When the user do this 4 times, Workflow is triggered for 4 times at the same time.
So, you mean you have one workflow, but users could trigger it as many times as they click the button. And do you want to limit the times to trigger the workflow when they click the button? Something like rate-limit?
1 Like
Something like “Even if the user add 10 new records, the workflow should trigger a maximum of 5 and queue the others and wait for them to finish.”
Yes rate-limit or count-limit.
Workflow in NocoBase always queue all executions. So, this means “Even if the user add 10 new records”, the dispatcher of workflow will trigger them all, but execute only in one-by-one way. In other words, there will be only 1 of 10 workflow be running (consuming server resources).
For your purpose if I understand correctly, limit the resources of user triggering workflow, it is by default.
If you need to limit the button should not be clicked multiple times to avoid multiple times triggering, it will be another topic.