[
https://issues.apache.org/jira/browse/LOG4J2-1429?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15330970#comment-15330970
]
Ralph Goers edited comment on LOG4J2-1429 at 6/15/16 1:14 AM:
--------------------------------------------------------------
You can use
{code}
LoggerContext initialize(final String name, final ClassLoader loader, final
List<URI> configLocations, final Object externalContext)
{code}
to initialize Log4j. You can gather the config locations in any manner you want
and then pass them to the initialize method. The initialize method is in the
Configurator class.
was (Author: [email protected]):
You can use
{code}
LoggerContext initialize(final String name, final ClassLoader loader, final
List<URI> configLocations, final Object externalContext)
{code}
to initialize Log4j. You can gather the config locations in any manner you want
and then pass them to the initialize method.
> Configuration File Include
> ---------------------------
>
> Key: LOG4J2-1429
> URL: https://issues.apache.org/jira/browse/LOG4J2-1429
> Project: Log4j 2
> Issue Type: New Feature
> Components: Configurators
> Reporter: Scot Hale
>
> Configuration File Include
> logback has a configuration feature that allows a fragment of a file to be
> included. The file source can be a file, classpath resource, or a URL. The
> feature is documented here:
> http://logback.qos.ch/manual/configuration.html#fileInclusion . This
> requested feature need not be implemented the same. Instead of fragments, it
> would probably be okay to supply a full configuration and merge it. Either
> implementation would work for my specific use case.
> Each of the included files should be checked for changes on the
> monitorInterval to allow a reload of the configuration.
> Also includes can be considered "optional", which allows the resource to be
> missing.
> The main use case I have as a requestor, is to create a configuration and
> package it in a jar. The jar is provided to multiple applications which can
> adjust the logging levels at runtime for diagnostic purposes with well known
> included files.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]