aspose file tools*
The moose likes Developer Certification (SCJD/OCMJD) and the fly likes logging status messages into a file Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Soft Skills this week in the Jobs Discussion forum!
JavaRanch » Java Forums » Certification » Developer Certification (SCJD/OCMJD)
Bookmark "logging status messages into a file" Watch "logging status messages into a file" New topic
Author

logging status messages into a file

Rasika Chitnis
Ranch Hand

Joined: Jun 19, 2001
Posts: 131
Is anybody logging debug messages or exceptions to a log file ? I know it is not a requirement, but I had lot of System.out's in debug phase and I feel some of them should be retained even in the final version, e.g. when I run the server I would have liked to see a message on the console confirmimg that the object is successfully bound in the rmiregistry.
Rasika Chitnis
Ranch Hand

Joined: Jun 19, 2001
Posts: 131
Is retaining System.out's in the code, a total NO-NO for this project ?? I find that in some places, it makes absolute sense to print status to console, like unlock method could not unlock the record, as a quick way to tell that something went wrong.
Mark Spritzler
ranger
Sheriff

Joined: Feb 05, 2001
Posts: 17260
    
    6

You don't want System.outs in your code for submission. Usually your exceptions should be chained up to you GUI, where you can display a nice message saying things like "Unable to Unlock Record, you don't have the Lock" or something like that.
Personnally if I am running the app, which I am submitting, I don't want to see the console pop some message on the screen, as that scares me, usually It means to me an excepetion has occured.
But System.outs are very important for debugging.
Mark


Perfect World Programming, LLC - Two Laptop Bag - Tube Organizer
How to Ask Questions the Smart Way FAQ
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: logging status messages into a file