• (cs)

    First.

    Akismetn, you crap.

  • anon (unregistered)

    frist

    if akismet will let me post...

  • (cs) in reply to anon
    anon:
    frist

    if akismet will let me post...

    Sorry anon, yuo're late to party./

  • anon (unregistered) in reply to anon

    Thanks akismet, you let nagish beat me.

  • (cs)

    That's dumb. They should really print the stack trace to the debug log.

  • Sam (unregistered)

    This isn't that crazy. It will do things like checking log file permission and alert the user if that fails.

  • Obligatory... (unregistered)

    Yo I heard you like logging so I put logging in your logging so you can log while you log...

  • Studley (unregistered)

    It's all very well testing that the logger is logging, but it needs some additional logging to check that the logger logging is logging.

  • Z (unregistered)

    Oh, c'mon. We all know that logging costs nothing. Obviously, you have to make sure that your logging system doesn't fail, otherwise what good is it?

  • Koppernicus (unregistered)

    I have logged our deal (I have logged our deal (I have logged our deal)), pray I don't log it any further.

  • Darth Logger (unregistered)

    I have logged your logging. Pray that I don't log any further.

  • Darth Paula (unregistered) in reply to Darth Logger
    Darth Logger:
    I have logged your logging. Pray that I don't log any further.

    I LOVE YOU DARTH!!!!!

  • Ãà (unregistered)

    try { System.out.println("Attempting to comment");

    Hey, it's better to be safe than sorry right? Make sure the commenting is safe too, put it in a try/catch block.
    
    System.out.println("Commenting")
    

    } catch (Exception ex) { ex.printStackTrace(); }

  • ÃÆâ€℠(unregistered) in reply to Nagesh
    Nagesh:
    anon:
    frist

    if akismet will let me post...

    Sorry anon, yuo're late to party./

    Idiots...

  • John (unregistered)

    This is really cool! It looks like log4j. So if you change your configuration file to log at the "info" or higher level, you could have many, many, prints to standard out, with nothing showing in the log file.

    Even better, change the configuration file without telling anyone, and watch the ensuing panic.

    My Opinion: Logging that you are going to log, and doing the extra logging somewhere besides the log file, is not a good idea. It will drive you crazy.

  • what (unregistered)

    I hear you like logging in your logging yo!

  • Smiddy (unregistered)
    "What rolls down stairs alone or in pairs
    Rolls over your neighbor's dog?
    What's great for a snack and fits on your back?
    It's Log, Log, Log!
    
    It's Log, Log, it's big, it's heavy, it's wood.
    It's Log, Log, it's better than bad, it's good!
    Everyone wants a log! You're gonna love it, Log!
    Come on and get your log! Everyone needs a Log!"
    

    What wrong log?

  • (cs) in reply to Studley
    Studley:
    It's all very well testing that the logger is logging, but it needs some additional logging to check that the logger logging is logging.
    How much logs does a logger log if a logger does log logs?
  • anon (unregistered) in reply to ÃÆâ€â„Â
    ÃÆâ€â„Â:
    Nagesh:
    anon:
    frist

    if akismet will let me post...

    Sorry anon, yuo're late to party./

    Idiots...

    What kind of idiot name is "ÃÆâ€â„Â" ?

  • (cs)

    But who logs the logger that logs the logger? It is such a slippery slope for so much logging to be in the hands of so few loggers.

    Never was so much logged by so many to so few logs.

  • (cs)

    I heard about the constipated mathematician who worked out logs with a pencil but this is several orders of magnitude funnier.

  • (cs)

    Oh, okay. TRWTF is that the logger object isn't private and final. Took me awhile to realize what was wrong there.

  • (cs) in reply to boog
    boog:
    That's dumb. They should really print the stack trace to the debug log.

    Yes. Propogating the error is a good aproach for error handling.

  • (cs)

    With this kind of logging, server diskspace run out soon.

    Then you're screwed in the worst kind of way ever.

    ....

    Akismet, you crazy clown,you're at it again. What do you want us to do? WRite your stupid name in every post?

    I am off to eat Pav Bhaji. This is special snak in Mumbai. Not too common in Hyderabad. Delicacy, never less. Does Akismet hate coloured posters or just colooured comments?

  • neminem (unregistered) in reply to Nagesh
    Nagesh:
    I am off to eat Pav Bhaji. This is special snak in Mumbai.
    Nagesh might be a troll, but he seems to have good taste in food. I say "seems" because, while wikipedia insists that this is a common dish in cheap Indian places in "Asia, America, UK, Switzerland and elsewhere", I've been to a decent number of cheap Indian places here in California (which, you'll note, is part of America), and I've never even heard of it. Looks pretty tasty, though. I may be extremely white, but that doesn't stop me from thinking that Indian food is amazing. (Incidentally, I'm going out for Indian food tonight. Haven't had good Indian food in way too long.)

    Nagesh, troll or not, would you not agree that biryani is one of the greatest culinary inventions ever?

    Oh yeah, and something about logs. Reminds me a bit of the ride at the Boardwalk, near where I grew up, called Logger's Revenge (in that case, the revenge was the flume at the end. In this case, it would presumably be what happened when their disk filled up.)

  • (cs) in reply to neminem
    neminem:
    Nagesh:
    I am off to eat Pav Bhaji. This is special snak in Mumbai.
    Nagesh might be a troll, but he seems to have good taste in food. I say "seems" because, while wikipedia insists that this is a common dish in cheap Indian places in "Asia, America, UK, Switzerland and elsewhere", I've been to a decent number of cheap Indian places here in California (which, you'll note, is part of America), and I've never even heard of it. Looks pretty tasty, though. I may be extremely white, but that doesn't stop me from thinking that Indian food is amazing. (Incidentally, I'm going out for Indian food tonight. Haven't had good Indian food in way too long.)

    Nagesh, troll or not, would you not agree that biryani is one of the greatest culinary inventions ever?

    Oh yeah, and something about logs. Reminds me a bit of the ride at the Boardwalk, near where I grew up, called Logger's Revenge (in that case, the revenge was the flume at the end. In this case, it would presumably be what happened when their disk filled up.)

    Hyderabad Biryani beste in world. Hyderabad for long time ruled by Nizams. Nizam pakka ladkibaaz and marry many times (another story). So cooks of Nizam bring over recipes from all over the world to make special Biryani. Slow simmer make chicken extra tender. Unfortunate, I prefer vegetarian so have to settle for a vegetable version of original dish. Original Biryani made from goat meat. We call it mutton in India. Mutton shops very scary places to venture in to. Enjoy Indian food.

  • bleep (unregistered) in reply to neminem
    neminem:
    Nagesh:
    I am off to eat Pav Bhaji. This is special snak in Mumbai.
    Nagesh might be a troll, but he seems to have good taste in food. I say "seems" because, while wikipedia insists that this is a common dish in cheap Indian places in "Asia, America, UK, Switzerland and elsewhere", I've been to a decent number of cheap Indian places here in California (which, you'll note, is part of America), and I've never even heard of it. Looks pretty tasty, though. I may be extremely white, but that doesn't stop me from thinking that Indian food is amazing. (Incidentally, I'm going out for Indian food tonight. Haven't had good Indian food in way too long.)

    Nagesh, troll or not, would you not agree that biryani is one of the greatest culinary inventions ever?

    Oh yeah, and something about logs. Reminds me a bit of the ride at the Boardwalk, near where I grew up, called Logger's Revenge (in that case, the revenge was the flume at the end. In this case, it would presumably be what happened when their disk filled up.)

    Why would a troll not have good taste in food? We don't all eat Billy Goats, you know...

  • bleep (unregistered) in reply to bleep
    bleep:
    neminem:
    Nagesh:
    I am off to eat Pav Bhaji. This is special snak in Mumbai.
    Nagesh might be a troll, but he seems to have good taste in food. I say "seems" because, while wikipedia insists that this is a common dish in cheap Indian places in "Asia, America, UK, Switzerland and elsewhere", I've been to a decent number of cheap Indian places here in California (which, you'll note, is part of America), and I've never even heard of it. Looks pretty tasty, though. I may be extremely white, but that doesn't stop me from thinking that Indian food is amazing. (Incidentally, I'm going out for Indian food tonight. Haven't had good Indian food in way too long.)

    Nagesh, troll or not, would you not agree that biryani is one of the greatest culinary inventions ever?

    Oh yeah, and something about logs. Reminds me a bit of the ride at the Boardwalk, near where I grew up, called Logger's Revenge (in that case, the revenge was the flume at the end. In this case, it would presumably be what happened when their disk filled up.)

    Why would a troll not have good taste in food? We don't all eat Billy Goats, you know...

    or based on Nagesh's reply, maybe not....

  • Decius (unregistered)

    Why use the unnatural and artificial log(Logging) functions when you can use the natural ln(Logging) function?

  • Drew (unregistered) in reply to ÃÃ

    try { System.out.println("Error checking error checks");

    // because you never know when catching an exception will cause an exception
    
    try {
        System.out.println("Attempting to comment");
    
        Hey, it's better to be safe than sorry right? Make sure the commenting is safe too, put it in a try/catch block.
    
        System.out.println("Commenting")
    } catch (Exception ex) {
        ex.printStackTrace();
    } 
    

    } catch (Exception ex) { ex.printStackTrace(); }

  • (cs)

    Don't they know one of the E's in Java EE is Enterprise? If they really want this to be enterprisey they need to find a way to put some XML in the log format!

  • Luiz Felipe (unregistered)
    1. get the stack trace.
    2. get the scope from reflection
    3. serialize all local objects and the stack trace and the message in one big xml.
    4. put annotations all over you program method.
    5. print stack trace in constructor of all annotation classes.
    6. log that xml inside cdata of another xml.
    7. ensure that you log the logger
    8. send the log to super duper log server.
    9. put logging in every network package received in log server (pcap dump). save in xml for enterprisey.
    10. use some form of kernel attachment in the SO to log every file access. dump the file changed to an xml log, to make sure file is writen to HD.
  • syockit (unregistered) in reply to bleep
    bleep:
    bleep:
    neminem:
    Nagesh:
    I am off to eat Pav Bhaji. This is special snak in Mumbai.
    Nagesh might be a troll, but he seems to have good taste in food. I say "seems" because, while wikipedia insists that this is a common dish in cheap Indian places in "Asia, America, UK, Switzerland and elsewhere", I've been to a decent number of cheap Indian places here in California (which, you'll note, is part of America), and I've never even heard of it. Looks pretty tasty, though. I may be extremely white, but that doesn't stop me from thinking that Indian food is amazing. (Incidentally, I'm going out for Indian food tonight. Haven't had good Indian food in way too long.)

    Nagesh, troll or not, would you not agree that biryani is one of the greatest culinary inventions ever?

    Oh yeah, and something about logs. Reminds me a bit of the ride at the Boardwalk, near where I grew up, called Logger's Revenge (in that case, the revenge was the flume at the end. In this case, it would presumably be what happened when their disk filled up.)

    Why would a troll not have good taste in food? We don't all eat Billy Goats, you know...

    or based on Nagesh's reply, maybe not....

    He's almost vegetarian. He thinks people buying and selling mutton are scary. OTOH, I eat mutton biryani from time to time. I prefer beef though, I wonder why they don't make it more often here? It's not India, there shouldn't be any taboo involving beef.

  • moz (unregistered) in reply to Decius
    Decius:
    Why use the unnatural and artificial log(Logging) functions when you can use the natural ln(Logging) function?
    Because we want to log the error, not create a hard link to it.
  • Pyrexkidd (unregistered) in reply to Koppernicus

    That's no moon. It's a log logger logger logger.

  • Bert (unregistered)

    Not a wtf. On an embedded system with no filesystem you need to doublecheck your logs...

  • oheso (unregistered) in reply to boog
    boog:
    That's dumb. They should really print the stack trace to the debug log.

    Featured comment, please.

  • (cs) in reply to oheso
    oheso:
    boog:
    That's dumb. They should really print the stack trace to the debug log.
    Featured comment, please.
    That's odd. I was going to suggest that boog be terminated before he could reproduce.

    But featuring his comment is almost as good.

  • The Real Paula (unregistered) in reply to Darth Paula
    Darth Paula:
    Darth Logger:
    I have logged your logging. Pray that I don't log any further.

    I LOVE YOU DARTH!!!!!

    Paula, surely it should be

    logger.log("Akismet - Brillant");

  • Swedish tard (unregistered) in reply to safarmer
    safarmer:
    Don't they know one of the E's in Java EE is Enterprise? If they really want this to be enterprisey they need to find a way to put some XML in the log format!

    We have that where I work. It is also the carrier for sending data between the GUI and the server. And config files. And database dump files. (Though, we have two formats, done by two entirely different sets of code, the other one is CSV). And install script configs. And build configurations. And for protocol specifications. And we use it for feature documents as well.

    XML is pretty much everywhere here. Much like how when you are in the desert, you get sand everywhere as well.

    And yeah. Im gonna go interview at another place soon.

  • Marvin the Martian (unregistered) in reply to John
    John:
    ...doing the extra logging somewhere besides the log file, is not a good idea. ...
    I read that as "log fire", and it sounded good & relaxing.
  • Bert Glanstron (unregistered)

    Dear NAGESH,

    In case you can't tell, this is a grown-up place. The fact that you insist on using your ridiculous handle clearly shows that you're too young and too stupid to be using the interNET.

    Go away and grow up.

    Sincerely, Bert Glanstron

  • Commenter (unregistered)

    Attempting to comment

    Commenter:
    Commenting an article

    Commenting

    PS: Yo dawg, I heard you like logging logging, so we logged logging your log messages.

  • grumpy (unregistered)

    A log is a log is a log. Where's the WTF in that?

  • Anonymous (unregistered)

    Attempted to post a sensible comment but it's devolved into an Akismet bash. Everything I try to submit is blocked - even when there are no URLs or links in the message. Quoting other messages seems to trigger it as well, even with no URLs in the quote. I literally cannot post ANYTHING today and the only reason I expect this to work is cruel, cruel irony.

  • (cs) in reply to Anonymous

    Akismet wins by losing. Interesting.

    I'm assuming there is a rejection log for Akismet that can be checked for the rejection reason?

    I was going to descend into an infinite loop of log-log-logging here, but the whole topic is already starting to wear a little thin. If you have a problem with my useless post, I suggest you log a complaint.

  • Anonymous (unregistered) in reply to Anonymous
    Anonymous:
    Attempted to post a sensible comment but it's devolved into an Akismet bash. Everything I try to submit is blocked - even when there are no URLs or links in the message. Quoting other messages seems to trigger it as well, even with no URLs in the quote. I literally cannot post ANYTHING today and the only reason I expect this to work is cruel, cruel irony.
    You have got to be kidding me?! Akismet finally lets me post but only when I replace my sensible comment with an Akismet bash? What the hell is this? Does Akismet get turned on by pissing people off?

    Very annoyed about this. I'm not going to launch into a tirade like some folks but honestly, it's got to the point where Akismet is seriously hurting the site by frustrating users and limiting valid user content. All this in the name of spam reduction which obviously doesn't work because every single day we get a user called "cindy" who hot-links directly to some dodgy knocked-off goods site. The spammers clearly know how to evade Akismet so the honest users suffer for no good reason.

    For the love of God, there are other spam-reduction techniques you can use. For starters, you can get rid of that abysmal home-made captcha and replace it with something that doesn't have the answer encoded in the querystring. Google's Re-Captcha is worth investigating - it takes about 5 mintues to implement and unlike yours it actually works.

  • (cs)

    Could be worse.

    public class Log {
      public void debug(String msg) {
        this.debug("Attempting to log");
        this.stream.println(msg);
        this.debug("Finished logging");
      }
    }
    
  • Mike (unregistered)

    Isn't this the principle that blogging is based on?

  • Anon Too (unregistered)

    If I'm not logging, how am I going to see the forest for the trees?

Leave a comment on “Logging the Logger”

Log In or post as a guest

Replying to comment #:

« Return to Article