db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Daniel John Debrunner <...@debrunners.com>
Subject Re: DERBY-31: setQueryTimeout semantics
Date Fri, 22 Apr 2005 14:07:26 GMT
Oyvind.Bakksjo@Sun.COM wrote:

> In principle, there is no requirement that execute produces any result
> at all, so all work could be done while invoking ResultSet.next(). In
> this case, it makes sense to have the querytimeout affect not only
> Statement.execute(), but the fetching phase as well. It might also be a
> more orthogonal approach implementation-wise.
> 
> We're then left with three choices:
> 1) setQueryTimeout() only affects Statement.execute()
> 2) setQueryTimeout() affects Statement.execute() and ResultSet.next(),
> starting from zero for each invocation
> 3) setQueryTimeout() affects Statement.execute() and ResultSet.next(),
> accumulating time spent in each invocation
> 
> I think option 3 is the most sensible one, but I'm open to other
> opinions. Also, it would be interesting to consider what other vendors
> do. Does anybody know?

I'd assumed from the wording of the setQueryTimeout that it was option 2
, more of response time issue than resource usage issue. But it would be
good to see what the other driver vendors do.

Dan.


Mime
View raw message