Skip to content

JMS Message Store

Introduction

Persists messages in a JMS queue inside a JMS Broker. Since messages are persisted in an orderly manner, JMS message stores implement the Store and Forward integration pattern. This message store can be configured by specifying the class as org.apache.synapse.message.store.impl.jms.JmsStore.

To try this out quickly, see the JMS Message Store example.

Properties

Listed below are the properties used for creating a JMS Message Store.

Required Properties

The following properties are required when creating a JMS Message Store.

Property Description
Message Store Name A unique name for the JMS message store.
Message Store Type Select JMS Message Store from the list.
Initial Context Factory The JNDI initial context factory class. This class must implement the java.naming.spi.InitialContextFactory interface. Initial Context Factory used to connect to the JMS broker.
Provider URL The URL of the JNDI provider. URL of the naming provider to be used by the context factory.

Optional Properties

The following optional properties can be configured when creating a JMS Message Store.

Property Description
JNDI Queue Name The message store queue name. Though this is not a required parameter, we recommend specifying a value for this.
Connection factory The JNDI name of the connection factory that is used to create jms connections. Though this is not a required parameter, we recommend specifying a value for this.
User Name The user name to connect to the broker.
Password The password to connect to the broker.
JMS API Specification Version The JMS API version to be used. Possible values are 1.1 (default) or 1.0.
vender.class.loader.enabled Set to false when using IBM MQ, which requires skipping the external class loader. Recommended when using IBM MQ.
store.jms.cache.connection true/false Enable Connection caching.
Enable Producer Guaranteed Delivery See the Properties for Guaranteed Delivery of Messages.
Failover Message Store See the Properties for Guaranteed Delivery of Messages.

Properties: Guaranteed Delivery of Messages

If you need to ensure guaranteed delivery of your messages, specify values for the following parameters:

Property Description
Enable Producer Guaranteed Delivery This flag specifies whether guaranteed delivery is enabled on the producer side. The value is set to false by default.
Failover Message Store The message store to which the store mediator should send messages when the original message store fails.
Top