Bugs item #585372, was opened at 2002-07-23 14:12
Message generated for change (Comment added) made by letiemble
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=376685&aid=585372&group_id=22866

Category: JBossServer
Group: v2.4 (stable)
>Status: Pending
Resolution: None
Priority: 5
Submitted By: Laurence Smith (lasmith)
Assigned to: Laurent Etiemble (letiemble)
Summary: Console appender looping

Initial Comment:
I have searched the forums and found there is a known 
issue when you try and configure log4j twice in that the 
console appender loops (I couldn't find a bug report 
though). This causes the logging to the console to stop 
completely and gradually eats up resources i assume.

I have also come accross the same problem when you 
configure the mbean for the log4j service by calling the 
constructor (String, int) in jboss.conf. This is so log4j 
uses the 'configure and watch' API. This is to allow me 
to turn debugging on and off at runtime (useful if you 
aren't allowed to take the site down).

Here is the line in jboss.conf:

<MLET CODE = "org.jboss.logging.Log4jService" 
ARCHIVE="jboss.jar,log4j.jar" 
CODEBASE="../../lib/ext/">
        <ARG TYPE="java.lang.String" 
VALUE="log4j.properties">
        <ARG TYPE="int" VALUE="5">
</MLET>

this appears to work ok, however when it comes to 
reloading the config file after a change the console 
appenders goes into its infinite loop. 

I am assuming this is a JBoss issue I have quickly 
looked at the source, Log4jService.java and cant see 
anything blatently obvious, so perhaps it is a log4j 
issue. I tried upgrading log4j to 1.2.5 but still had the 
same problem.

I am running JBoss 2.7 (I would have entered it in the by 
the way, though I encountered the first problem on 3 
aswell.

ls

----------------------------------------------------------------------

>Comment By: Laurent Etiemble (letiemble)
Date: 2003-11-07 12:02

Message:
Logged In: YES 
user_id=437455

Well, any suggestion ?


----------------------------------------------------------------------

Comment By: Laurent Etiemble (letiemble)
Date: 2003-10-14 13:56

Message:
Logged In: YES 
user_id=437455

The configuration file is defining a Console appender that
prints on the System.out.
The Log4j service redirects the System.out and System.err to
a category (STDOUT and STDERR at level INFO). This is done
after the first reading of the log4j.properties file.
It is when the configuration file is reloaded that the
looping occurs.

One workaround is to remove the redirection of System.out
and System.err from the Log4j service, which means that what
is printed on System.out and System.err is lost.

I don't see any easy solution to allow both the dynamic
reloading of log4j.properties and the re-direction of
System.out and System.err to the log output.

Any suggestions ?

----------------------------------------------------------------------

Comment By: Laurence Smith (lasmith)
Date: 2002-07-23 21:18

Message:
Logged In: YES 
user_id=261097

Sorry I meant JBoss 2.4.7

ls

----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=376685&aid=585372&group_id=22866


-------------------------------------------------------
This SF.net email is sponsored by: SF.net Giveback Program.
Does SourceForge.net help you be more productive?  Does it
help you create better code?   SHARE THE LOVE, and help us help
YOU!  Click Here: http://sourceforge.net/donate/
_______________________________________________
JBoss-Development mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-development

Reply via email to