1 May 2006 07:33
RE: DailyRollingFileAppender question
ITN (Babu Easwaramoorthy <BabuE <at> emiratesbank.com>
2006-05-01 05:33:29 GMT
2006-05-01 05:33:29 GMT
Hi Curt, Jake,
Thanks for your solutions.
My problem is resolved. I was trying to create DailyRollingFileAppender
programmatically.
-Babu
-----Original Message-----
From: Jacob Kjome [mailto:hoju <at> visi.com]
Sent: Monday, May 01, 2006 2:32 AM
To: Log4J Users List
Subject: Re: DailyRollingFileAppender question
I might be wrong, but I'll bet Babu wasn't considering
programmatically creating the DailyRollingFileAppender. Babu, I
think what you are looking for is using a system property to define
the file name for the appender. For instance...
log4j.appender.myRollingAppender.File=/logs/${myRollingAppenderFileName}
If your configuration code, make sure you set the system property
"myRollingAppenderFileName" before you call one of the configure()
methods. Or, just add something like
"-DmyRollingAppenderFileName=someFileName.log" to the command line
where you start your java program. In the latter case, you can use
Log4j auto-configuration rather than having to call configure()
manually.
Jake
(Continue reading)
Jake
> with best regards,
> Rafal
>
> ----- Original Message -----
> From: "Jacob Kjome" <hoju <at> visi.com>
> To: "Log4J Users List" <log4j-user <at> logging.apache.org>
> Sent: Friday, April 28, 2006 5:02 PM
> Subject: Re: Log4j doesn't create log files
>
>
> >
> > Where did you expect the "applicationRoot" variable to come from? If you
> > don't
RSS Feed