Managing Process Chains

Intershop Commerce Management implements a mechanism for creating and executing process chains. Process chains help to automate the sequential execution of interdependent scheduled jobs or pipelines.

Defining a process chain involves, basically, the following tasks:

  • Specifying the chain elements, i.e., the jobs or pipelines to be processed

  • Creating a scheduled job that triggers the execution

Executing Process Chains

For process chains to be executed, administrators must create and configure a scheduled job that triggers the pipeline ExecuteProcessChain included with the Intershop Commerce Management core cartridge.

To execute a process chain:
  1. Create a new scheduled job.
    For details about scheduled job creation, refer to Creating New Scheduled Jobs. Make sure to specify the pipeline ExecuteProcessChain and the start node Start.
  2. Add the XmlFileName attribute to the new job.
    The pipeline ExecuteProcessChain requires the path to the process chain configuration XML file as the input parameter XmlFileName.
    Therefore you have to add an attribute XmlFileName to the job. Its value must be of the data type String and must specify the complete path and file name of the configuration file relative to <IS.INSTANCE.SHARE>, e.g., system/config/cluster/processchain.xml.
  3. Configure the process chain execution.
    Define the recurring interval, specific login and password etc. as necessary. For details, see Creating New Scheduled Jobs.
The process chain will be executed according to your settings.

Specifying Process Chain Elements

Administrators can define process chains via XML files.

Define process chains by using the XML files to be located in <IS.INSTANCE.SHARE>/system/config/cluster.
Note: The default installation includes an example file, processchain.xml.example.
The main configurable elements include:
  • <chain>

    The root element of the process chain XML file. Important attributes include name (used in the Intershop System Management, module Monitoring | Locking | Processes) and keepAliveTime, which defines the time that threads exceeding the core pool size may remain idle before being terminated.

  • <concurrent>

    Child element of <chain> or <sequence>. Includes jobs or pipelines to be executed in parallel. The attribute name is used in the Intershop System Management module Monitoring | Locking | Processes.

  • <sequence>

    Child element of <chain> or <concurrent>. Includes jobs or pipelines to be executed sequentially in the given order. The attribute name is used in the Intershop System Management module Monitoring | Locking | Processes.

  • <job>

    Child element of <sequence> or <concurrent>. Specifies a job to be executed within the chain. The next table lists the attributes for <job>.
    Table 1. Attributes of the process chain element <job>
    Attribute Description
    job Specifies the name of the job as defined in the Intershop System Management Schedules module (mandatory).
    name Specifies a display name for the job to be used in the Monitoring | Locking | Processes module.
    domain Can define a specific domain for the job execution (optional). By default, the chain element job is executed in the domain of the process chain.
    allsites Can specify whether the job executes in all domains (true | false). By default, it is set to false.
    concurrent With allsites=true, can specify whether the job executes in parallel in all domains (true | false). By default, it is set to false.
  • <pipeline>

    Child element of <sequence> or <concurrent>. Specifies a pipeline to be executed within the chain. The next table lists the attributes for <pipeline>.

    Table 2. Attributes of the process chain element <pipeline>
    Attribute Description
    pipeline Specifies the name of the pipeline to be executed.
    name Specifies a display name for the pipeline to be used in the Monitoring | Locking | Processes module.
    domain Can define a specific domain for the pipeline execution (optional). By default, the chain element pipeline is executed in the domain of the process chain.
    startnode Can define a specific pipeline start node (optional). By default, it is set to Start.
    login Can define the login name that the pipeline to be executed may require.
    password Can define the password if the pipeline to be executed requires a specific login.
  • <error>

    Optional child element of <sequence>. Specifies a dedicated <job> or <pipeline> that is to be executed in case the preceding jobs or pipelines within the <sequence> have failed.

    Note: Make sure that <error> is the last element within the corresponding <sequence>.
  • <parameter>

    Optional child element of <pipeline>. Can specify the parameter that the pipeline to be executed may require.

  • <description>

    Optional child element of <sequence>, <concurrent>, <job> or <pipeline>. Specifies a description to be displayed in the Intershop System Management module Monitoring | Locking | Processes.

  • <ignore>

    Optional child element of <sequence>, <concurrent>, <job> or <pipeline>. Can specify status codes (SUCCESS|WARNING|FAILURE|ERROR|NOTFOUND|INTERRUPTED) returned from the corresponding chain element upon execution that should be ignored for the remaining process chain execution. This way, the process chain execution can continue in case of errors in one of its sub tasks.