> -----Original Message----- > From: Ceki G�lc� [mailto:[EMAIL PROTECTED] > Sent: 09 June 2004 10:14 > To: Log4NET User > Subject: RE: XML Layout > > > At 12:40 AM 6/9/2004, Nicko Cadell wrote: > >Another solution is to ignore the main issue. > > :-) > > >If you can setup a rolling strategy that rolls the file on > startup if > >it exists then you have a situation where you never need > append to the file. > > Good point. In my analysis outlined in my previous message, > this case was mentally merged into a "rollover", but you are > right it is a slightly different case.
Actually it could be possible to tie this behaviour to the append flag inherited from FileAppender. Currently when using the RollingFileAppender it would seem to be wrong not to set append to true. If it is set to false then the RollingFileAppender must always roll any existing file out of the way before creating the new file. > >Each time the app starts it rolls the current log file out > of the way > >before creating a new file. This will impact the rolling > strategies you > >may be able to select for this file format. You may also end > up with a > >lot of files just containing the header and footer (one per > execution) > >if you aren't logging any messages. > > It actually can get worse because rollovers can fail. In case > of failed rollover, we skip the rollover and continue > appending to the existing log file. Error handling and recovery is always a difficult problem. Nicko
