Slashdot Mirror


Software Logging Schemes?

MySkippy writes "I've been a software engineer for just over 10 years, and I've seen a lot of different styles of logging in the applications I've worked on. Some were extremely verbose — about 1 logging line for every 2 lines of code. Others were very lacking, with maybe 1 line in 200 devoted to logging. I personally find that writing debug and informational messages about every 2 to 5 lines works well for debugging an issue, but can become cumbersome when reading through a log for analysis. I like to write warning messages when thresholds or limits are being approached — these tend to be infrequent. I log errors whenever I catch one (but I've never put a 'fatal' message in my code, because if it's truly a fatal error I probably didn't catch it). Recently I came across log4j and log4net and have begun using them both. That brings me to my question: how do the coders on Slashdot handle logging in their code?"

4 of 225 comments (clear)

  1. Attention Slash-Dot and Internet in General: by Anonymous Coward · · Score: -1, Offtopic

    Ladies and gentlemen, I am horny.

    1. Re:Attention Slash-Dot and Internet in General: by Anonymous Coward · · Score: -1, Offtopic

      Evfer since I wuz a little boy, my momma told me that I was the topic. Now I am much older but some things never change: I am the topic, nothing human is untopicable of me. I hereby lodge my formal protest against this unjustificiable moderitationism blatantly smeared upon my (above) postage.

  2. Bunion Software's Blue Ox Lumberjack Logging by c0d3r · · Score: 0, Offtopic

    Checkout Bunion's Blue Ox Lumberjack Logging Solutions for industrial strength Logging functionality.

    http://en.wikipedia.org/wiki/Paul_Bunyan_(lumberjack)

  3. You Ain't No 'Engineer' code monkey !! by Anonymous Coward · · Score: -1, Offtopic

    You MIGHT be a computer programmer, but you ain't no software engineer, code monkey, 'cause there be no such thing as a software engineer...lessen you count sanitation engineerin' too.