logging-log4net-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Adriano Labate" <adriano.lab...@polyright.com>
Subject RE: Using log4net with web services
Date Mon, 04 Sep 2006 16:20:27 GMT
Hi Dean,

Thank you for your reply.

You gave me the answer I was looking for. 
What I didn't know was how to find the log4net configuration file in the root or logs directory.
Your demo app and LoggingGoodies class were very useful too.

Thank you once again.
Adriano Labate

-----Message d'origine-----
De : Dean Fiala [mailto:dfiala@celadonlabs.com] 
Envoyé : vendredi, 1 septembre 2006 16:03
À : 'Log4NET User'
Objet : RE: Using log4net with web services

Adriano,
Working with log4Net and webservices would be very similar to working with a
web application.

You could initialize it on the service page itself, but doing it in the
global.asax is probably a better way to go.  I prefer the XML configuration
option using a separate config file. 

I have a little demo app for doing all this here.
http://www.vpsw.com/log4net/default.aspx  The source code can be found
zipped here http://www.vpsw.com/log4net/files/LogTheWorldC.zip

If you are going to log to a file or the windows Event Log, you will need to
take a couple of extra steps to configure your server.  To log to a file,
you'll need to give write permissions to the ASP.NET user on the directory
the file is located. For setting up the Event Log, check out
http://support.microsoft.com/default.aspx?scid=kb;en-us;329291.

HTH,
Dean Fiala

Chief Technology Officer
Celadon Laboratories, Inc.
http://www.celadonlabs.com
Microsoft MVP






-----Original Message-----
From: Adriano Labate [mailto:adriano.labate@polyright.com] 
Sent: Friday, September 01, 2006 3:41 AM
To: log4net-user@logging.apache.org
Subject: Using log4net with web services

Hi

I would like to use log4net to log from a web service (asmx file).

I am quite new to web services and .NET but I've uses log4j for long years
before.

Could anyone give me some advice about how integrate log4net with web
services ? Where/how to initialize it ? Where/how to configure it?

Is there something specific to web services, i.e its stateless behavior ?

Best regards
Adriano Labate





Mime
View raw message