Zum Hauptinhalt springen

Performance improvements

The following performance improvements have been made.

Task execution performance improved (#662964)

The performance of task execution has been improved to reduce the interval between task executions based on the number of tasks waiting for execution. This optimizes the processing of a large number of small tasks.

Previously, tasks were executed with a fixed interval between attempts to acquire a task, which lead to idle times of the execution threads. Now, the threads will acquire a new task immediately after finishing the execution of the previous one, without considering the waiting period defined in the system property task.execution.interval.seconds. When no more tasks are waiting for execution, the strategy is switched back to the regular interval automatically, minimizing database load.

The system property task.execution.smart.intervals has been added to the module cmas-core-server to configure the behaviour. By default, it is set to true, which enables accelerated task execution. You can set it to false to restore the waiting intervall before the thread tries to lock a new task.

Best practice

For most efficient processing of a large number of small tasks, it is recommended to set the system property number.of.tasks of the module cmas-core-server to 1, unless you experience a slow performance.