We worked recently on the Request Timeout functionality in Lucee to counter changes in Java 8 that affected the existing functionality.
Remaining problem is that every request timeout can leave the server in a instable state, because it can kill a thread in a monitor, lock, writing a file … .
So in any case a request timeout should be avoided at any cost.
This raises the question, can we improve the current implementation to avoid request timeouts?
Raise awarness of Request Timeouts happening
Show in admin or the debug output how many request timeouts you had since startup.
maybe with a little bit more info (compressed).
Make request timeout smarter
Instead of simply stop a thread after a certain time Lucee should analyze the thread instead.
Answer the following question:
- is the thread blocked (waiting for example on a network stream) or still running
- log information about long running requests and compare current requests with requests from history
Instead of only supporting forcing a stop, Lucee should have a more graceful stopping mechanism to choose.
Log more useful information
for example log a category of the request timeout (network,code,waiting,…)
Any other idea how to improve?