Class TemporaryQueueReplyManager
- java.lang.Object
-
- org.apache.camel.support.service.BaseService
-
- org.apache.camel.support.service.ServiceSupport
-
- org.apache.camel.component.jms.reply.ReplyManagerSupport
-
- org.apache.camel.component.jms.reply.TemporaryQueueReplyManager
-
- All Implemented Interfaces:
AutoCloseable
,ReplyManager
,org.apache.camel.Service
,org.apache.camel.ShutdownableService
,org.apache.camel.StatefulService
,org.apache.camel.SuspendableService
,org.springframework.jms.listener.SessionAwareMessageListener
public class TemporaryQueueReplyManager extends ReplyManagerSupport
AReplyManager
when using temporary queues.
-
-
Field Summary
-
Fields inherited from class org.apache.camel.component.jms.reply.ReplyManagerSupport
camelContext, correlation, correlationProperty, endpoint, executorService, listenerContainer, log, replyTo, replyToLatch, replyToTimeout, scheduledExecutorService
-
-
Constructor Summary
Constructors Constructor Description TemporaryQueueReplyManager(org.apache.camel.CamelContext camelContext)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected org.springframework.jms.listener.AbstractMessageListenerContainer
createListenerContainer()
protected ReplyHandler
createReplyHandler(ReplyManager replyManager, org.apache.camel.Exchange exchange, org.apache.camel.AsyncCallback callback, String originalCorrelationId, String correlationId, long requestTimeout)
javax.jms.Destination
getReplyTo()
Gets the reply to queue being usedprotected void
handleReplyMessage(String correlationID, javax.jms.Message message, javax.jms.Session session)
void
setReplyToSelectorHeader(org.apache.camel.Message camelMessage, javax.jms.Message jmsMessage)
To be used when a reply queue is used with a custom JMS selector is being used.void
updateCorrelationId(String correlationId, String newCorrelationId, long requestTimeout)
Updates the correlation id to the new correlation id.-
Methods inherited from class org.apache.camel.component.jms.reply.ReplyManagerSupport
doStart, doStop, onMessage, processReply, registerReply, setCorrelationProperty, setEndpoint, setOnTimeoutExecutorService, setReplyTo, setScheduledExecutorService, waitForProvisionCorrelationToBeUpdated
-
Methods inherited from class org.apache.camel.support.service.BaseService
build, doBuild, doFail, doInit, doLifecycleChange, doResume, doShutdown, doSuspend, fail, getStatus, init, isBuild, isInit, isNew, isRunAllowed, isShutdown, isStarted, isStarting, isStartingOrStarted, isStopped, isStopping, isStoppingOrStopped, isSuspended, isSuspending, isSuspendingOrSuspended, resume, shutdown, start, stop, suspend
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
-
-
-
Method Detail
-
getReplyTo
public javax.jms.Destination getReplyTo()
Description copied from interface:ReplyManager
Gets the reply to queue being used- Specified by:
getReplyTo
in interfaceReplyManager
- Overrides:
getReplyTo
in classReplyManagerSupport
-
createReplyHandler
protected ReplyHandler createReplyHandler(ReplyManager replyManager, org.apache.camel.Exchange exchange, org.apache.camel.AsyncCallback callback, String originalCorrelationId, String correlationId, long requestTimeout)
- Specified by:
createReplyHandler
in classReplyManagerSupport
-
updateCorrelationId
public void updateCorrelationId(String correlationId, String newCorrelationId, long requestTimeout)
Description copied from interface:ReplyManager
Updates the correlation id to the new correlation id. This is only used when useMessageIDasCorrelationID option is used, which means a provisional correlation id is first used, then after the message has been sent, the real correlation id is known. This allows us then to update the internal mapping to expect the real correlation id.- Parameters:
correlationId
- the provisional correlation idnewCorrelationId
- the real correlation idrequestTimeout
- the timeout
-
handleReplyMessage
protected void handleReplyMessage(String correlationID, javax.jms.Message message, javax.jms.Session session)
- Specified by:
handleReplyMessage
in classReplyManagerSupport
-
setReplyToSelectorHeader
public void setReplyToSelectorHeader(org.apache.camel.Message camelMessage, javax.jms.Message jmsMessage) throws javax.jms.JMSException
Description copied from interface:ReplyManager
To be used when a reply queue is used with a custom JMS selector is being used.- Throws:
javax.jms.JMSException
-
createListenerContainer
protected org.springframework.jms.listener.AbstractMessageListenerContainer createListenerContainer() throws Exception
- Specified by:
createListenerContainer
in classReplyManagerSupport
- Throws:
Exception
-
-