logging-log4net-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Chris Jerdonek" <jerdo...@granicus.com>
Subject RE: how to log to differnent textfiles?
Date Mon, 19 May 2008 11:46:55 GMT
> is it possible to combine this with a RollingFileAppender?

Yes.  This is because "LockingModel" is a property of the FileAppender
class, and the RollingFileAppender class extends FileAppender.  You can
see this for yourself if you go to the log4net SDK reference and click
on log4net.Appender -> RollingFileAppender Class.  The SDK reference is
available here:


It's also available by clicking on "SDK Reference" in the left column of
the main log4net web site.


Chris Jerdonek
Software Developer
P: (415) 357-3618 Ext. 1357
Granicus, Inc.

-----Original Message-----
From: Drinck@gmx.de [mailto:Drinck@gmx.de] 
Sent: Monday, May 19, 2008 4:40 AM
To: Log4NET User
Subject: Re: how to log to differnent textfiles?

Chris Jerdonek schrieb:
>> But when I start my application more than once, I receive a "file in 
> use" exception.  Is it possible to set the logfile path at runtime?
> You can also try using a "minimal lock," which lets multiple processes
> write to the same file.  Just add the following to your appender
> <lockingModel type="log4net.Appender.FileAppender+MinimalLock" />
> This is covered in the log4net config examples in the FileAppender
> section:
> http://logging.apache.org/log4net/release/config-examples.html
is it possible to combine this with a RollingFileAppender?

best regards,

View raw message