Get JMS Queue Message

Get JMS Queue Message is an asynchronous activity that retrieves a message from the specified queue. You can use this activity to perform a receive operation on the queue as opposed to waiting for a queue message to be delivered to the Wait for JMS Queue Message activity.

General

You can use the Message Selector field on the Advanced tab to retrieve a specific queue message from the queue.

The General tab has the following fields.

Field Literal Value/Process Property/Module Property? Description
Name None The name to be displayed as the label for the activity in the process.
JMS Connection Literal Value

Module Property

The JMS connection. For details refer to, JMS Connection.
Destination Yes The name of the queue from which to retrieve the message.

The syntax of the destination name is specific to the JMS provider you are using. See the JMS provider documentation for more information about queue names.

Message Type Yes The type of the message which can be one of the following:
  • Text: The message is a java.lang.String.
  • Bytes: A stream of bytes.
  • Map: A set of name or value pairs. The names are strings, and the values are simple datatypes (JAVA primitives), an array of bytes (use the Binary datatype when mapping this data), or a string. Each item can be accessed sequentially or by its name.
  • Object: A Java object that can be serialized.
  • Object Ref: An object reference to a Java object.
  • Simple: A message with no body part.
  • Stream: A stream of Java primitives, strings, or arrays of bytes. Each value must be read sequentially.
  • XML Test: The message is XML text.
Acknowledgment Mode Yes The acknowledge mode for incoming messages. It can be one of the following:
  • Auto: the mode where the message is automatically acknowledged, when it is received.
  • Client: the mode where the message is acknowledged at a later point by using the Confirm activity. If the message is not confirmed before the process instance ends, the message is redelivered and a new process instance is created to handle the new incoming message. Ensure that your process confirms the message when using this acknowledge mode.
  • Dups OK: the mode where the message is acknowledged automatically when it is received. JMS provides this mode for lazy acknowledgment, but TIBCO ActiveMatrix BusinessWorks acknowledges messages upon receipt.
  • TIBCO EMS Explicit Client: (only available for TIBCO Enterprise Message Service) a message which is not acknowledged using the Confirm activity before the process instance ends, is redelivered instead of all messages in the session. The session is not blocked and one session handles all incoming messages for each process instance.
  • TIBCO EMS EXPLICIT Client Dups OK: (only available for TIBCO Enterprise Message Service) a message which is not acknowledged using the Confirm activity before the process instance ends, is redelivered instead of all messages in the session. The session is not blocked and one session handles all the incoming messages for each process instance. The messages however, are lazily acknowledged.
  • TIBCO EMS No Acknowledge: messages delivered using this mode do not require acknowledgment. Hence, the messages in this mode are not redelivered regardless of whether the delivery was successful.

Description

Provide a short description for the activity here.

Advanced

The Advanced tab has the following fields.

Field Literal Value/Process Property? Description
Message Selector Yes A string to determine whether a message should be received. The syntax of the message selector is determined by the JMS provider (where message properties are used instead of table column names).

See the JMS provider documentation for more information and syntax for a message selector string.

Application Properties Type None The type of application-specific message properties that is part of the message.

Output Editor

The Output Editor tab defines the schema to use for messages of type Map, Stream, or XML Text. Map messages are name or value pairs, and using this schema you can define the structure of the retrieved destination queue message. The schema defined on the Output Editor tab becomes the body of the message on the Output tab. For XML Text message type, select an XSD element. For Map and Stream message types, select an XSD type in the Output Editor tab.

Input

The following is the input for the activity.

Input Item Datatype Description
destinationQueue string The queue to which to send the request. This input item overrides the Destination field on the General tab.
timeout integer Specifies how long the message can remain active (in seconds). If set to 0, the message does not expire.
selector string A string to determine whether a message should be received. The value of this element overrides any value specified in the Message Selector field of the Advanced tab. The syntax of the message selector is determined by the JMS provider, but it is usually a subset of SQL92 (where message properties are used instead of table column names).

See the JMS provider documentation for more information and syntax for a message selector string.

Output

The following is the output of the activity.

Output Item Datatype Description
JMSHeaders complex The message header fields for the message. See Common JMS Properties and Headers for more information about message header fields.

Only properties applicable to this type of message are displayed.

JMSProperties complex The message properties for the message. See Common JMS Properties and Headers for more information about message properties.

Only properties applicable to this type of message are displayed.

Body as per message type The body of the message.

Fault

The Fault tab lists the possible exceptions thrown by this activity. See Error Codes for more information about error codes and the corrective action to take.

Fault Thrown When..
JMSInvalidInputException The input to the activity is not valid.
JMSSessionCreateException The JMS session could not be created.
JMSReceiveException The JMS receive operation failed.
ActivityTimedOutException The specified timeout is attained and the activity has not completed its execution.