Beefy Boxes and Bandwidth Generously Provided by pair Networks
Welcome to the Monastery
 
PerlMonks  

comment on

( [id://3333]=superdoc: print w/replies, xml ) Need Help??
I have used Log::Log4perl is production with Apache and mod_perl2, although not in very high traffic applications. So what are the performance impacts of (log4perl) logging in a high traffic web application? The answer is, as always, it depends.

Running in DEBUG mode (full detail) can seriously slow down performance, so you should be careful when setting up your loggers, appenders and levels. Also, very verbose logging can make the logs hard to read, and you can keep less history than if you were less verbose.

Benchmarking your application with different log4perl settings is important to understand how it affects you in your environment. Perhaps you should experiment with different disk setups, such as having /var/log/ on a separate disk system? Your I/O performance will most likely be one of the most important factors.

Do also keep an eye on the is_level functions in order to minimize impact of suppressed messages:

if($logger->is_error()) { $logger->error("Erroneous array: @super_long_array"); }
--
No matter how great and destructive your problems may seem now, remember, you've probably only seen the tip of them. [1]

In reply to Re: Apache and log4perl (high performance logging?) by andreas1234567
in thread Apache and log4perl (high performance logging?) by zerohero

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post; it's "PerlMonks-approved HTML":



  • Are you posting in the right place? Check out Where do I post X? to know for sure.
  • Posts may use any of the Perl Monks Approved HTML tags. Currently these include the following:
    <code> <a> <b> <big> <blockquote> <br /> <dd> <dl> <dt> <em> <font> <h1> <h2> <h3> <h4> <h5> <h6> <hr /> <i> <li> <nbsp> <ol> <p> <small> <strike> <strong> <sub> <sup> <table> <td> <th> <tr> <tt> <u> <ul>
  • Snippets of code should be wrapped in <code> tags not <pre> tags. In fact, <pre> tags should generally be avoided. If they must be used, extreme care should be taken to ensure that their contents do not have long lines (<70 chars), in order to prevent horizontal scrolling (and possible janitor intervention).
  • Want more info? How to link or How to display code and escape characters are good places to start.
Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others sharing their wisdom with the Monastery: (5)
As of 2024-04-23 06:17 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found