-
Notifications
You must be signed in to change notification settings - Fork 5k
[Feature][MasterServer] reduce db query operation when process instance running #6891
Copy link
Copy link
Closed
Labels
Milestone
Description
Search before asking
- I had searched in the issues and found no similar feature requirement.
Description
Now when Master run a workflow, it will do many db operation, which will make Master handle slowly.
Such as a easy dag, contains a shell task, run once and will occur more than 30 db operation: 1 delete, 2 insert, 5 update and 26 select.
I think if Master use memory cache of processInstance and taskInstance, instead of selecting from db every time, it will reduce the db stress and improve the Master handling workflow.
- when api update process instance or task instance, notify master to refresh and change state.
WorkflowExecuteThreadas the cache manager for each processInstance, which contains the taskInstances of this workflow.
BTW, I found that the old design TaskInstanceCacheManagerImpl, but it seems never used now.
Use case
No response
Related issues
No response
Are you willing to submit a PR?
- Yes I am willing to submit a PR!
Code of Conduct
- I agree to follow this project's Code of Conduct
Reactions are currently unavailable