Wednesday, October 29, 2008

Apache ......> 2 mins ...... JBoss = Timeout

The thing is when the report is prepared it might took around 2-3 minutes, and the user after 2 minutes saw a blank page on their browser, no explanation, no clue, nothing.

We have Apache web server works as a proxy to JBoss and we use mod_proxy here (why not proxy_ajp/mod_jk? because we want to simulate our client's config --> they won't allow us to add additional module to their server).

Looking at the log, found the exception :
ClientAbortException: Broken pipe

The first idea came to my mind is it must be the browser that send the timeout signal to the server, opening about:config on the browser (Do you know the browser I'm using?) only to find that the timeout configuration is 300 (5 mins). It seems that it's not the browser to blame on the timeout.

The second idea, it's broken pipe... is it possible that apache buffer is not large enough? Then other idea come up, is it possible that Apache is the one to "blame" for causing the timeout?
Yep, indeed, the default timeout configuration (/etc/httpd/httpd.conf) is 120secs.

# Timeout: The number of seconds before receives and sends time out.
Timeout 120

Changing it to 300 (5 mins) should be enough to allow the report to be prepared fully.

One problem solved, one lesson learned and one happy customer we got.

No comments: