You could use the log4j-core implementation of LoggerContext.getLoggers()
to list the current known loggers.
https://logging.apache.org/log4j/2.x/log4j-core/apidocs/org/apache/logging/log4j/core/LoggerContext.html#getLoggers()
You could also use the JMX API for LoggerConfigAdminMBean to query the
I know the separator is a problem in some cases. But I though it was the
minus sign, which causes problems like
https://issues.apache.org/jira/browse/LOG4J2-1013 which I am not sure how
to best solve :-(
Gary
On Mon, Nov 28, 2016 at 4:52 PM, Remko Popma wrote:
> Aha!
> Looks like works, but
>
Aha!
Looks like works, but
doesn't.
For some reason I thought a default value could be specified after a second
colon ':'.
I guess I got confused with something else.
I can see the FileAppender plugin being initialized with the resolved lookup
string. The status log doesn't show that the l
Ralph, thanks for replying.
I tried that before sending the email but a file ${sys:proc:unknown}.log was
created...
Should it make any difference whether the File appender or the RollingFile
appender is used? (I only tried File.)
Where in the code is the lookup resolved? (I couldn't find it i
On Mon, Nov 28, 2016 at 2:13 PM, Marcel Stör wrote:
> On 28.11.16 21:58, Gary Gregory wrote:
> > Does this help:
> > https://garygregory.wordpress.com/2016/01/11/changing-log-
> levels-in-log4j2/
>
> Yes it does, thanks a lot! Since you commented only on the first part of
> my message (how to mig
On 28.11.16 21:58, Gary Gregory wrote:
> Does this help:
> https://garygregory.wordpress.com/2016/01/11/changing-log-levels-in-log4j2/
Yes it does, thanks a lot! Since you commented only on the first part of
my message (how to migrate our Servlet to log4j2) can I assume there's
no out-of-the-box l
Does this help:
https://garygregory.wordpress.com/2016/01/11/changing-log-levels-in-log4j2/
?
Gary
On Mon, Nov 28, 2016 at 12:28 PM, Marcel Stör wrote:
> For years we've been shipping our web applications with a simple and
> ugly but tremendously effective Servlet to switch log4j log levels at
For years we've been shipping our web applications with a simple and
ugly but tremendously effective Servlet to switch log4j log levels at
runtime[1]. In fact, it's been so effective on countless occasions
(read: debugging sessions in production environments) that we never
bothered looking into alt
Using a single $ works as that is resolved during configuration. As I recall,
‘$${nnn:…}’ does not work. I specify ${sys:catalina.home} in the filename for
all of my web apps.
Ralph
> On Nov 27, 2016, at 11:10 PM, Remko Popma wrote:
>
> Does the FileAppender support lookups in the configured