> -----Original Message-----
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] 
> Sent: 09 June 2005 14:27
> To: log4net-user@logging.apache.org
> Subject: file appender in web apps
> 
> Hi, 
> 
> I am using log4net 1.2.9 and .Net 1.1 
> 
> I am planning to use a file appender to log Debug messages 
> for a web application. Are there any drawbacks/limitations in 
> using file appender for a web app given the fact that there 
> will be many concurrent users. Also ideally what should be 
> the locking mode? Minimal or Exclusive. 

If only one process is writing to the file then using Exclusive is
preferred because it has much higher performance. If you are using a web
garden then you will have multiple processes service the requests and
will need to use Minimal locking.


> If Exclusive then 
> when will the lock be released ? 

When the FileAppender is closed.


> Also do I need to explicitly call LogManager.ShutDown() or 
> any other methods in the Application_End event? 

log4net tries to hook the AppDomain unload event to notify the appenders
to shutdown. There is no harm in explicitly calling shutdown.

Cheers,

Nicko


> 
> Thanks,
> Hemant
> 

Reply via email to