Class PropertyLogContextConfigurator
- java.lang.Object
-
- org.jboss.logmanager.configuration.PropertyLogContextConfigurator
-
- All Implemented Interfaces:
LogContextConfigurator
public class PropertyLogContextConfigurator extends Object implements LogContextConfigurator
A default log context configuration.If the input stream is
nullan attempt is made to find alogging.propertiesfile. If the file is not found, a service loader is used to find the first implementation of aLogContextConfigurator. If that fails a defaultConsoleHandleris configured with the pattern%d{yyyy-MM-dd'T'HH:mm:ssXXX} %-5p [%c] (%t) %s%e%n.Locating the
logging.propertieshappens in the following order:- The
logging.configurationsystem property is checked - The current threads ClassLoader.getResourceAsStream(String) class loader} for a
logging.properties - Finally
Class.getResourceAsStream(String)is used to locate alogging.properties
- Author:
- James R. Perkins
-
-
Field Summary
-
Fields inherited from interface org.jboss.logmanager.LogContextConfigurator
EMPTY
-
-
Constructor Summary
Constructors Constructor Description PropertyLogContextConfigurator()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidconfigure(LogContext logContext, InputStream inputStream)Configure the given log context according to this configurator's policy.
-
-
-
Method Detail
-
configure
public void configure(LogContext logContext, InputStream inputStream)
Description copied from interface:LogContextConfiguratorConfigure the given log context according to this configurator's policy. If a configuration stream was provided, that is passed in to this method to be used or ignored. The stream should remain open after this method is called.- Specified by:
configurein interfaceLogContextConfigurator- Parameters:
logContext- the log context to configure (notnull)inputStream- the input stream that was requested to be used, ornullif none was provided
-
-