Mapping input and output data for an activity or step

In Process Designer, to pass variables to an activity or step you have to set the input and output data mapping.

Before you begin

You must have a process that contains a set of declared variables and an activity, or a service that contains a set of declared variables and a step. The activity or step must implement a service or linked process which also contains a set of declared variables that match the ones in the main process for an activity, or the service for a step.
Restriction: For client-side human services, mapping input and output data is applicable only if the client-side human service is used within a process. Data mapping is not applicable if the client-side human service was created with a Launch or Details UI view in the process editor, or is used for a dashboard.

About this task

When developing processes in Process Designer, you must set the input and output mapping for each activity included in a process so that the variable values received and generated by the subprocesses and services that implement the activities map to the variables from the main process. Similarly, if you have a service, you must set the input and output mapping for each step included in the service.

Note: This task is not relevant if you use the Activity Wizard to create a service to implement an activity.

The following procedure describes how to map both input and output data for an activity or a step. Depending on the logic of your process or service, an activity or step may only require input or output data and not both.

Procedure

  1. Open the process or service diagram.
  2. Click the activity in the diagram or the step in the service diagram, and then click the Data Mapping tab in the properties. The Data Mapping tab displays the variables that are available from the service implemented in the activity or step.
    • For receive events that are triggered using an undercover agent (UCA), both identifier and non-identifier variables can be used for correlation.
    • This topic applies only to the IBM Business Process Manager Advanced configuration.For receive events that are triggered using a Service Component Architecture (SCA) service call, only variables that are marked as process instance identifiers can be used for correlation.
      Tip: If a selected variable is subsequently changed to not be a process instance identifier, an error icon is displayed by the variable on this tab.
    IBM BPM version 8.6.0 cumulative fix 2017.12Note: If your activity is an inline user task, no variables are displayed that are available from a service, but you can add variables that you want to pass to a service.
  3. To complete the data mapping, click the Auto-map input properties with variables from service icon (Two arrows facing opposite directions) in both the Input Mapping and Output Mapping sections.
    IBM BPM version 8.6.0 cumulative fix 2017.12Note: For inline user tasks, the Data Mapping tab does not contain any auto-mapping capability. The interface of user inline tasks is defined entirely by what you choose to map. Additional information about inline user tasks is found in the topic Working with inline user tasks.

    In the desktop Process Designer, auto-mapping works only when variable names and types match exactly. You should always use an identical name and data type for a set of input and output variables that are passed in, processed, and then passed back. If no matching output parameters are found, you can choose to generate them. Existing mappings are over-written by the newly generated ones. Auto-mapping does not take into account existing variables with the same names and different types, and creates duplicate variables which result in validation errors. The output variables generated are always private variables.

    Auto-mapping works slightly differently in the web Process Designer. Existing mappings are not overwritten. No variables are generated for existing variables with the same name but different types. By default, the variables are created as private variables. You can choose to make them input, output, or input and output variables.

    If your variable is a shared business object then the output mapping from the activity or step is not required.

  4. Click Save or Finish Editing.

What to do next

The data mapping is complete, and you can test it.