db-jdo-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Joerg von Frantzius <joerg.von.frantz...@artnology.com>
Subject Update timeout?
Date Mon, 16 Nov 2009 17:27:30 GMT
Hi,

the other day we had the problem that a row lock got held indefinitely
in a production database, probably because of the appserver not properly
committing a connection. As a consequence, the HTTP-threads of the
appserver got blocked one after the other, during execution of an UPDATE
statement. This eventually lead to the whole appserver cluster to hang,
when all HTTP thread pools were filled with blocked threads.

The consequences of a single hanging row-lock could be much less drastic
if something like an update timeout existed. I was hoping that
http://java.sun.com/j2se/1.4.2/docs/api/java/sql/Statement.html#setQueryTimeout(int)
applies to both SELECT and UPDATE statements, so that threads blocked in
a UPDATE statement wouldn't do so forever.

What do you think of having an additional javax.jdo.option.UpdateTimeout
PMF property for this?

Currently there is no way for an application to access any
java.sql.Statement object used by the JDO implementation to invoke
setQueryTimeout() by itself, so in order to have update timeouts with
JDO, some extension of the spec would be necessary?

Regards,
Jörg

-- 
____________________________________________________________________
artnology GmbH - Milastraße 4 - 10437 Berlin - Germany
Geschäftsführer: Ekkehard Blome (CEO), Felix Kuschnick (CCO)
Registergericht: Amtsgericht Berlin Charlottenburg HRB 76376 
UST-Id. DE 217652550


Mime
  • Unnamed multipart/mixed (inline, None, 0 bytes)
View raw message