Configuring the Eclipse Amlen resource adapter to preserve message order for inbound communication

When you want to process messages in the order in which they are received, you must consider the values that are assigned to the following activation specification properties.

To preserve message order, you must have only one consumer and for topic destinations, subscriptions must be unshared. Message delivery order can be disrupted when transactions are rolled back or when transaction recovery occurs in a global transaction context. For more information, see Message order limitations with the Eclipse Amlen resource adapter.

You can configure a clientId in this scenario. JMS allows only one connection per clientId. As you are using one connection in this scenario, clientId can be set.

If you want to preserve message order in a WebSphere® Application Server cluster, you must set clientId. If clientId is not set, then a connection from a different WebSphere Application Server is considered as a new subscription. Setting a clientId allows only one WebSphere Application Server in the cluster to connect to Eclipse Amlen. If this WebSphere Application Server stops or disconnects, another WebSphere Application Server connects to the same session and the message order is preserved.

Configure the Eclipse Amlen resource adapter properties

Activation specification configuration
Consider the settings of the following activation specification properties when you configure the Eclipse Amlen resource adapter to preserve message order for inbound communication:
  • clientId
    The client ID for this connection.
    You might want to set a client ID so that you can restrict connections into Eclipse Amlen based on the client ID that is specified in the connection policy. You can also limit the actions that a connected client can perform based on the client ID that is specified in the messaging policy.
    If you want to preserve message order in a WebSphere Application Server cluster, you must set clientId.
  • server
    The Eclipse Amlen host name or IP address.
    You must specify the host name or IP address of the endpoint that you configured.
  • port
    The port of the endpoint that you configured.
  • concurrentConsumers
    The maximum number of consumers on this connection.
    If you want to preserve message order, you must set concurrentConsumers to 1 to ensure that there is only one consumer.
  • subscriptionShared
    Specifies whether a subscription is shared between consumers or not.
    If you want to preserve message order for topic destinations, you must set this value to NonShared.
    If subscriptionDurability is set to Durable, then clientId must be set for this case because clientId is required for unshared durable subscriptions.
Specify one of the following options:
  • destination and destinationType
    destination specifies the name of the topic from which messages are received. destinationType specifies the type of destination.
    The value of destinationType must be set tojavax.jms.Topic for a topic destination or to javax.jms.Queue for a queue destination.
  • destinationLookup
    The name of a JNDI object that represents the Eclipse Amlen topic from which messages are received.