tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Looijmans, Mike" <>
Subject RE: Tomcat Crashes out of continuous servicing of stuck request
Date Fri, 04 Dec 2009 10:41:03 GMT
> Without trying to send something back to the client, there is 
> no way telling the client closed the window (or pressed 
> reload or switched to another URL).

I would expect the socket to be closed, which can be detected at the
server side. The exceptions I can think of are the client crashing or a
network disconnect.

Though apache probably detects the socket's close, it has little means
of informing the associated servlet because that is blocked waiting for
the response from the database.
Depending on the database, it is usually also no use to try and stop -
the query will continue its work even though the requesting user is gone
on most DBMSes. So taking a slot in the webserver is not a big issue,
the DB is wasting far more resources on that user.

Other options to explore are dividing the big query into multiple
smaller ones, so that you can abort sooner. Use "INTO TEMP" to store
intermediates. That would give you the opportiunity to check whether the
client is still listening - and you could even give the client some
updates on progress, which may be considered a nice to have feature as

Best of all would be to optimize the database and make those queries
faster, but I guess you must have valid reasons for not doing so.


-- My reply ends here --

This message and attachment(s) are intended solely for use by the addressee and may contain
information that is privileged, confidential or otherwise exempt from disclosure under applicable

If you are not the intended recipient or agent thereof responsible for delivering this message
to the intended recipient, you are hereby notified that any dissemination, distribution or
copying of this communication is strictly prohibited.

If you have received this communication in error, please notify the sender immediately by
telephone and with a 'reply' message.

Thank you for your co-operation.

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message