This one will be short, because there simply isn’t that much to say. Your home page is one of the most important pages on your site in terms of the visitor’s experience. If your site requires registration, authentication or identification, nearly all users must go through this page. It is the proverbial front door to your site and application.
On a recent load test, the test had to be aborted after 9 minutes, while they were only at 25% of the planned total load level of 385,000 sessions per hour. They were using a LAMJ architecture, and each home page hit generated a long running SQL query. Even very patient users, who are tolerant to slowdowns and errors, will not stick around if the home page takes several minutes. However, this site didn’t even do that! After 2 minutes into the test, the pages simply said
” Whoops! The social network is currently down for maintenance. Please be patient, we’re working on it! “
As you may imagine, their home page is now very fast–0.07 seconds in fact. That is a very fast error message that every user is seeing on the home page, and it would deliver the same for every other page too if the user actually made it that far. I don’t think I need to mention the usefulness of all users seeing that error message.
What caused this slowdown and crash you may ask? I’m glad you did. The long running queries exhausted the JDBC connection pool and maxed out the available number of connections, which is what caused the immediate error page.
The only good thing I can say is at least they didn’t just print stack traces with DSN information contained in them. I’ve been shocked at the content of some of the stack traces I’ve seen on production sites when they encounter an error, but that’s another post.