Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

  • Pre-loading
    • Tasks can be pre-loaded by use of the <job min_tasks="number"/> attribute where number specifies the number of tasks that are pre-loaded.
    • Such tasks will be loaded and keep running during the lifetime of JobScheduler. Such tasks will not consume CPU resources when being idle. The tasks will be re-used immediately for an incoming order and will execute the spooler_process() method of the job implementation.
    • Tasks that are pre-loaded can be configured to restart after expiration of the idle timeout setting, see below. This is effected by use of the  <job force_idle_timeout="yes/no"/> attribute that forces a restart after the timeout set by the <job idle_timeout="duration"/> attribute.
    • Pre-loading comes at the disadvantage that the task log contains the log information of all orders that have been processed during the tasks' lifetime. Such logs might grow to a considerable size and will be written to the database only when the task is terminated which might slow down this operation.
  • Re-use
    • Tasks can be configured for re-use by the <job idle_timeout="duration"/> attribute where duration can be specified in seconds or in the HH:MM or HH:MM:SS formats. The default value for the idle_timeout attribute is 5s.
    • The idle timeout lets a task continue after the processing of an order for the specified duration. Should the next order enter the job node within the duration of the idle timeout then the task will be re-used, otherwise the task is terminated.
    • This setting is frequently used if pre-loading of a high number of tasks would consume too many system resources (memory) and the expected scenario is that multiple orders will arrive in parallel for the job node.
    • It is not recommended to suppress the idle timeout by use of <job idle_timeout="0"/> as this would result in immediate termination of the task after processing of the current order should no additional orders be waiting for this job node. An order will immediately proceed to the next job node in a job chain without consideration of the task being continued, therefore this setting does not affect the time consumption of an order that leaves the job node but improves the performance for the next orders that enter the job node.
  • Resource Consumption
    • Pre-loading and re-use of tasks saves the effort of loading the JVM which can include 1s and more depending on the system performance.
    • The memory allocated to the JVM will be retained during the lifetime of the task.

...