I have been told to add “logging” to my code using log4net, the problem is no one can travel in time and see what real world problems the logging will need to be used to solve.<
Log events to event viewer.
Use wisely INFO DEBUG WARNING and ERROR.
when developing show everything (use the console on the server side- see below) on production , log only errors (configurable)
I create a logger in the begging of each class giving it the typeof(myClass) but that's optional...
I'm hosting the WCF in DEV as a console app - so watching the server log is easy also in the console, but once it becomes a service, you have to use event viewer....
ah - and it is very fast if you compare it to WCF "calling times" (calling from client to server) so it doesn't really effect your times, unless you has something the logs like crazy (nHibernate for example) )