Defining An On Event Message Flow
Use this feature only if you understand how outbound messaging works in the source Application.
In this example, we used a TIBCO Cloud™ Integration - Connect Message-Based flow to process outbound messages from Salesforce and integrate the records within the messages into a target datastore.
If your site has Salesforce Outbound Messaging set up for a specific object, a message may be created whenever a change is made to the records in that Salesforce object or entity.
As illustrated in this image, the outbound message pings the TIBCO Cloud™ Integration - Connect cloud endpoint, which uses a URL that is unique for each Message flow to relay the message to TIBCO Cloud™ Integration - Connect.
In TIBCO Cloud™ Integration - Connect, use the Flow designer to create visual flows by pulling the elements, or blocks, from the Connections panel to the workspace. For Message flows, each flow can process a single type of entity from a source.
Creating Flows
When you open a flow the Connections panel and workspace display. The Connections panel contains all of the blocks required to easily create flows used to integrate your source data into one or more target datastores. To build your flow, move the blocks into the workspace.
Each time you save your flow a separate revision of the flow is stored. Before saving, enter a comment in the Comment field at the bottom of the workspace to associate a comment with the new revision. You can go back to a prior revision from the Revisions dialog. See Flow Revisions for additional information.
Selecting Connections
Each Connection in a flow can be used for both Source and Target operations based on what the Connector and the associated datastore support. For example, if you have a Salesforce Connection and you use a Query block for that Connection in the flow, the Query is a Source operation, therefore, Salesforce is the Source for that block. If you use a Create block for the Salesforce Connection in the flow, Create is a Target operation, and Salesforce is the Target for that block.
Connections are sorted based on the order in which they were added to the flow. The color of the blocks associated with a Connection is determined by the order of the Connections. Control blocks are always light purple, the first Connection Blocks are always orange, and Blocks for the second Connection are yellow, and so on up to eleven Connections.
TIBCO Cloud™ Integration - Connect supports multiple target datastores in Integration flows. You can integrate data from one source into multiple targets. For example, while integrating your Microsoft Dynamics GP data into Salesforce, you can also send data from the same run to a CSV Text file for reporting purposes. Add Connections to a flow to connect to one or more target datastores.
The first step is to select or create up Connections in the Connections panel on the left side of the flow workspace. From the Connections panel, you can either:
- Select Add Connection and select an existing Connection from the Connection dialog.
- Select Add Connection and select Create a New Connection in the Connection dialog.
- After selecting a Connection, you can use the Gear menu to do the following:
- Edit — Make changes to the selected Connection. See Editing Connections.
- Reassign Connections — Change a Connection within a flow without reconfiguring each block that calls that Connection.
- Reset Metadata — Update the metadata for this Connection.
See Resetting Metadata. Note: Metadata for Text Connections cannot be reset here. See Resetting Metadata for Text Connections.
- Metadata Status — View a list of the most recent set of metadata requests and the request status for this Connection. See Metadata Status.
- Remove — Delete the Connection. Connections can only be removed if they are not used in the flow.
As soon as a valid Connection is selected, all of the blocks supported by the Connection display in the Connection panel.
Starting A Flow
After you select your Connections, you can begin to create a flow. A flow is a visual representation of the instructions needed to integrate your data. For Message flows, the flow must start with a Wait For Message Block.
Add Wait For Message Block
- From the Connections panel, select the Wait For Message Block associated with the Connection you want to use as a data source and drag it to the workspace.
Note: As you drag and drop blocks, the top border always changes color. If the color of the block is transparent, you have not attached it correctly to the previous block and the flow does not run.
When you first drag blocks over, they often display an error in the corner. This is expected because the block is missing important configuration information, such as the entity you want to use.
- Select the Wait For Message Block.
- Select the General link in the Properties panel to open the Wait For Message Block Properties.
- Select your source entity. At this point, you can continue to build your flow, or you can close the Properties dialog and save the flow.
- Select the next block for your flow. Unlike a regular flow, the For Each Result block is not required or available.
As you build your flow, keep in mind that you only define the processing for one record at a time. If a message contains multiple records, your flow runs once for each record.
- When you are done, select OK to save and close your flow. Then, configure the Outbound Message in the source Application.Note: After saving the flow the first time, TIBCO Cloud™ Integration - Connect generates a unique Endpoint URL which displays on the Wait For Message Block Properties — General tab. This may take a few minutes.
You must copy and paste the URL into the source Application. See the Administrator for the Application or the associated Help.
Set Security Rules
From the Security dialog under Environment & Tools > Security Settings, specify the security rules for the On event apps in this Organization.
- 54.204.16.213
- 54.83.47.195
- 23.23.251.57
Example: Creating The Outbound Message In Salesforce
To use a Message flow, you need to create a Workflow and an Outbound Message in Salesforce. The message you configure uses the Endpoint URL displayed in the Wait for Message Block.
- Create a new Workflow Rule.
- Add a new Outbound Message as a Workflow Action.
- For the new Outbound Message, copy the Endpoint URL from the Wait for Message Block for this entity.
Note: Every Message flow has a unique URL. Make sure that you configure your messages for the correct flows.
- When you are done, be sure to activate the Workflow Rule.
For detailed information about configuring and monitoring Workflows and Outbound Messages, see the Salesforce Help.