org.apache.logging.log4j.core.appender.jms
Class JmsTopicAppender
java.lang.Object
org.apache.logging.log4j.core.AbstractLifeCycle
org.apache.logging.log4j.core.filter.AbstractFilterable
org.apache.logging.log4j.core.appender.AbstractAppender
org.apache.logging.log4j.core.appender.jms.JmsTopicAppender
- All Implemented Interfaces:
- Appender, Filterable, LifeCycle
@Plugin(name="JMSTopic",
category="Core",
elementType="appender",
printObject=true)
public final class JmsTopicAppender
- extends AbstractAppender
Appender to write to a JMS Topic.
Method Summary |
void |
append(LogEvent event)
Actual writing occurs here. |
static JmsTopicAppender |
createAppender(String name,
String factoryName,
String providerURL,
String urlPkgPrefixes,
String securityPrincipalName,
String securityCredentials,
String factoryBindingName,
String topicBindingName,
String userName,
String password,
Layout<? extends Serializable> layout,
Filter filter,
String ignore)
Create a JmsTopicAppender. |
Methods inherited from class org.apache.logging.log4j.core.AbstractLifeCycle |
getState, isInitialized, isStarted, isStarting, isStopped, isStopping, setStarted, setStarting, setState, setStopped, setStopping |
append
public void append(LogEvent event)
- Actual writing occurs here.
- Parameters:
event
- The LogEvent.
createAppender
@PluginFactory
public static JmsTopicAppender createAppender(@PluginAttribute(value="name")
String name,
@PluginAttribute(value="factoryName")
String factoryName,
@PluginAttribute(value="providerURL")
String providerURL,
@PluginAttribute(value="urlPkgPrefixes")
String urlPkgPrefixes,
@PluginAttribute(value="securityPrincipalName")
String securityPrincipalName,
@PluginAttribute(value="securityCredentials")
String securityCredentials,
@PluginAttribute(value="factoryBindingName")
String factoryBindingName,
@PluginAttribute(value="topicBindingName")
String topicBindingName,
@PluginAttribute(value="userName")
String userName,
@PluginAttribute(value="password")
String password,
@PluginElement(value="Layout")
Layout<? extends Serializable> layout,
@PluginElement(value="Filters")
Filter filter,
@PluginAttribute(value="ignoreExceptions")
String ignore)
- Create a JmsTopicAppender.
- Parameters:
name
- The name of the Appender.factoryName
- The fully qualified class name of the InitialContextFactory.providerURL
- The URL of the provider to use.urlPkgPrefixes
- A colon-separated list of package prefixes for the class name of the factory class that
will create a URL context factorysecurityPrincipalName
- The name of the identity of the Principal.securityCredentials
- The security credentials of the Principal.factoryBindingName
- The name to locate in the Context that provides the TopicConnectionFactory.topicBindingName
- The name to use to locate the Topic.userName
- The userid to use to create the Topic Connection.password
- The password to use to create the Topic Connection.layout
- The layout to use (defaults to SerializedLayout).filter
- The Filter or null.ignore
- If "true"
(default) exceptions encountered when appending events are logged; otherwise
they are propagated to the caller.
- Returns:
- The JmsTopicAppender.
Copyright © 1999-2014 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.