Pickup service

Pickup service refers to the automatic services that feed the Activiti framework to execute a batch. The workflow follows this process:

  1. New documents are uploaded into the system and converted to batch instances.
  2. This activates an event-based trigger mechanism, which sends the event to the distribution pickup node.
  3. The pickup service runs and forwards the job to an available node using an intelligent distribution system.

Pickup settings

The pickup service is executed on a single server in a cluster with a fail-over functionality. This is an automatic service that assigns a random server in the cluster to execute the pickup service.

The server on which the pickup service is being executed is responsible for picking up all the batches for the cluster while keeping a check on the total execution capacity of the cluster. This is controlled through the following properties:

  • server.instance.max.process.capacity.mode

  • server.instance.max.process.capacity

  • server.instance.pick.capacity.mode

  • server.instance.pick.capacity

  • application.cluster.mode *

  • activity.job.interval.time *

  • activity.thread.wait.time *

Follow these steps to configure the pickup settings.

  1. Go to the dcma-workflows.properties file located at <Transact_Folder>\Application\WEB-INF\classes\META-INF\dcma-workflows.properties.
  2. Configure the following properties according to your workflow needs:

    Configurable property

    Options

    server.instance.max.process.capacity.mode
    • 0 : Maximum process capacity will be calculated automatically based on the number of cores in the system. See Execution capacity by cores.

    • 1: Maximum process capacity will be equal to the value specified for server.instance.max.process.capacity.

    server.instance.max.process.capacity

    If server.instance.max.process.capacity.mode is set to 1, set this property to the total maximum number of batches that each server in a cluster will execute.

    For example, if you have a 3-node cluster and each server should execute 5 batches, set this property to 5.

    server.instance.pick.capacity.mode
    • 0: Pickup capacity will be calculated automatically based on the number of cores in the system. See Execution capacity by cores.

    • 1: Pickup capacity will be equal to the value specified for server.instance.pick.capacity.

    Set this value to 1.

    If this value is set to zero (0), the capacity will be calculated automatically, and you will not be able to configure the next property.

    server.instance.pick.capacity

    Set this property to the total maximum number of batches that will be distributed in a cluster.

    For example, if you have a 3-node cluster and you want it to pick up 15 batches, set this property to 15.

    server.instance.batch.priority.range

    Specifies the batch instance priority range allowable for pickup.

    dcma.pickup.wait.ms

    This listening mechanism thread distributes jobs after receiving an event-based trigger or at the specified interval time in milliseconds.

    The default value is 6000.

    There should be no need to change this property.

    Configure all servers in the cluster using the same maximum process capacity and pick capacity values. This enables any server in the cluster to be assigned to run the pickup service in case of a failover.

  3. Restart the Transact server.

    If this is a clustered environment, start all servers one by one.

UI servers

UI nodes can be configured to not perform any workflow pickup execution, eliminating the associated inefficiencies. This is accomplished by disabling the new server.type.processing property.

UI servers should be set where:

server.instance.max.process.capacity.mode=1
server.instance.max.process.capacity=0
server.type.processing=false

The UI node can still be the pickup service distribution node if assigned the PICKUP_SERVICE from the service status table, and server.type.processing is set to false. All other nodes with server.instance.max.process.capacity greater than zero (0) should have server.type.processing set to true.

Execution capacity by cores

If either of the capacity.mode properties is set to zero (0), the execution capacity will be automatically calculated based on the total number of cores available for active processing servers. This is detailed in the following table.

Number of cores

Execution capacity (number of batches)

≤ 4

Equal to the number of server cores

5-8

Server cores - 1

9-15

8

16-32

10

≥ 33

15

Cron settings

The pickup service is controlled using cron job expressions. A cron is a string which schedules a task to run on your server automatically at a specified interval. A cron job is the scheduled task itself. For more information on creating cron jobs, see Cron expressions.

Cron settings for the pickup service determine the wait time to move a batch from the "New" to the "Running" state. This is controlled in the dcma-workflows.properties file, located at <Transact_Folder>\Application\WEB-INF\classes\META-INF\dcma-workflows.

Example of cron settings:

Server 1

Server 2

 dcma.pickUp.cronjob.expression=0/15 * * ? *
*
dcma.resume.cronjob.expression=0/15 * * ? * *
dcma.pickUp.cronjob.expression=0/30 * * ? *
*
dcma.resume.cronjob.expression=0/30 * * ? * *

All cron settings for the pickup service must be offset per server. We recommend that there is a minimum of 15 seconds difference per server.

Activiti

Activiti is a light-weight workflow and Business Process Management (BPM) Platform that uses the Business Process Model and Notation (BPMN) standard for defining workflows. It provides a fast and reliable workflow engine for Java. It is open-source and distributed under an Apache license. Each batch class, module, and plugin is defined as a BPMN.

Specifications:

  • License : Apache License 2.0

  • Version : 5.16.1

  • Process Definition Language : BPMN2.0