Configuring the user-defined node properties and terminals for your connector

Configure the properties for your user-defined node and add input or output terminals so that you can connect it to other nodes in a message flow.

Before you begin

Create the plug-in files for your user-defined node by following the instructions in Creating a user-defined node for a connector.

About this task

When you create the plug-in files for your user-defined node, a .msgnode file is opened in the Message Node editor of the Integration Development perspective. You can now add terminals and properties to the node:

Adding terminals to the node

About this task

When you are creating user-defined nodes for connectors, you can add specific types of terminal according to the interaction type. User-defined nodes for connectors cannot have dynamic terminals. For detailed information about how terminals work for different interaction types, see User-defined node terminals for connectors.

Procedure

  1. Open the .msgnode file for your user-defined node.
  2. If the Terminals page is not already displayed, click the Terminals tab at the bottom of the Message Node editor.
  3. Add an output terminal and name it "failure". The name is case-sensitive and must use lowercase characters.
    This terminal is used if the connector issues an exception at run time.
  4. If you are creating an input node, delete the input terminal by selecting it, then clicking Delete.
    Similarly, if you are creating an output node, delete the output terminal.
  5. Ensure that Support dynamic In terminals and Support dynamic Out terminals are cleared.
  6. Save the file.

Defining properties for the node

About this task

A message flow developer can add a message flow node to a message flow, then customize that node by setting the available properties. You can define those properties for your user-defined node on the Properties tab of the Message Node editor.

For a connector, you must define a hidden property that specifies the connector provider name. You can then add any other relevant properties, such as a database name, host server name, or password. The properties that you set here must match the properties that are used by the connector at run time.

For a connector, table properties are not supported, and you cannot use a custom compiler class or a custom editor class.

Procedure

  1. Open the .msgnode file for your user-defined node.
  2. On the Properties tab, click the node name in the property hierarchy to view the properties that are associated with it.
  3. Clear Use integration node default values.
  4. If the node is an input node, select Input node.
  5. By default, all properties are grouped under the Basic group. You can add new groups in which to place properties. When a flow developer selects your user-defined node in the IBM® Integration Toolkit, each group of properties is shown on a separate tab in the Properties view. To create more groups of properties, click Add Property Group The image shows the Add Property Group icon and enter a suitable name for the group.
  6. Add a hidden property to specify the provider name for the connector.
    1. Select the name of a property group, click Add Simple PropertyThe image shows the Add Simple Property icon., then set the name to connectorName.
    2. Select Built-in and set it to String.
    3. Set the default value to the name of the provider, which must match the connectorProvider name in the descriptor file of your compiled connector JAR file. This name is used for all interaction types of this particular connector (input, output, or request).
    4. Select Hidden.
      This option ensures that this property is associated with the connector, but the message flow developer cannot see or change the value.
    5. Because these properties are hidden, do not select Read Only, Mandatory, or Configurable, and do not specify field-level help.
    6. Do not set Custom Compiler Class or Custom Editor Class.
  7. Add properties to be set by a message flow developer in a similar way.
    Ensure that Hidden is cleared for these properties so that the message flow developer can customize them.
  8. Optional: Drag the properties in the properties hierarchy to change the order in which they are listed on the properties page.
  9. Save and close the .msgnode file.
  10. Optional: You can customize the text that is displayed in the node properties view for each property. When you define the property in the .msgnode file, the name cannot contain spaces. Therefore, you might want to edit the property name so that the name in the Properties view contains spaces.
    To set the text, open the .properties file for your user-defined node and edit the following line:
    Property.propertyName=Property name
  11. Save and close the .properties file.

What to do next

Package your user-defined node by following the instructions in Packaging the user-defined node project for a connector.