logging-log4net-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Nicko Cadell" <ni...@neoworks.com>
Subject RE: can derived classes change the RollingFileAppender filename?
Date Mon, 18 Jul 2005 19:42:19 GMT
Currently it is not possible to change the way that the
RollingFileAppender names size rolled files. The '.N' numbered postfix
is assumed in a number of places in the code making this feature non
trivial to implement.


> -----Original Message-----
> From: sv bobj [mailto:svbobj@gmail.com] 
> Sent: 07 July 2005 01:31
> To: log4net-user@logging.apache.org
> Subject: can derived classes change the RollingFileAppender filename?
> I am using the RollingFileAppender, but don't like the way it 
> tacks a "1", "2", "3" on the end of the filename because it 
> means you can't double click on the filenames to view them.
>    i.e.   log.txt.1, log.txt.2, log.txt.3     don't load very well
> when you click on them.
> Is there some way to override the filename and provide your own?
> I was looking at the source and it looks like 
> "GetNextOutputFileName()" is the right function, but it is 
> not marked virtual.
> What I'd like, is some way to have the rolling file appender 
> create log files with the names
>     log_<process_pid>_1.txt
>     log_<process_pid>_2.txt
>     ...
>     log_<process_pid>_n.txt
> Is that possible?

View raw message