public class JmsMessageDispatcher extends AbstractMessageDispatcher
JmsMessageDispatcher
is responsible for dispatching messages to JMS
destinations. All JMS semantics apply and settings such as replyTo and QoS
properties are read from the event properties or defaults are used (according to
the JMS specification)Modifier and Type | Class and Description |
---|---|
protected class |
JmsMessageDispatcher.ReplyToListener |
defaultOutboundTransformers, defaultResponseTransformers
connected, endpoint, lifecycleManager, logger, muleMessageFactory, retryTemplate
RECEIVE_NO_WAIT, RECEIVE_WAIT_INDEFINITELY
PHASE_NAME
PHASE_NAME
PHASE_NAME
PHASE_NAME
Constructor and Description |
---|
JmsMessageDispatcher(OutboundEndpoint endpoint) |
Modifier and Type | Method and Description |
---|---|
protected void |
applyOutboundTransformers(MuleEvent event) |
protected MuleMessage |
createMessageWithJmsMessagePayload(Message jmsMessage) |
protected MessageConsumer |
createReplyToConsumer(Message currentMessage,
MuleEvent event,
Session session,
Destination replyTo,
boolean topic) |
protected void |
doConnect() |
protected void |
doDisconnect() |
protected void |
doDispatch(MuleEvent event) |
protected void |
doDispose() |
protected MuleMessage |
doSend(MuleEvent event) |
protected Destination |
getReplyToDestination(Message message,
Session session,
MuleEvent event,
boolean remoteSync,
boolean topic) |
protected void |
handleMultiTx(Session session)
Deprecated.
|
protected boolean |
isDisableTemporaryDestinations() |
protected boolean |
isHandleReplyTo(Message msg,
MuleEvent event)
Some JMS implementations do not support ReplyTo or require some further fiddling of the message
|
protected void |
preTransformMessage(MuleMessage message)
This method is called before the current message is transformed.
|
protected void |
processMessage(Message msg,
MuleEvent event)
This method is called once the JMS message is created.
|
applyResponseTransformers, createLifecycleManager, getDispatcherName, getEndpoint, getWorkManager, process, returnResponse, returnResponse
activate, connect, connectHandler, createMuleMessage, createMuleMessage, createMuleMessage, createMuleMessageFactory, createNullMuleMessage, disconnect, dispose, disposeAndLogException, doInitialise, doStart, doStartHandler, doStop, getConnectEventId, getConnectionDescription, getConnector, getLifecycleState, initialise, initializeMessageFactory, initializeRetryPolicy, isConnected, isDoThreading, isStarted, isStarting, isStopped, isStopping, passivate, setEndpoint, start, stop, toString, validate, validateConnection
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
activate, createMuleMessage, createMuleMessage, getConnector, passivate, validate
connect, disconnect, getConnectionDescription, isConnected, validateConnection
initialise
dispose
getLifecycleState
public JmsMessageDispatcher(OutboundEndpoint endpoint)
protected void doDispatch(MuleEvent event) throws Exception
doDispatch
in class AbstractMessageDispatcher
Exception
protected void doConnect() throws Exception
doConnect
in class AbstractTransportMessageHandler
Exception
protected void doDisconnect() throws Exception
doDisconnect
in class AbstractTransportMessageHandler
Exception
protected boolean isDisableTemporaryDestinations()
protected MuleMessage createMessageWithJmsMessagePayload(Message jmsMessage) throws Exception
Exception
protected void preTransformMessage(MuleMessage message) throws Exception
message
- the current MuleMessage Being processedException
@Deprecated protected void handleMultiTx(Session session) throws Exception
Exception
protected MuleMessage doSend(MuleEvent event) throws Exception
doSend
in class AbstractMessageDispatcher
Exception
protected void doDispose()
doDispose
in class AbstractTransportMessageHandler
protected void processMessage(Message msg, MuleEvent event) throws JMSException
msg
- The JMS message that will be sentevent
- the current eventJMSException
- if the JmsMessage cannot be written to, this should not happen because
the JMSMessage passed in will always be newly createdprotected boolean isHandleReplyTo(Message msg, MuleEvent event) throws JMSException
msg
- The JMS message that will be sentevent
- the current eventJMSException
- if the JmsMessage cannot be written to, this should not happen because the JMSMessage passed
in will always be newly createdprotected MessageConsumer createReplyToConsumer(Message currentMessage, MuleEvent event, Session session, Destination replyTo, boolean topic) throws JMSException
JMSException
protected Destination getReplyToDestination(Message message, Session session, MuleEvent event, boolean remoteSync, boolean topic) throws JMSException, EndpointException, InitialisationException
protected void applyOutboundTransformers(MuleEvent event) throws MuleException
applyOutboundTransformers
in class AbstractMessageDispatcher
MuleException
Copyright © 2003–2015 MuleSoft, Inc.. All rights reserved.