logging-log4j-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Blondeel Thibault <thibault.blond...@acunia.com>
Subject Re: How to work with custom Priorities?
Date Fri, 08 Feb 2002 10:14:27 GMT
Ceki Gülcü wrote:

> Thibault,
>
> No, you definitely do not need to sub-class category. I suggest that you
> run log4j with the debug option on. As in
>
> log4j.debug=true
> log4j.category.Cat=ALERT#MyProperty, A1
> ...
>
> to see that the ALERT priority is being read in.
>
> Now, if the ALERT priority is higher than the priority of your log
> statement, then
> log4j will not print anything...
>
> Hope this helps, Ceki
>

Thanks for your reply ... I found the problem ... my priorities where defined
the other way around. I mean the highest priority the lowest int_value they had
... so I had to overwrite the isGreaterOrEqual() method of the Priority class.
But now I have another problem (... the usual life of a programmer :)) ...), it
works fine with the property file  "log4j.category.Cat=ALERT#MyProperty, A1"
but not with my xml file "<priority class="MyPriority" value="alert"/>" . When I
turn de debug option at the command line -Dlog4j.debug then I can see that the
xml file is correctly being parsed but he set category to DEBUG default value
....???
Is there something wrong with my xml synthax? Can I assign one of my priorities
to the root category?

Best regards,

Thibault


--
To unsubscribe, e-mail:   <mailto:log4j-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:log4j-user-help@jakarta.apache.org>


Mime
View raw message