LoopBackRequest node
Use the LoopBackRequest node to issue synchronous requests through a LoopBack® connector, to create, retrieve, update, and delete data in a backend data source.
The LoopBackRequest node is available on Windows, AIX®, and Linux® on x86-64 systems.
You can download your chosen LoopBack connectors, and then install them by using the npm tool that is provided with IBM® App Connect Enterprise, as described in Installing the LoopBack connector. You can then access the connectors from your message flow. For more information, see Working with LoopBack connectors.
This topic contains the following sections:
Purpose
You can use the LoopBackRequest node in a message flow to create, retrieve, update, and delete data through a LoopBack connector such as MongoDB, Cloudant, or PostgreSQL.
Before you can use the connectors, you must install them into IBM App Connect Enterprise by using the npm tool that is provided with IBM App Connect Enterprise. You can then configure a LoopBackRequest node in a message flow to use a specific data source stanza from the LoopBack datasources.json file for your connector, and invoke create, retrieve, update, or delete operations on a model instance for that data source. The datasources.json file is located in the MQSI_WORKPATH/connectors/loopback directory. Optionally, you can provide a LoopBack JSON model definition in a file located in MQSI_WORKPATH/connectors/loopback/data-source/model.json. For more information, see Working with LoopBack connectors.
The LoopBackRequest node operations are synchronous and non-transactional, which means that, if a message flow fails and rolls back after the LoopBackRequest node, the operation on the data source will still complete.
Using the LoopBackRequest node in a message flow
For more information about LoopBack connectors, see Working with LoopBack connectors.
Terminals and properties
When you have put an instance of the LoopBackRequest node into a message flow, you can configure it; see Configuring a message flow node. The properties of the node are displayed in the Properties view. All mandatory properties for which you must enter a value (those without a default value) are marked with an asterisk.
The LoopBackRequest node terminals are described in the following table.
Terminal | Description |
---|---|
In | The input terminal that accepts a message for processing by the node. The LoopBackRequest node is driven by a message arriving on the In terminal. The message must be in the JSON domain. |
Out | The output terminal from which the message tree is propagated. The output message tree contains the JSON object that is returned from the LoopBack connector, and it is in the JSON domain. |
Failure | If an error occurs in the LoopBackRequest node, the message is sent to the Failure terminal. |
The following tables describe the node properties. The columns headed M indicate whether the property is mandatory (marked with an asterisk on the panel if you must enter a value when no default is defined); the columns headed C indicate whether the property is configurable (you can change the value when you add the message flow to the BAR file to deploy it).
Property | M | C | Default | Description |
---|---|---|---|---|
Node name | No | No | The node type, LoopBackRequest | The name of the node. |
Short description | No | No | A brief description of the node. | |
Long description | No | No | Text that describes the purpose of the node in the message flow. |
Property | M | C | Default | Description | mqsiapplybaroverride command property |
---|---|---|---|---|---|
Data source name | Yes | No | The name of the data-source stanza in the datasources.json file. Use this property to specify the name of the data source stanza for your chosen connector in the LoopBack datasources.json file, which is located in the connectors/loopback subdirectory of the integration node's workpath. | dataSource | |
Object | Yes | Yes | The type of object that you want to access. | object | |
Operation | Yes | No | The operation to be used. This property lists
the operations that are available. You can override this property
by setting the operation name in the LocalEnvironment.Destination.Loopback.Request
subtree. The available operations are:
|
||
Security identity | No | Yes | The security identity to look up in the integration server to get the authentication properties to be used. Use the mqsisetdbparms command to set the security identity on the integration server . Note: Note: This property overrides any equivalent security properties provided in the data sources file.
|
securityIdentity | |
Timeout (milliseconds) | No | Yes | 120000 | The time (in milliseconds) that the node waits for the LoopBack connector to process the operation. You can override this property by setting the object name in the LocalEnvironment.Destination.Loopback.Request subtree. | timeoutMilliseconds |
Property | M | C | Default | Description |
---|---|---|---|---|
Message domain | Yes | No | JSON | The domain that is used to parse the response message. By default, the message that is propagated is in the JSON domain. You cannot specify a different domain. |
Message model | No | No | The name or location of the message model schema file in which the incoming message is defined. You cannot set this property. | |
Message | No | No | The name of the response message. The node detects the message type automatically; you cannot set this property. | |
Physical format | No | No | The name of the physical format of the response message. You cannot set this property. |
Property | M | C | Default | Description |
---|---|---|---|---|
Data Location | Yes | No | $Body | The location in the incoming message tree from which data is retrieved to form the request that is sent from the LoopBackRequest node. The default value, $Body, represents the incoming message body. You can enter any XPath or ESQL expression that defines the location of the message tree to serialize and send. |
Property | M | C | Default | Description |
---|---|---|---|---|
Output data location | Yes | No | $OutputRoot | The message tree location to which the LoopBackRequest node sends output. |
Copy local environment | No | No | Selected | This property controls whether to copy the incoming local environment or propagate the incoming local environment. By default, this check box is selected, which specifies that the local environment is copied so that the incoming local environment is preserved. The additions to the local environment are visible only to nodes downstream of this node. If this check box is cleared, the incoming local environment is used for the outgoing message. Any modifications that are made to the local environment by this node are visible to both downstream and upstream nodes after this node has completed. |
Property | M | C | Default | Description |
---|---|---|---|---|
Events | No | No | None | Events that you have defined for the node are displayed on this tab. By
default, no monitoring events are defined on any node in a message flow. Use
Add, Edit, and Delete to
create, change or delete monitoring events for the node. You can enable and disable events that are shown here by selecting or clearing the Enabled check box. |