JBossESB - JBossESBEIP - Message Store
-
Pattern Description
Store messages into a persistent store.
Implementation
We offer two implementions of the Message Store. One is a based on storing messages in a relational database, while
the other one is based on a JackRabbit which is an implementation of jsr170.
Configuration
While the Message Store is meant to be used in custom actions, we have two actions of our own specific to access the Message Store.
Message Persister
The message persister simply persists a message to the store. The action configuration looks like:
... <action name="PersistAction" class="org.jboss.soa.esb.actions.MessagePersister"> <property name="classfication" value="DLQ"></property> <property name="message-store-type" value="urn:jboss/esb/persistence/type/DATABASE"></property> </action> ...
Attribute | Required | Description |
---|---|---|
classification | yes | Used to classify the message (free format) |
message-store-type | yes | Can be either "urn:jboss/esb/persistence/type/DATABASE" or "urn:jboss/esb/persistence/type/JCR" |
Store Message
... <action name="MessageStoreAction" class="org.jboss.soa.esb.actions.actions.MessagePersister"></action> ...
The unique URI is set in the property: 'org.jboss.soa.esb.messagestore.message-uri'
Retrieve Message
... <action name="MessageStoreAction" process="getMessage" class="org.jboss.soa.esb.actions.actions.MessagePersister"></action> ...
You will have to specify the unique URI is set in the property: 'org.jboss.soa.esb.messagestore.message-uri' and the action will return the message from the store.
Retrieve Messages for a classification
... <action name="MessageStoreAction" process="getMessages" class="org.jboss.soa.esb.actions.actions.MessagePersister"></action> ...
You will have to specify the property: 'org.jboss.soa.esb.messagestore.classification' and the action will return a message with in the body a Map containing all the message for that classification <DLQ,RDLVR,STORE>.
No attributes can be specified for this action.
More information
Quickstarts:
Comments