-
Feature Request
-
Resolution: Fixed
-
L3 - Default
-
None
-
None
User Story (Required on creation):
In some scenarios, users have different types of jobs that shall be not compete for execution resources. For example, a system may have "online" and "batch" jobs, where online jobs are short-running and should be handled as soon as possible as a human user is waiting for its completion whereas batch jobs are potentially a bit longer running but without time criticality. If both of these job types are handled by one job executor, they compete for execution resources (thread pool) and quality of service may deteriorate. In particular, execution resources may be blocked by batch jobs while online jobs are waiting for be picked up and executed. The purpose of this feature request is to allow users to set up dedicated job executors (and therefore thread pools) for different ranges of job priorities. This way, resources can be exclusively provisioned for online jobs (by assigning them a higher priority than batch jobs) and progress is ensured.
Functional Requirements (Required before implementation):
- The process engine can be configured to acquire and execute jobs for a priority range (similar to deployment-aware job execution)
- A range has an upper and a lower bound, both are optional
- To be decided: Ensure that non-BPMN jobs can receive priorities (e.g. batches, history cleanup)
Technical Requirements (Required before implementation):
- to be decided: In the case of exclusive follow-up jobs that would be executed directly by the same job executor, decide what should happen if the new job does not fall into the job executor's priority range (probably it should not execute the job in that case)
- to be decided: How does the job executor ensure exclusive job execution when there are multiple jobs for the same process instance, but some of them do not fall into the job executor's priority range
Limitations of Scope (Optional):
- The default database schema does not include indexes for the optimal acquisition query performance with priorities, assuming most users will not use them; instead, the documentation recommends useful indexes (https://docs.camunda.org/manual/7.15/user-guide/process-engine/the-job-executor/#the-job-order-of-job-acquisition)