Workflow task settings

In the Workflow Builder, create a workflow in the triDataConnectJob module. The sample workflow deals with several key workflow tasks and task settings.

Start task

The Object Type that is related to triDataConnectJob, and the Event of SYSTEM DC PROCESS JOB identify the correct workflow for the DataConnect Agent. The DataConnect Agent pulls the BO_NAME field, which must be the name of the Object Type from the DC_JOB entry for the job.

Table 1. Start task settings
Field Description
Name In the workflow Start task, Name the workflow by applying the IBM® TRIRIGA® naming standards.
Concurrence, Integration Set Concurrence to Asynchronous. Select the Integration flag, which allows DataConnect tasks to be a part of the workflow.
Module Set Module to triDataConnectJob.
Object Type Set Object Type to the business object you created in the triDataConnectJob module.
Event Set Event to SYSTEM DC PROCESS JOB. This event is the DataConnect event.
Propagate Integration Status, Integration Select the Propagate Integration Status flag, which specifies to propagate the Integration flag when this workflow calls another workflow.

DataConnect task

The DataConnect task retrieves records from the staging table and iterates through the staged entries, creating or updating a smart record for each one.

Table 2. DataConnect task settings
Field Description
Label, Description Create the workflow body with the DataConnect task where appropriate. Enter a Label and Description.
Module, Business Object Specify the Module and Business Object on which the DataConnect task operates.
Initial State Make Initial State the state in which a new record must be created. The DataConnect task ignores the value of Initial State if the record is being updated. The choices in the list box are the states that are defined for the business object. The record is created in that state; it is not transitioned to that state. If you want the record to be transitioned, have the DataConnect task create the object in the null state. Then, use a Trigger Action task within the DataConnect task body to transition the record to the intended state.
Use Temporary Data Select Use Temporary Data when the DataConnect task is to use temporary data. When a DataConnect task with Use Temporary Data checked applies incoming data, the platform inserts or applies updates to temporary data instead of to the permanent data. See Use Temporary Data for examples and more details.
In-Sequence, Task Step In the Correlation section:
  • In-Sequence indicates that the correlation on the staging entry and the sequence number are used to determine the order by which the records are processed. This scenario is the default and the most common scenario unless you have DataConnect tasks one within another.
  • Task Step indicates that the correlation must come from an enclosing DataConnect task and must be used in the Where clause to determine what entries to process. For example, Job Number + Correlation Number, ordered by Sequence Number. Using Task Step allows the DataConnect task to get the correlation number from one of the enclosing DataConnect tasks.
None, Per X Iterations, All Iterations Select the scope in the Transaction section.
  • None: The record is committed right after it is created or updated.
  • Per X Iterations: A new context is created for every X iterations and committed when that number of iterations is complete.
  • All Iterations: A new context is created before the task starts any processing and is committed when all iterations are complete.

Trigger action task

The last step in the workflow must be a Trigger Action task to mark the job Completed or Failed.

Table 3. Trigger Action task settings
Field Description
Label, Action In Trigger Action Task Properties, enter Mark Job Completed in the Label field, and select triDCCompleted for the Action field.
Take the, of Task, Use it, Object Type In the Records section, select Business Object for the Take the field and Start (loDCPurchaseOrder) for the of Task field. Mark the Use it option and select loDCPurchaseOrder for the Object Type field.

Break task

For transactions to roll back or commit, put a Break (or Continue) in the DataConnect body. With the Break (or Continue) task, you can check the DataConnect task status, and determine what block to go to. You can also decide whether to keep iterating or not (Continue versus Break) and whether to commit or roll back (Success or Failure). The transaction setting on the DataConnect task works with the Break (or Continue) task settings.

The Break also has settings to control temporary data. Find more details and examples in Use Temporary Data.

If the DataConnect task is not using transactions, rows are committed with each task step. If you do not reach a Break (or Continue) that changes the processing flow and are using transactions, a commit takes place that is based on the DataConnect task settings.

If the DataConnect task is using transactions and the workflow Breaks (or Continues), the transactions roll back or commit based on the Success or Failure setting on the Break. Processing continues at the scope indicated in the Break (or Continue). Current Scope means the DataConnect task that you are in. Break Flow Type means continue processing at the task after the DataConnect task. Continue Flow Type means continue onto the next row in the staging table batch for this job. Selected Block means Break (or Continue) at that DataConnect task.