Thursday, 7 December 2017

How do you handle logging?

At my company, we're in a bit of a state with regards to logging. All that happens at the moment is console.log, with the occasional console.error. We have Winston installed, but I ended up setting that to { level: 'error' } to quieten down logs slowing down prod. They go into Graylog at the moment, but nothing too advanced.I have never really got my head around proper approaches to logging in nodejs. I have looked at the debug library, but I feel like we should be using something more advanced. The service have winston, should I be logging using a winston logger?What's your own approach?

Submitted December 07, 2017 at 04:39PM by nearxanldn

No comments:

Post a Comment