I’ve inherited a front end written by a third-party. That front end interacts with Oracle through procedures written by a different third-party. The stored procedure in question requires 2 minutes and 36 seconds to return search results when it is manually executed. I can’t see the procedure and that team has suggested that I increase the timeout in the Web application (hosted on a shared server).
In my world, anything over 30 seconds would require a performance fix before being deployed to production with a few exceptions (legacy code, crazy reports, etc.). The option that was suggested to me was to increase the timeout from 30 seconds (explicitly added by the front end developer) to 180 seconds.
My question to you:
What are the risks with taking the easy approach and increasing the timeout? If possible, please provide links to articles that support your views so I can reference them.
Also feel free to chime in if you believe this is a non-issue.
The issue with increasing timeouts globally is that you could run into several issues down the road:
When you increase timeouts what you are telling the server is that it needs to keep the thread that it is using to service that request running. The server will have a limited number of threads, so a thread that it keeps running for extended periods of time is a thread that is not available to service other requests. If you have a lot of requests that take a long time to run, then eventually you run out of threads and the server becomes unresponsive.
Whether this matters at all for you will depend on how many requests are made to that particular stored procedure. If there is only one request made every so often, then it’s not a big deal. However, the problem with setting the timeout globally is that it now applies to ALL requests, so if there are other requests that might take a long time to run, you will be extending their duration as well.