StartSoftlinksFromProcessVariablesHandler

Description

This handler starts softlinks and fills it with variables from the main process.

Thereby, the handler acts in accordance with the following schema:

  1. It searches for all variables containing the mainSuffix parameter.

  2. Afterward, it searches for all variables containing the softLinkSuffix parameter, whereupon it counts up from 0 to less than the softLinkCount parameter.

  3. After every increment, a softlink instance of the given definition is started. In the softlink instances, the softLinkSuffix parameter is removed in order to make the representation in the form easier.


Class

com.dooris.bpm.actionhandler.StartSoftlinksFromProcessVariablesHandler

Parameter

Parameter name

Default value

Description

Valid examples

Parameter name

Default value

Description

Valid examples

softLinkDefinition

 

Specifies from which process definition softlinks are to be started.

SGO Softlink

mainSuffix

 

Specifies which process variables of the main process are to be included in all softlinks.

Example: if the suffix is set to '_data', all process variables ending in '_data' will be taken (firstname_data, lastname_data, email_data,…)

Mandatory field. If not required, please enter an ending that is not in existence, i.e. _end

_mainData

softLinkCount

 

Specifies how many softlinks are to be started.

${softLinkCount}

softLinkSuffix

 

Specifies which variables are to be assigned to the individual softlinks.

This is where the parameter softLinkCount is used.

The handler counts to “i”, counting up from 0 to i < softLinkCount and thereby collects all variables that are built based on the following schema:

variablesname_softLinkSuffix[i]

After each run, it starts an instance of the softlink definition and passes all variables found by the mainSuffix and the softLinkSuffix to it.

In the newly started softlink instances, the softLinkSuffix is removed to ensure a uniform representation in the form.

At least one variable with the appropriate ending must be found, otherwise a sub-process will not be started.

_softLink

archiveWithMainInstance

true

Indicates whether the softlink instances should be archived when the main process instance is archived.

Possible values:

  • archiveWithMainInstance=true → The softlink instances are archived with the main process instance.

  • archiveWithMainInstance=false → The softlink instances are not archived with the main process instance.

false

useChildTransactionsForSoftlinks

false

To handle a big number of started softlink processes this parameter must be set to true. 

true

 

Example

  • Example 1

     

    Variable in the process: 
    user_email_sl[0]=john@doe.com 
    user_email_sl[1]=maria@doe.com 
    user_email_sl[2]=charles@doe.com 
    user_name_sl[0]=John
    user_name_sl[1]=Maria
    user_name_sl[2]=Charles
    user_lastname_sl[0]=Doe
    user_lastname_sl[1]=Doe
    user_lastname_sl[2]=Doe

    softLinkSuffix=_sl
    softLinkCount=3

    ⇒ 3 Sub-processes with variables:
    1.
    user_email=john@doe.com 
    user_name=John
    user_lastname=Doe
    2.
    user_email=Maria …

 

  • Example 2

    date_start_hp=01.01.2014 
    starter_hp=pm

    requesters_hp=user123 username=Doe
    useremail_sl[0]=john@doe.com
    userfirstname=John

    mainSuffix=_hp
    softLinkSuffix=_sl
    softLinkCount=1

    ⇒Sub-process with the following variables: 
    date_start=01.01.2014
    starter=pm
    requesters=user123