JMS Transport Parameters¶
About the JMS transport¶
The Java Message Service (JMS) transport in WSO2 Micro Integrator allows you to easily send and receive messages to queues and topics of any JMS service that implements the JMS specification.
Java Message Service (JMS) is a widely used API in Java-based Message Oriented Middleware(MOM) applications. It facilitates loosely coupled, reliable, and asynchronous communication between different components of a distributed application. It supports two asynchronous communication models for messaging as follows:
- Point-to-point model: In this model message communication happens from one JMS client to another JMS client through a dedicated queue.
- Publish and subscribe model: In this model message communication happens from one JMS client(publisher) to many JMS clients(subscribers) through a topic.
- Queues: point-to-point.
- Topics: publish and subscribe.
- Shared Topic Subscription
- JMSX Delivery Count
- JMS Message Delivery Delay
Parameters¶
Given below is the list of JMS transport parameters that can be configured when you create a proxy service.
JMS connection factory parameters¶
Configuration parameters for the JMS receiver and the sender are XML fragments that represent JMS connection factories.
TOML Parameter Name |
Axis2 Parameter Name |
Description |
---|---|---|
parameter.initial_naming_factory | java.naming.factory.initial |
JNDI initial context factory class. The class must implement the java.naming.spi.InitialContextFactory interface. The default value is org.apache.activemq.jndi.ActiveMQInitialContextFactory .
|
parameter.provider_url | java.naming.provider.url |
URL of the JNDI provider. By default, the value is tcp://localhost:61616 .
|
parameter.naming_security_principal | java.naming.security.principal |
JNDI Username. |
parameter.naming_security_credential | java.naming.security.credentials |
JNDI password. |
parameter.transactionality | transport.Transactionality |
Preferred mode of transactionality.
Note: In the Micro Integrator, JMS transactions only work with either the Callout mediator or the Call mediator in blocking mode. The possible values are as follows:
|
parameter.transaction_jndi_name | transport.UserTxnJNDIName |
JNDI name to be used to require user transaction. The default value is java:comp/UserTransaction .
|
parameter.cache_user_transaction | transport.CacheUserTxn |
Whether caching for user transactions should be enabled or not. By default, this setting is true .
|
parameter.session_transaction | transport.jms.SessionTransacted |
Whether the JMS session should be transacted or not. By default, this setting is true (if transactionality is 'local').
|
parameter.session_acknowledgement | transport.jms.SessionAcknowledgement |
JMS session acknowledgment mode. The possible values are as follows:
|
parameter.connection_factory_name | transport.jms.ConnectionFactoryJNDIName |
The JNDI name of the connection factory.
The possible values are as follows:
|
parameter.connection_factory_type | transport.jms.ConnectionFactoryType |
Type of the connection factory. The possible values are queue , or topic . The default value is queue .
|
parameter.jms_spec_version | transport.jms.JMSSpecVersion |
JMS API version. Possible values are 1.1 or 1.0.2b . The default value is 1.1 .
|
parameter.username | transport.jms.UserName | The JMS connection username. |
parameter.password | transport.jms.Password | The JMS connection password. |
parameter.destination | transport.jms.Destination | The JNDI name of the destination. |
parameter.destination_type | transport.jms.DestinationType |
Type of the destination. Possible values are queue , or topic . The default setting is queue .
|
parameter.default_reply_destination | transport.jms.DefaultReplyDestination | JNDI name of the default reply destination. |
parameter.default_destination_type | transport.jms.DefaultReplyDestinationType |
Type of the reply destination. Possible values are queue , or topic . Defaults to the type of the destination.
|
parameter.message_selector | transport.jms.MessageSelector | Message selector implementation. |
parameter.subscription_durable | transport.jms.SubscriptionDurable |
Whether the connection factory is subscription durable or not. By default, this parameter is set to false .
|
parameter.durable_subscriber_client_id | transport.jms.DurableSubscriberClientID | The ClientId parameter when using durable subscriptions. This parameter is required if the value specified as transport.jms.ubscriptionDurable is true .
|
parameter.durable_subscriber_name | transport.jms.DurableSubscriberName |
The name of the durable subscriber. This parameter is required if the value specified as transport.jms.SubscriptionDurable is true .
|
parameter.pub_sub_local | transport.jms.PubSubNoLocal |
Whether the messages should be published by the same connection through which they were received. The default setting is false .
|
parameter.cache_level | transport.jms.CacheLevel |
The cache level with which JMS objects should be cached at start up. You can configure this in the ei.toml file if Micro Integrator acts as a JMS producer. Example:
auto .
|
parameter.receive_timeout | transport.jms.ReceiveTimeout |
Time to wait for a JMS message during polling. Set this parameter value to a negative integer to wait indefinitely. Set to zero to prevent waiting. The default value is 1000 milliseconds.
|
parameter.concurrent_consumer | transport.jms.ConcurrentConsumers |
Number of concurrent threads to be started to consume messages when polling. You can specify any positive integer. However, for topics, this parameters should always be set to 1 .
|
parameter.max_concurrent_consumer | transport.jms.MaxConcurrentConsumers |
Maximum number of concurrent threads to use during polling. You can specify any positive integer. The default value is 1 .
|
parameter.idle_task_limit | transport.jms.IdleTaskLimit |
The number of idle runs per thread before it dies out. You can specify any positive integer. The default value is 10 .
|
parameter.max_message_per_task | transport.jms.MaxMessagesPerTask |
The maximum number of successful message receipts per thread. You can specify any positive integer. The default value is |
parameter.initial_reconnection_duration | transport.jms.InitialReconnectDuration |
Initial reconnection attempts duration in milliseconds. You can specify any positive integer. The default value is 10000 milliseconds.
|
parameter.reconnect_progress_factor | transport.jms.ReconnectProgressFactor |
Factor by which the reconnection duration will be increased. You can specify any positive integer. The default value is 2 .
|
parameter.max_reconnect_duration | transport.jms.MaxReconnectDuration |
Maximum reconnection duration in milliseconds. The default value is 3600000 milliseconds (1 hour).
|
parameter.reconnect_interval | transport.jms.ReconnectInterval | Reconnection interval in milliseconds. The default value is 3600000 milliseconds (1 hour).
|
parameter.max_jsm_connection | transport.jms.MaxJMSConnections |
Maximum cached JMS connections in the producer level. You can specify any positive integer. The default value is 10 .
|
parameter.max_consumer_error_retrieve_before_delay | transport.jms.MaxConsumeErrorRetriesBeforeDelay |
Number of retries on consume errors before sleep delay kicks in. You can specify any positive integer. The default value is 20 .
|
parameter.consume_error_delay | transport.jms.ConsumeErrorDelay |
Sleep delay when a consume error is encountered (in milliseconds). You can specify any positive integer. The default value is 100 milliseconds.
|
parameter.consume_error_progression | transport.jms.ConsumeErrorProgression |
Factor by which the consume error retry sleep will be increased. You can specify any positive integer. The default value is 2.0 .
|
MaxConsumeErrorRetryCount | transport.jms.MaxConsumeErrorRetryCount |
The maximum number of times the consumer should retry upon receiving a consumer error. You need to introduce this parameter only if the Broker has issues in notifying the Exception Listeners about the exceptions occurred. You can specify any positive integer. The default value is 1 .
|
Service-level JMS configuration parameters¶
Parameter Name | Description |
---|---|
transport.jms.ConnectionFactory | Name of the JMS connection factory the service should use. You can specify the name of an already defined connection factory |
transport.jms.PublishEPR | JMS EPR to be published in the WSDL. Specify a JMS EPR. |
transport.jms.ContentType | Specifies how the transport listener should determine the content type of received messages. Specify a simple string value, in which case the transport listener assumes that the received messages always have the specified content type, or a set of rules. For more information, see http://axis.apache.org/axis2/java/transports/jms.html#Service_configuration. |
transport.jms.MessagePropertyHyphens
|
Specifies the action to be taken when there are JMS Message property names that contain hyphens. The possible values are as follows:
|