X-Original-To: pgsql-jdbc-postgresql.org@localhost.postgresql.org Received: from localhost (av.hub.org [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id D151F52802 for ; Fri, 19 Aug 2005 14:08:46 -0300 (ADT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 14926-04 for ; Fri, 19 Aug 2005 17:08:44 +0000 (GMT) Received: from mail63.csoft.net (leary3.csoft.net [63.111.22.74]) by svr1.postgresql.org (Postfix) with SMTP id 8A1CA52BCA for ; Fri, 19 Aug 2005 14:08:42 -0300 (ADT) Received: (qmail 17564 invoked by uid 1112); 19 Aug 2005 17:08:42 -0000 Date: Fri, 19 Aug 2005 12:08:42 -0500 (EST) From: Kris Jurka X-X-Sender: books@leary.csoft.net To: Kevin Grittner Cc: tgl@sss.pgh.pa.us, oliver@opencloud.com, pgsql-jdbc@postgresql.org Subject: Re: java.sql.SQLException: ERROR: canceling query due In-Reply-To: Message-ID: References: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.008 required=5 tests=[AWL=0.008] X-Spam-Level: X-Archive-Number: 200508/141 X-Sequence-Number: 13710 On Fri, 19 Aug 2005, Kevin Grittner wrote: > I'm curious whether "SET statement_timeout=n" sets this for a > connection. If so, wouldn't it be a good thing to update the JDBC > setQueryTimeout and getQueryTimeout methods to use these SET and SHOW > statements? > Yes, it sets it per connection, but the problem is that the JDBC level needs it per Statement. So we'd have to set/reset it for each command. I was originally concerned about thread safety and transactions, but thinking about it some more now the monitor around QueryExecutorImpl should protect against that. Maybe this is easier than I thought. Kris Jurka