Received: from localhost (unknown [200.46.204.184]) by postgresql.org (Postfix) with ESMTP id 199959FC826 for ; Tue, 23 Oct 2007 15:21:11 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.184]) (amavisd-maia, port 10024) with ESMTP id 17240-07-3 for ; Tue, 23 Oct 2007 15:20:52 -0300 (ADT) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.5 Received: from mail01.enterprisedb.com (mail01.enterprisedb.com [63.246.7.168]) by postgresql.org (Postfix) with ESMTP id 6B74F9FC79F for ; Tue, 23 Oct 2007 15:16:04 -0300 (ADT) thread-index: AcgVoNEM4Jwrn7gVQeW2bfmMj88FKw== Received: from [192.168.1.33] ([86.0.85.188]) by mail01.enterprisedb.com over TLS secured channel with Microsoft SMTPSVC(6.0.3790.3959); Tue, 23 Oct 2007 14:16:21 -0400 Message-ID: <471E39E1.7080907@enterprisedb.com> Content-Class: urn:content-classes:message Importance: normal X-MimeOLE: Produced By Microsoft MimeOLE V6.00.3790.4133 Date: Tue, 23 Oct 2007 19:13:53 +0100 From: "Heikki Linnakangas" User-Agent: Icedove 1.5.0.12 (X11/20070730) MIME-Version: 1.0 To: "Matthew Storer" Cc: Subject: Re: "Something unusual has occured" error using PostgreSQL 8.2 with Apache Commons DBCP 1.2.2 References: <1193159536.9909.1217408695@webmail.messagingengine.com> In-Reply-To: <1193159536.9909.1217408695@webmail.messagingengine.com> Content-Type: text/plain; charset="ISO-8859-1" Content-Transfer-Encoding: 7bit X-OriginalArrivalTime: 23 Oct 2007 18:16:21.0812 (UTC) FILETIME=[D0902F40:01C815A0] X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200710/124 X-Sequence-Number: 17696 Matthew Storer wrote: > To start, I'm putting together a Java client-server app, where the > server side talks to a PostgreSQL database via an Apache Commons DBCP > link for connection pooling. Using the code I've included below, I'm > able to establish a connection, get database metadata, and execute > stored functions perfectly well PROVIDING I DON'T try to call > getConnection() again without closing the first connection beforehand. > (but it seems to me that doing that ought to work alright, because if I > call getConnection() a second time, shouldn't the DBCP code just pull a > new connection from the pool, and not, instead, throw this exception?) Can you reduce it to a self-contained test case? That way others can test and help with it as well. > EXCEPTION: > ---------- > org.postgresql.util.PSQLException: Something unusual has occured to > cause the driver to fail. Please report this exception. > at org.postgresql.Driver.connect(Driver.java:276) > at java.sql.DriverManager.getConnection(Unknown Source) > at java.sql.DriverManager.getConnection(Unknown Source) > at > org.apache.commons.dbcp.DriverManagerConnectionFactory.createConnection(DriverManagerConnectionFactory.java:68) > at > org.apache.commons.dbcp.PoolableConnectionFactory.makeObject(PoolableConnectionFactory.java:294) > at > org.apache.commons.pool.impl.GenericObjectPool.borrowObject(GenericObjectPool.java:840) > at > org.apache.commons.dbcp.PoolingDriver.connect(PoolingDriver.java:176) > > at java.sql.DriverManager.getConnection(Unknown Source) > at java.sql.DriverManager.getConnection(Unknown Source) > at > myproject.db.ConnectionPool.getConnection(ConnectionPool.java:136) Is that the whole stack trace? The stack trace of the underlying exception should be there as well. -- Heikki Linnakangas EnterpriseDB http://www.enterprisedb.com