[prev in list] [next in list] [prev in thread] [next in thread] 

List:       log4j-dev
Subject:    Re: Log4j- maxHistory property in TimeBasedRollingPolicy
From:       Ashwine <ashwini.shetty0502 () gmail ! com>
Date:       2011-05-05 6:12:10
Message-ID: 31547710.post () talk ! nabble ! com
[Download RAW message or body]


Hi Ralph, 

Figured out the problem. the log4j property for deleting old archived files
is maxBackupIndex and not maxHistory. 
I found this property in the RollingFileAppender class of the log4j jar.
We are however using TimeBasedRollingPolicy which uses the
apache-log4j-extras version of the RollingFileAppender which i figured out
does not contain this property. 



Ralph Goers wrote:
> 
> What makes you think that maxHistory is a valid property?
> 
> Ralph
> 
> On May 4, 2011, at 12:38 AM, Ashwine wrote:
> 
> > 
> > We are using log4j-1.2.16.jar and apache-log4j-extras-1.1.jar to
> > implement
> > the TimeBasedRollingPolicy logging functionality using the property File
> > approach.
> > 
> > We intend to use the maxHistory Feature but are getting the following
> > warning message. 
> > 
> > maxHistory that does not exist in
> > org.apache.log4j.rolling.TimeBasedRollingPolicy
> > 
> > 1. we have checked several class files in the above mentioned jar files
> > for
> > this property but we could'nt find the maxHistory property in the
> > classes. 
> > 2. We have taken the Property file approach and this is the syntax we've
> > used. 
> > log4j.appender.GoopilAppender.RollingPolicy.maxHistory=180
> > 3. The property file approach works fine for other properties like
> > zipping
> > the log files, log file generation etc. but the maxHistory is having this
> > issue. 
> > 
> > -- 
> > View this message in context:
> > http://old.nabble.com/Log4j--maxHistory-property-in-TimeBasedRollingPolicy-tp31539197p31539197.html
> >  Sent from the Log4j - Dev mailing list archive at Nabble.com.
> > 
> > 
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: log4j-dev-unsubscribe@logging.apache.org
> > For additional commands, e-mail: log4j-dev-help@logging.apache.org
> > 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: log4j-dev-unsubscribe@logging.apache.org
> For additional commands, e-mail: log4j-dev-help@logging.apache.org
> 
> 
> 

-- 
View this message in context: \
http://old.nabble.com/Log4j--maxHistory-property-in-TimeBasedRollingPolicy-tp31539197p31547710.html
 Sent from the Log4j - Dev mailing list archive at Nabble.com.


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


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic