[
https://issues.apache.org/jira/browse/LOG4J2-3437?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17507554#comment-17507554
]
Pooja Pandey edited comment on LOG4J2-3437 at 3/16/22, 12:52 PM:
-----------------------------------------------------------------
[~pkarwasz],
Thanks for your response.
I see that below code doesn't execute since getContext() is not accessible.
final Configuration config = ((LoggerContext)
LogManager.getContext(false)).getConfiguration();
was (Author: JIRAUSER285751):
[~pkarwasz],
Thanks for your response.
> Log4j 1.x bridge Request to support programmatically configuring Log4j.
> -----------------------------------------------------------------------
>
> Key: LOG4J2-3437
> URL: https://issues.apache.org/jira/browse/LOG4J2-3437
> Project: Log4j 2
> Issue Type: Bug
> Components: Log4j 1.2 bridge
> Affects Versions: 2.17.2
> Reporter: Pooja Pandey
> Priority: Major
>
> As per log4j migration documentation
> ([https://logging.apache.org/log4j/2.x/manual/migration.html),|https://logging.apache.org/log4j/2.x/manual/migration.html)]
> I understand that currently log4j 1.x bridge 2.17.2 doesn't support
> programmatically configuring log4j appenders.
> *#### Limitations of the Log4j 1.x bridge*
> # *They must not programmatically configure Log4j.*
>
> In our application, we have a requirement where we need to add many
> FileAppender programmatically with various log threshold values.
>
> Hoping to get this feature supported in future versions for log4j1.x bridge.
>
--
This message was sent by Atlassian Jira
(v8.20.1#820001)