I've had logging woes recently trying debug code with the help of different logging frameworks.
I have several projects for which I am responsible, and these projects have to be tested in a production-like environment (solaris on a remote server) instead of my development environment (macbook pro on my lap). I could probably do some fancy vm stuff and a little more dependency injection in my tests... but sometimes it's really more worth it to put the thing up, let it break, and read the logs to find out why. PROBLEM: log levels. When I am looking for a mysterious bug, I don't always know where the problem is so I don't always know which log lines I want to see in the logs. Maybe the one line that will illuminate the issue is at level 'trace' and I won't ever see it because it is buried under a billion other log lines (like, maybe we are siege testing). SOLUTION: Tagged logs! log = new Tagalog({ "acorn":fs.createWriteStream('../myAcorns.log') }) ... log.debug('did you steal my #acorn? ' + stolen? 'yes' : 'no') [myAcorns.log]-> did you steal my #acorn? yes AhHA! I wrote and published an alpha version of 'tagalog' on npm to test it out. It's pretty silly right now (no formatted strings, no way to print objects, etc.), but even at this stage I could use it to tag my logs and isolate the subjects I am interested in, instead of trusting yesterday me to know that tomorrow me wants a particular log line at level 'EMERGENCY! OH NOES!'. To recap: 1. tagged logs 2. debug quickly 3. ???? 4. profit! Please check it out at https://github.com/JoshRagem/tagalog and see how this idea works for you. Josh -- -- Job Board: http://jobs.nodejs.org/ Posting guidelines: https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines You received this message because you are subscribed to the Google Groups "nodejs" group. To post to this group, send email to nodejs@googlegroups.com To unsubscribe from this group, send email to nodejs+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/nodejs?hl=en?hl=en --- You received this message because you are subscribed to the Google Groups "nodejs" group. To unsubscribe from this group and stop receiving emails from it, send an email to nodejs+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.