From: Aldrich, T. <tim...@cs...> - 2004-09-14 15:21:20
|
All, I have a large perl project that uses Log::log4perl to log everything to a text file. If the program successfully completes then this log file is deleted before the program terminates. It is invaluable to be able to crank up the category to DEBUG and watch the file grow :) Now I would like to add logging to a different file that get's appended to during the day. This new rolling log needs different information. It should be general status messages . i.e. program started , ended , by whom. My question is , what is the best way to implement this additional log ? I could : * Pollute my program with print statements (shudder) * Add a new Log::log4perl category. * add a Log::log4perl filter I'm leaning towards categories because $logger->status("I started"); seems to be an easy fix , however the POD discourages the use of a new category. Implementing a filter means I now have to include some type of destination info in my log messages , and I don't want to revisit all of my calls to the logger to add destination info ! Any help / insight / advice would be greatly appreciated R/S____________ Timothy Aldrich -- ============================================================================== This message is for the sole use of the intended recipient. If you received this message in error please delete it and notify us. If this message was misdirected, CSFB does not waive any confidentiality or privilege. CSFB retains and monitors electronic communications sent through its network. Instructions transmitted over this system are not binding on CSFB until they are confirmed by us. Message transmission is not guaranteed to be secure. ============================================================================== |