Package io.micronaut.jms.listener
Class JMSListenerContainerFactory
java.lang.Object
io.micronaut.jms.listener.JMSListenerContainerFactory
Deprecated.
as of 2.1.1
Generates and tracks
JMSListenerContainer
within the Bean Context.- Since:
- 1.0.0
- Author:
- Elliott Pope
- See Also:
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptiongetRegisteredListener
(String destination) Deprecated.TheJMSListenerContainer
that is listening to the givendestination
.<T> void
registerListener
(JMSConnectionPool connectionPool, String destination, MessageHandler<T> listener, Class<T> clazz, JMSDestinationType type) Deprecated.Generates a newJMSListenerContainer
and registers the providedMessageHandler
as the receiving executable method.<T> void
registerListener
(JMSConnectionPool connectionPool, String destination, javax.jms.MessageListener listener, Class<T> clazz, boolean transacted, int acknowledgeMode, JMSDestinationType type, Optional<String> messageSelector) Deprecated.Generates a newJMSListenerContainer
and registers the providedMessageListener
as the receiving executable method.void
shutdown()
Deprecated.Shuts down the listeners registered with this factory.toString()
Deprecated.
-
Constructor Details
-
JMSListenerContainerFactory
public JMSListenerContainerFactory()Deprecated.
-
-
Method Details
-
registerListener
public <T> void registerListener(JMSConnectionPool connectionPool, String destination, MessageHandler<T> listener, Class<T> clazz, JMSDestinationType type) Deprecated.Generates a newJMSListenerContainer
and registers the providedMessageHandler
as the receiving executable method.NOTE: this method is not recommended for registering new
JMSListenerContainer
s however can be used to register them dynamically and allow for safe shutdown within the Bean Context.- Type Parameters:
T
- the class type- Parameters:
connectionPool
- the pooldestination
- the queue or topic namelistener
- the message listenerclazz
- the message typetype
- the destination type
-
registerListener
public <T> void registerListener(JMSConnectionPool connectionPool, String destination, javax.jms.MessageListener listener, Class<T> clazz, boolean transacted, int acknowledgeMode, JMSDestinationType type, Optional<String> messageSelector) Deprecated.Generates a newJMSListenerContainer
and registers the providedMessageListener
as the receiving executable method.NOTE: this method is not recommended for registering new
JMSListenerContainer
s however it can be used to register them dynamically and allow for safe shutdown within the Bean Context.- Type Parameters:
T
- the class type- Parameters:
connectionPool
- the pooldestination
- the queue or topic namelistener
- the message listenerclazz
- the message typetransacted
- indicates whether the session will use a local transactionacknowledgeMode
- when transacted is false, indicates how messages received by the session will be acknowledgedtype
- the destination typemessageSelector
- the message selector for the listener- See Also:
-
Session.AUTO_ACKNOWLEDGE
Session.CLIENT_ACKNOWLEDGE
Session.DUPS_OK_ACKNOWLEDGE
-
getRegisteredListener
Deprecated.TheJMSListenerContainer
that is listening to the givendestination
.- Parameters:
destination
- the name of a queue or topic- Returns:
- the container
-
shutdown
@PreDestroy public void shutdown()Deprecated.Shuts down the listeners registered with this factory. -
toString
Deprecated.
-