IBM Integration Bus, Version 9.0.0.8 Operating Systems: AIX, HP-Itanium, Linux, Solaris, Windows, z/OS

See information about the latest product version

JMSInput node

Use the JMSInput node to receive messages from JMS destinations. JMS destinations are accessed through a connection to a JMS provider.

This topic contains the following sections:

Purpose

The JMSInput node acts as a JMS message consumer and can receive all six message types that are defined in the Java™ Message Service Specification, version 1.1. Messages are received by using method calls, which are described in the JMS specification.

The JMSInput node is contained in the JMS drawer of the palette, and is represented in the IBM® Integration Toolkit by the following icon:

JMSInput node icon

Using the JMSInput node in a message flow

The following sample contains a message flow in which the JMSInput node is used. This sample is an example of how to use the JMSInput node.

You can view information about samples only when you use the product documentation that is integrated with the IBM Integration Toolkit or the online product documentation. You can run samples only when you use the product documentation that is integrated with the IBM Integration Toolkit.

The JMSInput node receives and propagates messages with a JMS message tree. You can set the properties of the JMSInput node to control the way in which the JMS messages are received.

The JMSInput node handles messages in the following message domains:
  • DFDL
  • XMLNSC
  • DataObject
  • JSON
  • BLOB
  • MIME
  • MRM
  • JMSMap
  • JMSStream
  • XMLNS

Message flows that handle messages that are received from connections to JMS providers must always start with a JMSInput node. If you include an output node in a message flow that starts with a JMSInput node, it can be any of the supported output nodes (including user-defined output nodes); you do not have to include a JMSOutput node. However, if you do not include a JMSOutput node, you must include the JMSMQTransform node to transform the message to the format that is expected by the output node.

If you are propagating JMS messages and creating a message flow to use as a subflow, you cannot use a standard input node; you must use an instance of the JMSInput node as the first node in order to create an In terminal for the subflow.

Restriction: When the JMSInput node receives publication topics, it internally restricts the message flow property Additional Instances to zero to prevent the receipt of duplicate publications.

Making the JMS provider client available to the JMS nodes

Configurable services are defined for a number of JMS providers. You can choose one of the predefined services, or you can create a service for a new provider, or for one of the existing providers. The predefined services are listed in Configurable services properties.

  • If you want to use the WebSphere® MQ JMS provider, and you have installed WebSphere MQ in the default location on the broker system, the properties are already set and you do not have to change them.
  • If you want to use the WebSphere MQ JMS provider, and you have installed WebSphere MQ in a different (nondefault) location, or if you want to use one of the other defined services, you must set the jarsURL property to identify the location of the service JAR files on the broker system. On Windows, the file location cannot be a mapped network drive on a remote Windows computer; the directory must be local or on a storage area network (SAN) disk.

    Use the mqsireportproperties command to view the provider properties, and the mqsichangeproperties command to set or modify the properties.

  • If no service is defined for your JMS provider, or if you want to create another service for an existing JMS provider, use the mqsicreateconfigurableservice command to identify the new service and to set its properties.
  • When you configure the node, select the appropriate service from the list of predefined services shown for the JMS provider name property, or type in the name of your required service.
  • Some JMS providers provide an alternative interface to the standard JMS specification for particular JMS API calls. In these cases, IBM supplies a Java class to interface with that proprietary API. For example, if the JMS nodes use BEA WebLogic as the JMS provider, and the nodes have to participate in an XA coordinated message flow, you must modify the configurable services properties that are associated with that vendor. For more information, see Configuring the broker to enable a JMS provider's proprietary API.
  • Some JMS providers, such as the BEA WebLogic provider, do not update the optional JMSXDeliveryCount field in the JMS message header; therefore, JMSInput node backout processing is not possible. To cope with any failures in the message flow, connect the Failure terminal of the JMSInput node.
  • To connect to different versions of a JMS provider, create a JMSProviders configurable service for each version of the JMS provider, then set the jarsURL property to a unique path.

Connecting the terminals

For each message that is received successfully, the JMSInput node routes the message to the Out terminal. If this action fails, the message is retried. If the retry threshold is reached, where the threshold is defined by the Backout threshold property of the node, the message is routed to the Failure terminal. You can connect nodes to the Failure terminal to handle this condition.

If an exception occurs in the failure path and the message is transactional, the path is tried again until the number of attempts is twice the Backout threshold. If that limit is exceeded, the message is routed to the Backout destination. If an exception occurs in the failure path and the message is non-transactional, the message is routed directly to the Backout destination. If you have not connected nodes to the Failure terminal, the message is routed directly to the Backout destination. If you do not define a Backout destination, the message is rolled back.

If processing is not resumed after you restart the broker or integration server, check the Deployment Log for a cause, such as an incorrect parser specified in the node properties. Correct the problem and redeploy the message flow. If the message itself is not valid, remove the message from the input queue to resume processing.

If the message is caught by the JMSInput node after an exception has been generated elsewhere in the message flow, the message is routed to the Catch terminal. If you have not connected nodes to the Catch terminal, the node backs out transactional messages for redelivery until the problem is resolved, or the Backout threshold is reached. If the threshold is reached, the message is routed to the Backout destination. If you have not connected nodes to the Catch terminal and the message is non-transactional, the message is routed directly to the Backout destination. If you do not define a Backout destination, the message is rolled back.

Configuring for coordinated transactions

When you include a JMSInput node in a message flow, the value that you set for Transaction mode defines whether messages are received under sync point. See Configuring for coordinated JMS transactions.

Configuring for batch acknowledgment

You can configure the JMSInput node to send a batch acknowledgment for receipt of non-transactional JMS messages. See Configuring the JMSInput node for batch message processing.

Terminals and properties

When you have put an instance of the JMSInput 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 that do not have a default value defined are marked with an asterisk.

The terminals of the JMSInput node are described in the following table.
Terminal Description
Failure The output terminal to which the message is routed if an error occurs. Even if the Validation property is set, messages that are propagated to this terminal are not validated.
Out The output terminal to which the message is routed if it is retrieved successfully.
Catch The output terminal to which the message is routed if an exception is generated downstream and caught by this node.

The following tables describe the node properties. The column headed M indicates whether the property is mandatory (marked with an asterisk if you must enter a value when no default is defined); the column headed C indicates whether the property is configurable (you can change the value when you add the message flow to the BAR file to deploy it).

The Description properties of the JMSInput node are described in the following table.
Property M C Default Description
Node name No No The node type, JMSInput 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.
The Basic properties of the JMSInput node are described in the following table.
Property M C Default Description mqsiapplybaroverride command property
Source queue No Yes Selected The name of the queue from which the node receives incoming messages. If the node is to read from a queue (point-to-point), select Source queue and enter the name of the source queue, which is the JMS queue that is listed in the bindings file. This property is mutually exclusive with Subscription topic. sourceQueueName
Subscription topic No Yes Cleared The name of the topic to which the node is subscribed. If the node is to read from a Subscription topic (publish/subscribe), select Subscription topic and enter the name of the subscription topic.
  • If you select Subscription topic, the node operates in the publish/subscribe message domain only.
  • This property is mutually exclusive with Source queue.
  • The Subscription topic name must conform to the standards of the JMS provider that is being used by the node.
topic
Durable subscription ID No Yes   The identifier for a durable subscription topic. If the node is to receive publications from a durable subscription topic, enter a Durable subscription ID.
  • Removing a durable subscription is a separate administration task. For information about removing a durable subscription see the JMS provider documentation.
  • This property is valid only when a Subscription topic string has been specified.
durableSubscriptionID
The JMS Connection properties of the JMSInput node are described in the following table.
Property M C Default Description mqsiapplybaroverride command property
JMS provider name Yes No WebSphere MQ Select a JMS vendor name from the list, or enter a name of your choice. When you select a name from the list, the Initial context factory property is updated automatically with the relevant Java class. If you enter your own JMS provider name, you must also enter a value for the Initial context factory The name must match the name of a configurable service that is defined for the broker to which you deploy the message flow. Alternatively, you can specify the JMSProviders configurable service.  
Initial context factory No Yes com.sun.jndi.fscontext. RefFSContextFactory The starting point for a JNDI namespace.

A JMS application uses the initial context to obtain and look up the connection factory and queue or topic objects for the JMS provider. If you select a JMS provider name from the list in JMS provider name, the Initial context factory property is updated automatically with the relevant Java class. If you enter your own JMS provider name, you must also enter a value for the Initial context factory. The default value is com.sun.jndi.fscontext.RefFSContextFactory, which defines the file-based Initial context factory for the WebSphere MQ JMS provider.

If the node is set to use your own JMS Provider, and the corresponding Configurable services property of the mqsichangeproperties definition has the InitialContextFactory attribute set, this attribute overrides the setting on the node.

initialContextFactory
Location JNDI bindings No Yes   The system path or the LDAP location for the bindings file. The bindings file contains definitions for the JNDI administered objects that are used by the JMSInput node.
When you enter a value for Location JNDI bindings, ensure that it complies with the following instructions:
  • Construct the bindings file before you deploy a message flow that contains a JMSInput node.
  • Do not include the file name of the bindings file in this field.
  • If you have specified an LDAP location that requires authentication, configure the LDAP principal (user ID) and LDAP credentials (password) separately. These values are configured at broker level. For information about configuring these values, see mqsicreatebroker command and mqsichangebroker command.
  • The string value must include a supported URL prefix that has a URL handler that is available on the class path.

For information about constructing the JNDI administered objects bindings file, see the JMS provider documentation.

If the node is set to use your own JMS Provider, and the corresponding Configurable services property of the mqsichangeproperties definition has the jndiBindingsLocation attribute set, this attribute overrides the setting on the node.

locationJndiBindings
Connection factory name No Yes   The name of the connection factory that is used by the JMSInput node to create a connection to the JMS provider. This name must exist in the bindings file. The Connection factory name can be a JMS QueueConnectionFactory or a JMS TopicConnectionFactory, but it must match the message model that is used by the node. You can also specify the generic JMS ConnectionFactory, which can be used for both JMS queue or JMS topic destinations. connectionFactoryName
Backout destination No Yes   The JMSInput node sends input messages to this destination when errors prevent the message flow from processing the message, and the message must be removed from the input destination. The backout destination name must exist in the bindings file. backoutDestination
Backout threshold No Yes 0 The value that controls when a redelivered message is put to the backout destination. For example, if the value is 3, the JMS provider attempts to deliver the message to the input destination three times. After the third attempted delivery, the message is removed from the input destination and is sent to the Backout destination.

See Configuring the backout threshold property.

 

The JMSInput node Input Message Parsing properties are described in the following table.

Property M C Default Description
Message domain No No BLOB The domain that is used to parse the message. If the field is blank then the default is BLOB.
Message model No No Cleared The name or location of the message model schema file in which the message is defined. This list is populated with all available message model schema files for the Message domain that you have selected.
Message No No Cleared The name or location of the message root within your message model schema file. This list is populated with all available messages that are defined in the Message model that you have selected.
Physical format No No Cleared The name of the physical format of the message. If you are using the MRM or IDOC parser, select the physical format of the incoming message from the list. This list includes all the physical formats that you have defined for the selected message model. If you set the Message domain property to DataObject, you can set this property to XML or SAP ALE IDoc. Set this property to SAP ALE IDoc when you have to parse a bit stream from an external source and generate a message tree.
The properties of the Parser Options for the JMSInput node are described in the following table.
Property M C Default Description
Parse timing No No On Demand This property controls when an input message is parsed. Valid values are:
  • On Demand
  • Immediate
  • Complete

Parse timing is, by default, set to On Demand, which causes parsing of the message to be delayed. To cause the message to be parsed immediately, see Parsing on demand.

Build tree using XML schema data types No No Cleared This property controls whether the XMLNSC parser creates syntax elements in the message tree with data types taken from the XML schema.

For more information about how the XMLNSC parser operates, see Manipulating messages in the XMLNSC domain.

Use XMLNSC compact parser for XMLNS domain No No Cleared This property controls whether the XMLNSC Compact Parser is used for messages in the XMLNS Domain. If you set this property, the message data is displayed under XMLNSC in nodes that are connected to the output terminal when the input MQRFH2 header or Input Message Parsing properties Message domain is XMLNS.
Retain mixed content No No Cleared This property controls whether the XMLNSC parser creates elements in the message tree when it encounters mixed text in an input message. If you select the check box, elements are created for mixed text. If you clear the check box, mixed text is ignored and no elements are created.
Retain comments No No Cleared This property controls whether the XMLNSC parser creates elements in the message tree when it encounters comments in an input message. If you select the check box, elements are created for comments. If you clear the check box, comments are ignored and no elements are created.
Retain processing instructions No No Cleared This property controls whether the XMLNSC parser creates elements in the message tree when it encounters processing instructions in an input message. If you select the check box, elements are created for processing instructions. If you clear the check box, processing instructions are ignored and no elements are created.
Opaque elements No No Blank This property is used to specify a list of elements in the input message that are to be opaquely parsed by the XMLNSC parser. Opaque parsing is performed only if validation is not enabled (that is, if Validate is None); entries that are specified in Opaque Elements are ignored if validation is enabled.
The Message Selectors properties of the JMSInput node are described in the following table. Set these properties to filter messages. For a description of how to construct the JMS message selector, see JMS message selector.
Property M C Default Description
Application property No No   The message selector that filters messages according to the application property value.

If the JMS provider is required to filter messages, based on message properties that are set by the originating JMS client application, enter a selector string for Application property, specifying both the property name and the selection conditions; for example, OrderValue > 200.

Leave Application property blank if you do not want the input node to make a selection based on application property.

Timestamp No No   The message selector that filters messages according to the JMSTimestamp.

If the JMS provider is required to filter messages that have been generated at specific times, enter a selector string for Timestamp, where the value is an unqualified Java millisecond time; for example, 105757642321. Qualify the selector with operators, such as =, BETWEEN or AND.

Leave Timestamp blank if you do not want the input node to make a selection based on the JMSTimeStamp.

Delivery mode No No All The message selector that filters messages according to the message delivery mode.
If the JMS provider is required to filter messages based on the JMSDeliveryMode header value in the JMS messages, select an option for Delivery mode from the list:
  • Select Non Persistent to receive messages that are marked as nonpersistent by the originating JMS client application.
  • Select Persistent to receive messages that are marked as persistent by the originating JMS client application.
  • Select All to receive both persistent and nonpersistent messages. (This value is the default.)
Priority No No   The message selector that filters messages according to the message priority.

If the JMS provider is required to filter messages based on the JMSPriority header value in the JMS message, enter a selector string for Priority.

Valid values for Priority are from 0 (lowest) to 9 (highest). For example, enter = 5 to receive messages of priority 5, > 4 to receive messages with a priority greater than 4, or BETWEEN 4 AND 8 to receive messages with a priority in the range 4 - 8.

Leave Priority blank if you do not want the input node to make a selection based on the JMSPriority.

Message ID No No   The message selector that filters messages according to the message ID.

If the JMS provider is required to filter messages based on the JMSMessageID header, enter a selector string for Message ID. For example, enter > WMBRK123456 to return messages where the Message ID is greater than WMBRK123456.

Leave Message ID blank if you do not want the input node to make a selection based on JMSMessageID.

Redelivered No No   If the JMS provider is required to filter messages based on the JMSRedelivered header, enter a selector string for Redelivered:
  • Enter = FALSE if the input node accepts only messages that have not been redelivered by the JMS provider.
  • Enter = TRUE if the input node accepts only messages that have been redelivered by the JMS provider.
  • Leave Redelivered blank if you do not want the input node to make a selection based on JMSRedelivered.
Correlation ID No No   The message selector that filters messages according to the correlation ID.

If the JMS provider is required to filter messages based on the JMSCorrelationID header, enter a selector string for Correlation ID. For example, = WMBRKABCDEFG returns messages with a Correlation ID that matches this value.

Leave Correlation ID blank if you do not want the input node to make a selection based on JMSCorrelationID.

The Advanced properties of the JMSInput node are described in the following table.
Property M C Default Description
Transaction mode Yes No No
This property controls whether the message is received under a JMS transaction. Valid values are Yes and No.
  • Select No to receive the message using a non-transactional JMS session.
  • Select Yes to receive the message using a transactional JMS session. The JMS transaction can be either local or XA coordinated. To use an XA transaction, using an XA JMS session, you must also select the message flow property Coordinated Transaction in the BAR file properties. See Configuring for coordinated JMS transactions.
The value set for Transaction mode on the JMSInput node is inherited by nodes downstream in the message flow that have their Transaction mode set to Automatic. Other resources that perform work within the message flow, such as DB2® or WebSphere MQ, use transactions regardless of the node's Transaction mode setting, and commit their transaction after the message is processed.
The Validation properties of the JMSInput node are described in the following table. For more details, see Validating messages and Validation properties.
Property M C Default Description mqsiapplybaroverride command property
Validate No Yes None This property controls whether validation takes place. Valid values are:
  • None
  • Content and Value
  • Content

If you select Content or Content and Value, select an option from the Failure action list.

validateMaster
Failure action No No Exception This property controls what happens if validation fails. You can set this property only if you set Validate to Content or Content and Value. Valid values are:
  • User Trace
  • Local Error Log
  • Exception (The default value)
  • Exception List
 
The Monitoring properties of the node are described in the following table.
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; see Configuring monitoring event sources using monitoring properties for details.

You can enable and disable events that are shown here by selecting or clearing the Enabled check box.


ac24820_.htm | Last updated Friday, 21 July 2017