Return-Path: Delivered-To: apmail-jakarta-avalon-dev-archive@jakarta.apache.org Received: (qmail 44463 invoked by uid 500); 13 Aug 2001 14:49:09 -0000 Mailing-List: contact avalon-dev-help@jakarta.apache.org; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: Reply-To: "Avalon Development" Delivered-To: mailing list avalon-dev@jakarta.apache.org Received: (qmail 44415 invoked from network); 13 Aug 2001 14:49:08 -0000 Content-Type: text/plain; charset="iso-8859-1" From: Peter Donald To: "Avalon Development" Subject: Re: AW: LogKit - FileRotation Date: Tue, 14 Aug 2001 00:42:17 +1000 X-Mailer: KMail [version 1.2] References: In-Reply-To: X-Wisdom-Cookie: Information is not knowledge, knowledge is not wisdom. MIME-Version: 1.0 Message-Id: <01081400421701.00830@helm.realityforge.org> Content-Transfer-Encoding: 8bit X-Spam-Rating: h31.sny.collab.net 1.6.2 0/1000/N On Tue, 14 Aug 2001 00:03, Carsten Ziegeler wrote: > > Peter Donald wrote: > > > > On Mon, 13 Aug 2001 23:19, Carsten Ziegeler wrote: > > > On what basis does the rotation work? File size or date? > > > > Both or either ;) I used an > > > > interface RollCondition > > { > > boolean roll( LogEvent event, File file ); > > } > > > > that allowed you to select the conditions under which you roll. > > > > > I wrote yesterday (!) > > > > eek ! It must be the season for it ;) > > > > > a simple FileTarget which combines > > > both attempts, e.g. the usual rotation is done by date: > > > Using a configuration a backup is created at the beginning > > > of every hour, 12 hours or day. When during this period > > > of time the size of the log gets to big (is also configurable), > > > it is also backuped and a new log is created. > > > > > > Perhaps we could join forces here? > > > > Abvsolutely. The other thing I started to implement was an interface like > > > > interface RollStrategy > > { > > File nextFile( File oldFile ); > > } > > Do you also have an interface for testing when to roll? Yep - see above (RollCondition) ;) > > Carsten > > > Which would do the actuall rolling. So you could select the strategy with > > which you name files - ie > > > > my.log > > my.log.1 > > my.log.2 > > my.log.3 > > (Files after 3rd generation are deleted) > > > > vs > > > > my.log > > my.log.20010722 > > my.log.20010611 > > ... > > (logs are infinite and use dates to roll) > > > > etc. > > > > So you had configurable generation count (ie number of files that > > could be > > present), format of filename etc. > > > > Howeverything I did was raw and untested properly so it may be > > better to work > > together to get once better tested system ;) > > > > > Carsten > > > > > > Open Source Group sunShine - b:Integrated > > > ================================================================ > > > Carsten Ziegeler, S&N AG, Klingenderstrasse 5, D-33100 Paderborn > > > www.sundn.de mailto: cziegeler@sundn.de > > > ================================================================ > > > > > > > Peter Donald wrote: > > > > > > > > On Mon, 13 Aug 2001 22:52, Bernhard Huber wrote: > > > > > Hi > > > > > > > > Hi, > > > > > > > > > I was implementing a FileRotation for LogKit, but not using > > > > > the very lattest LogKit interfaces. > > > > > > > > kool. > > > > > > > > > Is there a need for this feature? > > > > > > > > yes very much so. > > > > > > > > > As I understand > > > > > long running server-programs will write big log files. Maybe I have > > > > > overseen something but FileRotation is needed in production > > > > > environment, or shall Cocoon2, etc get restarted ever day :-) ? > > > > > > > > I have actually implemented FileRollTarget ages ago (a year > > > > or two) but I > > > > > > didn't own it. I actually reimplemented it a few days ago but > > > > wasn't willing > > > > to put it into CVS without more testing .. however if you > > > > already have a > > > > > > tested version .... that would be useful ;) > > > > > > > > Cheers, > > > > > > > > Pete > > > > > > > > *-----------------------------------------------------* > > > > > > > > | "Faced with the choice between changing one's mind, | > > > > | and proving that there is no need to do so - almost | > > > > | everyone gets busy on the proof." | > > > > | - John Kenneth Galbraith | > > > > > > > > *-----------------------------------------------------* > > > > > > > > --------------------------------------------------------------------- > > > > To unsubscribe, e-mail: avalon-dev-unsubscribe@jakarta.apache.org > > > > For additional commands, e-mail: avalon-dev-help@jakarta.apache.org > > > > > > --------------------------------------------------------------------- > > > To unsubscribe, e-mail: avalon-dev-unsubscribe@jakarta.apache.org > > > For additional commands, e-mail: avalon-dev-help@jakarta.apache.org > > > > -- > > Cheers, > > > > Pete > > > > *-----------------------------------------------------* > > * "Faced with the choice between changing one's mind, * > > * and proving that there is no need to do so - almost * > > * everyone gets busy on the proof." * > > * - John Kenneth Galbraith * > > *-----------------------------------------------------* > > > > --------------------------------------------------------------------- > > To unsubscribe, e-mail: avalon-dev-unsubscribe@jakarta.apache.org > > For additional commands, e-mail: avalon-dev-help@jakarta.apache.org > > --------------------------------------------------------------------- > To unsubscribe, e-mail: avalon-dev-unsubscribe@jakarta.apache.org > For additional commands, e-mail: avalon-dev-help@jakarta.apache.org -- Cheers, Pete *-----------------------------------------------------* * "Faced with the choice between changing one's mind, * * and proving that there is no need to do so - almost * * everyone gets busy on the proof." * * - John Kenneth Galbraith * *-----------------------------------------------------* --------------------------------------------------------------------- To unsubscribe, e-mail: avalon-dev-unsubscribe@jakarta.apache.org For additional commands, e-mail: avalon-dev-help@jakarta.apache.org