Beefy Boxes and Bandwidth Generously Provided by pair Networks
Problems? Is your data what you think it is?
 
PerlMonks  

Re^2: Balancing Logging and Code Readability

by ack (Deacon)
on Sep 17, 2009 at 02:34 UTC ( [id://795752]=note: print w/replies, xml ) Need Help??


in reply to Re: Balancing Logging and Code Readability
in thread Balancing Logging and Code Readability

I don't know of any "one size fits all" advice for logging.

I totally agree. In fact, I find that "one size" doesn't even work for my own challenges.

Thanks for the ideas...especially about use constants. I haven't had any reall performance problems with the logging, but I had wondered if there might be a way to handle at least some of the challenge if, in the future, I experienced a performance problem.

As I noted in my Update to my original post, I tend to use logging mostly for its flexibility in capturing script progress and capturing script results.

I, like you, tend to use print statements for my debugging. At the moment I attribute my preference for prints vs. logging to the reality that I'm still new to the logging capabilities that Log4perl offers. I have presumed that with more experience and understanding I would tend to migrate to using logging for debugging, too.

However, I've never had any real problem with using prints for debugging so I haven't really had any strong incentive or desire to migrate away from that strategy. I am, however, experimenting with using logging and have found that it has some interesting and useful contributions to make to my debugging. So, for me, the vote is still out on using logging for debugging.

Thanks so much for your reply. I really appreciate it.

ack Albuquerque, NM

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://795752]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (6)
As of 2024-04-24 05:55 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found