Thanks Mark for your help.
Janusz

-----Original Message-----
From: Mark Womack [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 28, 2002 4:25 AM
To: 'Log4J Users List'
Subject: RE: MDC layout parameter


When I last looked at Lumbermill, I don't remember seeing much in the
way of
filtering, but maybe I just missed it.  Chainsaw (which is being added
the
log4j project) does support extensive filtering, but only supports NDC
directly.  MDC is too new to be supported yet (since 1.2 has not shipped
yet), but if you are putting the MDC value in the message, you could
filter
it via the message text.

Glad you got it to work!
-Mark

-----Original Message-----
From: Janusz Dalecki [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, March 26, 2002 6:57 PM
To: Log4J Users List
Subject: RE: MDC layout parameter


Thanks Mark,
This works fine.
How can I filter them per MDC in say Lumbermill GUI?
Janusz

fyi
Point taken, I will raise bug next time - thanks.
-----Original Message-----
From: Mark Womack [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, March 27, 2002 1:54 PM
To: 'Log4J Users List'
Subject: RE: MDC layout parameter


fyi, I filed a bug against PatternLayout javadoc for not documenting the
%X
pattern converter.

-Mark

-----Original Message-----
From: Mark Womack 
Sent: Tuesday, March 26, 2002 5:20 PM
To: 'Log4J Users List'
Subject: RE: MDC layout parameter


Janusz,

The answer is in the log4j/helpers/PatternParser.java code (used by
PatternLayout.java).  %x is for NDC.  %X is for MDC.  You will probably
want
to specify the particular MDC key, and that would be like this:

%X{<key name>}

Try it and see if it works for you.

-Mark

[Ceki, I think the PatternLayout javadoc needs to be updated to include
this
new conversion pattern.]

-----Original Message-----
From: Janusz Dalecki [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, March 26, 2002 4:16 PM
To: [EMAIL PROTECTED]
Subject: MDC layout parameter


Hi,
I would like MDC to print my sub-system name (my sub-system is separate
app running under jvm). I am using log4j 1.2 beata.
I am trying to use MDC because if I understand properly all children
threads of the main thread will use the same context value, and that is
exactly what I want.
I can't get that to work - I am using in my PatternLayout %x flag to do
that - is that the reason it does not work. I was trying to look inside
a code, but can't find anything.
Janusz



--
To unsubscribe, e-mail:
<mailto:[EMAIL PROTECTED]>
For additional commands, e-mail:
<mailto:[EMAIL PROTECTED]>

--
To unsubscribe, e-mail:
<mailto:[EMAIL PROTECTED]>
For additional commands, e-mail:
<mailto:[EMAIL PROTECTED]>

--
To unsubscribe, e-mail:
<mailto:[EMAIL PROTECTED]>
For additional commands, e-mail:
<mailto:[EMAIL PROTECTED]>


--
To unsubscribe, e-mail:
<mailto:[EMAIL PROTECTED]>
For additional commands, e-mail:
<mailto:[EMAIL PROTECTED]>

--
To unsubscribe, e-mail:
<mailto:[EMAIL PROTECTED]>
For additional commands, e-mail:
<mailto:[EMAIL PROTECTED]>


--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to