IBM MQ Connector > Mappings and mapping tasks with IBM MQ Connector > IBM MQ targets in mappings
  

IBM MQ targets in mappings

To write data to an IBM MQ database, configure an IBM MQ object as the target in a mapping.
Specify the name and description of the IBM MQ target. Configure the target and advanced properties for the target object.
The following table describes the target properties that you can configure for an IBM MQ target:
Property
Description
Connection
Name of the target connection.
You can select an existing connection, create a new connection, or define parameter values for the target connection property.
To overwrite the target connection properties at runtime, select the Allow parameter to be overridden at run time option.
Target Type
Type of the IBM MQ target object.
Select one the following target types:
  • - Single Object
  • - Parameter
Default is Single Object.
Object
Name of the IBM MQ target object.
Specify the target object that you want to create. You can also select an existing object from the list.
If you enable the Skip Metadata Fetch property in the IBM MQ connection, only a placeholder object appears as an IBM MQ target object in the list, and you need to enter the queue name in the advanced target properties.
Parameter
A placeholder to dynamically assign values at run time for the target object without the requirement to edit the task.
Select an existing parameter for the target object or click New Parameter to define a new parameter for the target object.
The Parameter property appears only if you select parameter as the target type.
If you want to overwrite the target object at runtime, select the Allow parameter to be overridden at run time option. When the task runs, the agent uses the parameters from the file that you specify in the advanced session properties.
Operation
Type of the target operation.
You can perform only the insert operation on an IBM MQ target.
The following table describes the advanced target properties that you can configure for an IBM MQ target:
Property
Description
Queue Name
The queue name in the Queue Manager in IBM MQ where you want to write messages.
If you enable the Skip Metadata Fetch property in the IBM MQ connection, you need to enter the queue name.
Note: When you specify a queue name in both the Object and Queue Name fields, the queue name specified in the Queue Name field takes precedence.
Recovery Queue Name
The queue name in the Queue Manager in IBM MQ where you want to store the recovery state.
If you want to enable recovery strategy for the mapping task, enter the recovery queue name.
For example, QUEUE.RECOVERY.
To honor the recovery queue name entered in this property, set the MQTargetIsTransactional custom property value to true in the Secure Agent properties.
For more information about how to enable recovery strategy for the mapping task by configuring the Secure Agent properties, see Enabling the message recovery mechanism for targets.
Forward Rejected Rows
Determines whether the transformation passes rejected rows to the next transformation or drops rejected rows. By default, the mapping task forwards rejected rows to the next transformation.
If you enable the option, the Secure Agent flags the rows for reject and writes them to the reject file.
If you don’t enable the option, the Secure Agent drops the rejected rows and writes them to the session log file. The Secure Agent does not write the rejected rows to the reject file.

Message recovery strategy

You can configure message recovery for a mapping task that writes to an IBM MQ target. If the task crashes or if it terminates unexpectedly, you can rerun the task to recover the task from the last check point.
When you configure the recovery strategy for a mapping task, the Secure Agent recovers the state of a target message from the failed mapping and stores it in a queue in the Queue Manager in IBM MQ. If the task fails, run the mapping task in recovery mode to recover the state of a target message that the Secure Agent did not process.
To configure message recovery for a mapping task that writes to IBM MQ, set the MQTargetIsTransactional custom property in the Secure Agent properties, and specify the recovery queue name in the Target transformation.
When you run a mapping task enabled with recovery strategy and it fails, the Secure Agent generates the recovery state of the target message in the queue that you specified in the Recovery Queue Name property in the Target transformation.

Enabling the message recovery mechanism for targets

To enable message recovery for a mapping task that writes to an IBM MQ target, configure the MQTargetIsTransactional custom property in the Secure Agent properties and create a mapping, add the mapping to a mapping task, and then configure the advanced properties.
    1To configure the MQTargetIsTransactional custom property in the Secure Agent properties, perform the following steps:
    1. aLog in to Informatica Intelligent Cloud Services.
    2. bSelect Administrator > Runtime Environments.
    3. cOn the Runtime Environments page, select the Secure Agent.
    4. dClick Edit.
    5. eIn the Custom Configuration Details section, select Data Integration Server as the service and DTM as the type.
    6. fEnter MQTargetIsTransactional in the Name field and set the value to true.
    7. The configured MQTargetIsTransactional custom property in the Secure Agent properties.
    8. gClick Save.
    2Create an IBM MQ mapping configured with the recovery queue name in the Target transformation.
    3Create a mapping task that uses the configured IBM MQ mapping.
    4In the Runtime Options tab, add the following properties in the Advanced Session Properties section:
    1. aIn the Commit on End of File field, select the value of the property as No.
    2. bIn the Commit Type field, select the value of the property as Target.
    3. cIn the Recovery Strategy field, select the value of the property as Resume from last checkpoint.
    5Click Save > Run the mapping task.