public class JmsManager extends AbstractManager
count
Modifier and Type | Method and Description |
---|---|
Message |
createMessage(Serializable object)
Creates a TextMessage or ObjectMessage from a Serializable object.
|
MessageConsumer |
createMessageConsumer()
Creates a MessageConsumer on this Destination using the current Session.
|
MessageProducer |
createMessageProducer()
Creates a MessageProducer on this Destination using the current Session.
|
static JmsManager |
getJmsManager(String name,
JndiManager jndiManager,
String connectionFactoryName,
String destinationName,
String username,
String password)
Gets a JmsManager using the specified configuration parameters.
|
protected void |
releaseSub()
May be overridden by Managers to perform processing while the Manager is being released and the
lock is held.
|
getContentFormat, getCount, getManager, getName, hasManager, release
public static JmsManager getJmsManager(String name, JndiManager jndiManager, String connectionFactoryName, String destinationName, String username, String password)
name
- The name to use for this JmsManager.jndiManager
- The JndiManager to look up JMS information through.connectionFactoryName
- The binding name for the ConnectionFactory
.destinationName
- The binding name for the Destination
.username
- The username to connect with or null
for no authentication.password
- The password to use with the given username or null
for no authentication.public MessageConsumer createMessageConsumer() throws JMSException
JMSException
public MessageProducer createMessageProducer() throws JMSException
JMSException
public Message createMessage(Serializable object) throws JMSException
Layout
such as PatternLayout
,
the LogEvent
message will be serialized to a String. When using a
layout such as SerializedLayout
, the LogEvent message will be
serialized as a Java object.object
- The LogEvent or String message to wrap.JMSException
protected void releaseSub()
AbstractManager
releaseSub
in class AbstractManager
Copyright © 1999-2021 Apache Software Foundation. All Rights Reserved.
Apache Logging, Apache Log4j, Log4j, Apache, the Apache feather logo, the Apache Logging project logo, and the Apache Log4j logo are trademarks of The Apache Software Foundation.