You are viewing a plain text version of this content. The canonical link for it is here.
Posted to log4j-user@logging.apache.org by ja...@cardsetc.com on 2001/04/23 05:31:58 UTC

Changing categories for long-running application?

Folks,

Is it going to be possible to change the categories of an application
whilst it is still running? I would like to be able to turn on categories
for a class when it becomes necessary to debug a particular part of the
application, without having to restart it...

Regards,
James W.


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


Re: Changing categories for long-running application?

Posted by Paul Glezen <pg...@atdial.net>.
james.webster@cardsetc.com wrote:
> Is it going to be possible to change the categories of an application
> whilst it is still running? I would like to be able to turn on categories
> for a class when it becomes necessary to debug a particular part of the
> application, without having to restart it...
>
You can programmatically change attributes of log4j classes without any
problem.  It seems like you may be asking, "Can I change a config file
and have log4j change along with it, without having to restart the
app?"  You can also do this. Check out the configAndWatch method on the
configurator class.

- Paul
-- 
Beware of bugs in the above code.  I have
only proved it correct, not tried it.
-Don Knuth

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