As I'm currently setting up Logging in my (Asp.Net Web Api) application I was reading about best practices according logging. I came along this question about logging best practices.
I was going the Ninject
-> Logging Extensions
-> Nlog / Log4Net
way, but this question (or should I say answer) made me think a second time.
At the moment I have tracing enabled, log every here and there and it feels a bit messy to have logs and traces which don't add up together.
I think that when I switch to Diagnostics Tracing and build on top of what the framework already gives me I would end up with a more complete trace. A trace which tells a complete story sounds more useful to me then a separate trace and log which both know about a part of the story. And of course I could always separate things again with listeners and filters.
But at the other hand I always learned:
Logging != Tracing
So this leaves me with the question, should I drop the logging framework, it's the starting phase of the project, or should I stick with it?
And if I drop the logging framework, should I use a interface in case we ever wanna switch to another logging/tracing framework again, or can I just make a dependency on System.Diagnostics?