Gary Gregory created LOG4J2-1470:
------------------------------------
Summary: Add convenience API
Configurator.initializeResource(String, ClassLoader, String)
Key: LOG4J2-1470
URL: https://issues.apache.org/jira/browse/LOG4J2-1470
Project: Log4j 2
Issue Type: New Feature
Components: Configurators
Reporter: Gary Gregory
Assignee: Gary Gregory
Fix For: 2.7
Add convenience API with error checking to replace:
{code:java}
final URL url = classLoader.getResource("path/to/a/log4j2-config.xml");
final LoggerContext context = Configurator.initialize("SomeName", classLoader,
url.toURI());
{code}
with:
{code:java}
final LoggerContext context = Configurator.initializeResource("SomeName",
classLoader, "path/to/a/log4j2-config.xml");
{code}
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]