• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • paul wheaton
  • Liutauras Vilda
  • Ron McLeod
Sheriffs:
  • Jeanne Boyarsky
  • Devaka Cooray
  • Paul Clapham
Saloon Keepers:
  • Scott Selikoff
  • Tim Holloway
  • Piet Souris
  • Mikalai Zaikin
  • Frits Walraven
Bartenders:
  • Stephan van Hulst
  • Carey Brown

Those who have recently passed or submitted help!! - No Logging

 
Greenhorn
Posts: 24
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
After reading many of the discussions regarding logging. I was
wondering if anyone has recently passed or submitted by simply printing to
the console (System.out.println(X))? This is a major design issue
I am troubled over becuase my alternative is logging but I don't want
to go there for this project.
thanks,
rt
 
Ranch Hand
Posts: 41
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
What's wrong with logging?
It's really useful.
If you just use System.out.println, your code will be harder to debug, and thus you will be making it harder for yourself.
 
Ranch Hand
Posts: 293
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
My two cents worth is that there are the following two camps:
Camp 1 - use it. Needed for debugging. Why would you not want to use it? Why take it out if you have it working?
Camp 2 - it's great to use it, but not really necessary as per requirements. Everyone seems to agree that it is VERY useful throughout debugging. Make sure if you include it in your submission that you do it right because if problems you will lose points. Also, you probably won't gain points by including it. (Although some have said they may have got their results faster by including fancy logging.)
I would say that if you choose to use logging, just make sure that it won't fail under any condition in your graders environment. (can't depend on the jre/lib logging properties file being there)
I would say that if you choose to not use logging, just make sure you do enough crude logging in your debug testing to ensure that your stuff is working. Also document in your choices that you considered using it and decided not to for the following reasons...... From what my spec said, it sounds like as long as you document your design decisions, they don't break any required functionality, and you are consistent in your coding with your decision, you won't lose points. (Sometimes this sounds better to me than the potential of losing points if I screw some little thing up.)
Good luck making your decision!
TJ
 
Ranch Hand
Posts: 2937
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
After reading many of the discussions regarding logging. I was
wondering if anyone has recently passed or submitted by simply printing to
the console (System.out.println(X))?

I would be very surprised if anyone failed because he/she didn't do a fancy logging. System.out.println() will do just fine, don't worry about it. This logging stuff is just a recent fashion here at SCJD, so I would say concentrate on your design, not on the ornamentations.
 
Raymond Tanner
Greenhorn
Posts: 24
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
"What's wrong with logging?
It's really useful."

I have used logging extensively in other work. Thats not the problem.
I just want to keep things simple as possible for this project and would like to know if anyone has recently passed using simply the console.
 
Ranch Hand
Posts: 619
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,
Logging is absolutely not required for the assignment.
You must understand how your solution works and test it to see that it works the way you think it should. Logging is an incredibly valuable tool to help you do this. It is not very difficult to setup. Several people have posted their experiences setting up logging, so if you do a search in the forum you can access their advice. If you experience difficulties with getting the logging.properties file to work, you can even hard code the logging setup in your application. I much prefer it to System.out.println.
Hope this helps,
George
 
Ranch Hand
Posts: 451
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Eugene is quite correct.
It's really up to you to decide whether to use the logging API or System.out.println, since both can get the job done in an acceptable way.
You might want to ask yourself if it's something you think you will be useful to you in your ongoing work. Even if it is, you may decide not to use it simply because you don't have time at present to learn the API.
I asked myself the same question when deciding to use NIO or simply a RandomAccessFile. I chose not to use NIO for the assignment because I didn't see a pressing need to know it for my other work or the assignment.
With regards to the logging API, my decision was to use it because I anticipated being able to use the knowledge gained right away for my other work. Because of this, I considered logging to be a bit more than an ornamentation for me. I found this journey to be rewarding.
[ January 20, 2004: Message edited by: Ken Krebs ]
 
Politics n. Poly "many" + ticks "blood sucking insects". Tiny ad:
Gift giving made easy with the permaculture playing cards
https://coderanch.com/t/777758/Gift-giving-easy-permaculture-playing
reply
    Bookmark Topic Watch Topic
  • New Topic