I downloaded log4j-1.2.8.jar.
Along with this i found the CompositeRollingAppender.java in the contributions folder.

In this file, on line 362 the method super.setFile(fileName, append) is called.
In the FileAppender, there is no overloaded method where only two arguments are 
provided and hence it fails in the compilation.

Is this a known issue or has someone already resolved it?

Thanks 

Divya

----- Original Message ----- 
From: Divya Shetty 
To: Log4J Users List 
Sent: Saturday, November 29, 2003 11:00 AM
Subject: DailyRollingFileAppender with filesize option


Hi,

I have the following log4j property file:

log4j.rootLogger=debug, A
log4j.logger.SickPay=debug, SP

log4j.appender.SP=org.apache.log4j.DailyRollingFileAppender
log4j.appender.SP.File=COMMON~1\\Trial\\SP.log
log4j.appender.SP.MaxFileSize=1KB
log4j.appender.SP.MaxBackupIndex=6
log4j.appender.SP.layout=org.apache.log4j.PatternLayout
log4j.appender.SP.layout.ConversionPattern=%d ::%m%n

I need to roll over the file on basis of both the date and Size of the file.
When i run the application it gives me the compilation error: 
log4j:WARN No such property [maxBackupIndex] in 
org.apache.log4j.DailyRollingFileAppender.
log4j:WARN No such property [maxFileSize] in org.apache.log4j.DailyRollingFileAppender.

I checked the Mail list archive and there was a suggestion that one use 
CompositeRollingFileAppender.
Where can i find CompositeRollingFileAppender?

Could anyone suggest a way to implement this?

Regards,
Divya Shetty

Reply via email to