logging-log4j-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From <mwom...@apache.org>
Subject RE: provide a way to specifiy the names of the RollingFileAppender's backup files
Date Thu, 26 Sep 2002 05:45:08 GMT
Hi Thomas,

Thanks for posting the suggestion.  I think we need to look at it in the
context of the other RollingFileAppender changes that are being looked at.

Would anyone more familiar with those changes like to talk about them?

-Mark

> -----Original Message-----
> From: Auinger, Thomas [mailto:Thomas.Auinger@wincor-nixdorf.com]
> Sent: Wednesday, September 25, 2002 2:30 AM
> To: 'Log4J Developers List'
> Subject: RFE: provide a way to specifiy the names of the
> RollingFileAppender's backup files
>
>
> Hi!
>
> In the current implementation, the RollingFileAppender always
> names backup files to "<filename>.1", "<filename>.2" etc.
>
> It would be great, if developers could add their own naming
> convention.
>
> This could be done using different ways (I think):
>
> a) The developer sets a naming pattern String as a parameter
> to the RollingFileAppender, which defines the filename (similar
> to PatternLayout), e.g. "%f.%d.%n", where %f = filename, %d = date,
> %n = backupIndex
>
>
> b) The developer implements an interface, which provides a
> single method to generate a filename for a backup file:
>
>  public interface BackupFilenameResolver {
>
>  	public String getFilename( int backupIndex );
>
>  }
>
> An implementing class name of this interface may then be set
> as a parameter to the RollingFileAppender (similar to how
> ObjectRenderers are currently configured)
>
>
> I would prefer soultion (b), since it is more flexible.
>
>
> Greetings from Germany,
>  Thomas
>
> --
> To unsubscribe, e-mail:
<mailto:log4j-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:log4j-dev-help@jakarta.apache.org>


--
To unsubscribe, e-mail:   <mailto:log4j-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:log4j-dev-help@jakarta.apache.org>


Mime
View raw message