DefaultMessageListenerContainer
@Deprecated public class DefaultMessageListenerContainer102 extends DefaultMessageListenerContainer
DefaultMessageListenerContainer
for the JMS 1.0.2 specification,
not relying on JMS 1.1 methods like SimpleMessageListenerContainer itself.
This class can be used for JMS 1.0.2 providers, offering the same facility as DefaultMessageListenerContainer does for JMS 1.1 providers.
AbstractJmsListeningContainer.SharedConnectionNotInitializedException
CACHE_AUTO, CACHE_CONNECTION, CACHE_CONSUMER, CACHE_NONE, CACHE_SESSION, DEFAULT_RECOVERY_INTERVAL, DEFAULT_THREAD_NAME_PREFIX
DEFAULT_RECEIVE_TIMEOUT
lifecycleMonitor, sharedConnectionMonitor
logger
Constructor and Description |
---|
DefaultMessageListenerContainer102()
Deprecated.
|
Modifier and Type | Method and Description |
---|---|
protected javax.jms.Connection |
createConnection()
Deprecated.
This implementation overrides the superclass method to use JMS 1.0.2 API.
|
protected javax.jms.MessageConsumer |
createConsumer(javax.jms.Session session,
javax.jms.Destination destination)
Deprecated.
This implementation overrides the superclass method to use JMS 1.0.2 API.
|
protected javax.jms.Session |
createSession(javax.jms.Connection con)
Deprecated.
This implementation overrides the superclass method to use JMS 1.0.2 API.
|
protected javax.jms.Connection |
getConnection(JmsResourceHolder holder)
Deprecated.
This implementation overrides the superclass method to accept either
a QueueConnection or a TopicConnection, depending on the domain.
|
protected javax.jms.Session |
getSession(JmsResourceHolder holder)
Deprecated.
This implementation overrides the superclass method to accept either
a QueueSession or a TopicSession, depending on the domain.
|
protected boolean |
isClientAcknowledge(javax.jms.Session session)
Deprecated.
This implementation overrides the superclass method to avoid using
JMS 1.1's Session
getAcknowledgeMode() method. |
createDefaultTaskExecutor, doInitialize, doRescheduleTask, doShutdown, establishSharedConnection, getActiveConsumerCount, getCacheLevel, getConcurrentConsumers, getIdleConsumerLimit, getIdleTaskExecutionLimit, getMaxConcurrentConsumers, getMaxMessagesPerTask, getScheduledConsumerCount, handleListenerSetupFailure, initialize, isRecovering, isRegisteredWithDestination, messageReceived, noMessageReceived, recoverAfterListenerSetupFailure, refreshConnectionUntilSuccessful, refreshDestination, scheduleNewInvokerIfAppropriate, setCacheLevel, setCacheLevelName, setConcurrency, setConcurrentConsumers, setIdleConsumerLimit, setIdleTaskExecutionLimit, setMaxConcurrentConsumers, setMaxMessagesPerTask, setRecoveryInterval, setTaskExecutor, sharedConnectionEnabled, sleepInbetweenRecoveryAttempts, start, startSharedConnection, stop, stopSharedConnection
createListenerConsumer, doReceiveAndExecute, getTransactionManager, isPubSubNoLocal, isSessionLocallyTransacted, receiveAndExecute, receiveMessage, setPubSubNoLocal, setReceiveTimeout, setSessionTransacted, setTransactionManager, setTransactionName, setTransactionTimeout, shouldCommitAfterNoMessageReceived
checkMessageListener, commitIfNecessary, doExecuteListener, doInvokeListener, doInvokeListener, executeListener, getDefaultSubscriptionName, getDestination, getDestinationDescription, getDestinationName, getDurableSubscriptionName, getExceptionListener, getMessageListener, getMessageSelector, handleListenerException, invokeErrorHandler, invokeExceptionListener, invokeListener, isAcceptMessagesWhileStopping, isExposeListenerSession, isSubscriptionDurable, rollbackIfNecessary, rollbackOnExceptionIfNecessary, setAcceptMessagesWhileStopping, setDestination, setDestinationName, setDurableSubscriptionName, setErrorHandler, setExceptionListener, setExposeListenerSession, setMessageListener, setMessageSelector, setSubscriptionDurable, validateConfiguration
afterPropertiesSet, createSharedConnection, destroy, doStart, doStop, getBeanName, getClientId, getPausedTaskCount, getPhase, getSharedConnection, isActive, isAutoStartup, isRunning, logRejectedTask, prepareSharedConnection, refreshSharedConnection, rescheduleTaskIfNecessary, resumePausedTasks, runningAllowed, setAutoStartup, setBeanName, setClientId, setPhase, shutdown, stop
getDestinationResolver, isPubSubDomain, resolveDestinationName, setDestinationResolver, setPubSubDomain
convertJmsAccessException, getConnectionFactory, getSessionAcknowledgeMode, isSessionTransacted, setConnectionFactory, setSessionAcknowledgeMode, setSessionAcknowledgeModeName
public DefaultMessageListenerContainer102()
protected javax.jms.Connection getConnection(JmsResourceHolder holder)
getConnection
in class AbstractPollingMessageListenerContainer
holder
- the JmsResourceHoldernull
if none foundprotected javax.jms.Session getSession(JmsResourceHolder holder)
getSession
in class AbstractPollingMessageListenerContainer
holder
- the JmsResourceHoldernull
if none foundprotected javax.jms.Connection createConnection() throws javax.jms.JMSException
createConnection
in class JmsAccessor
javax.jms.JMSException
- if thrown by JMS API methodsConnectionFactory.createConnection()
protected javax.jms.Session createSession(javax.jms.Connection con) throws javax.jms.JMSException
createSession
in class JmsAccessor
con
- the JMS Connection to create a Session forjavax.jms.JMSException
- if thrown by JMS API methodsConnection.createSession(boolean, int)
protected javax.jms.MessageConsumer createConsumer(javax.jms.Session session, javax.jms.Destination destination) throws javax.jms.JMSException
createConsumer
in class AbstractPollingMessageListenerContainer
session
- the JMS Session to create a MessageConsumer fordestination
- the JMS Destination to create a MessageConsumer forjavax.jms.JMSException
- if thrown by JMS API methodsprotected boolean isClientAcknowledge(javax.jms.Session session) throws javax.jms.JMSException
getAcknowledgeMode()
method.
The best we can do here is to check the setting on the listener container.isClientAcknowledge
in class JmsAccessor
session
- the JMS Session to checkjavax.jms.JMSException
- if thrown by JMS API methodsSession.getAcknowledgeMode()
,
Session.CLIENT_ACKNOWLEDGE
Copyright © 2015. All rights reserved.