X-Original-To: pgsql-jdbc-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 86C2153B28 for ; Mon, 25 Apr 2005 21:01:30 -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 80541-04 for ; Tue, 26 Apr 2005 00:01:25 +0000 (GMT) Received: from mir3-fs.mir3.com (unknown [216.74.11.46]) by svr1.postgresql.org (Postfix) with ESMTP id B4C9153AEB for ; Mon, 25 Apr 2005 21:01:23 -0300 (ADT) Received: from amateljan.mirlogic.com ([172.16.2.68]) by mir3-fs.mir3.com with Microsoft SMTPSVC(5.0.2195.5329); Mon, 25 Apr 2005 17:02:51 -0700 Subject: Re: Problems after upgrading from 7.4.6 driver to 8.0.2 From: Mark Lewis To: pgsql-jdbc@postgresql.org In-Reply-To: <1114472323.923.56.camel@amateljan.mirlogic.com> References: <1114472323.923.56.camel@amateljan.mirlogic.com> Content-Type: text/plain Organization: MIR3, Inc. Message-Id: <1114473637.923.75.camel@amateljan.mirlogic.com> Mime-Version: 1.0 X-Mailer: Ximian Evolution 1.4.4 (1.4.4-3) Date: Mon, 25 Apr 2005 17:00:37 -0700 Content-Transfer-Encoding: 7bit X-OriginalArrivalTime: 26 Apr 2005 00:02:51.0923 (UTC) FILETIME=[4A1D1E30:01C549F3] X-Virus-Scanned: by amavisd-new at hub.org X-Archive-Number: 200504/160 X-Sequence-Number: 12767 Sorry for the noise, just after posting I finally tracked it down to a problem in the application. In one code path a prepared statement was being double-closed, which apparently triggers a bug in the version of DBCP being used. I'm still not sure why it only started misbehaving after upgrading the JDBC driver. -- Mark On Mon, 2005-04-25 at 16:38, Mark Lewis wrote: > After upgrading from pg74.215.jdbc3.jar to postgresql-8.0-310.jdbc3.jar, > I've encountered problems getting a "This statement has been closed" > exception when using a PreparedStatement. > > The application is using Jakarta's DBCP 1 connection pooling with > prepared statement caching, and is configured to execute "select 1" each > time a connection is checked out from the pool to ensure that the > connection is still alive, so I'm pretty sure the server connection is > still good. > > Are there any known gotchas migrating to the new server prepared > statement implementation? Something that could be causing statements to > close when they otherwise would not be? > > Thanks, > Mark Lewis > > Thanks, > Mark Lewis > > > > > > ---------------------------(end of broadcast)--------------------------- > TIP 4: Don't 'kill -9' the postmaster