Received: from localhost (maia-4.hub.org [200.46.204.183]) by postgresql.org (Postfix) with ESMTP id 5617A9FB80C for ; Tue, 5 Jun 2007 12:23:05 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.183]) (amavisd-maia, port 10024) with ESMTP id 95528-01-2 for ; Tue, 5 Jun 2007 12:22:56 -0300 (ADT) X-Greylist: from auto-whitelisted by SQLgrey-1.7.4 Received: from ns1.officenet.no (ns1.officenet.no [193.212.174.3]) by postgresql.org (Postfix) with ESMTP id 9705C9FBED1 for ; Tue, 5 Jun 2007 12:22:49 -0300 (ADT) Received: from [85.112.130.182] (helo=krogh-laptop.local) by ns1.officenet.no with esmtpsa (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.62) (envelope-from ) id 1Hvart-0001Wl-Dn for pgsql-jdbc@postgresql.org; Tue, 05 Jun 2007 17:22:48 +0200 From: Andreas Joseph Krogh Organization: OfficeNet AS To: pgsql-jdbc@postgresql.org Subject: Re: Connection Pool Date: Tue, 5 Jun 2007 17:22:50 +0200 User-Agent: KMail/1.9.7 References: <46656EB2.1060408@enterprisedb.com> In-Reply-To: <46656EB2.1060408@enterprisedb.com> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Message-Id: <200706051722.50953.andreak@officenet.no> X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=0.001 tagged_above=0 required=5 tests=BAYES_50=0.001 X-Spam-Level: X-Archive-Number: 200706/14 X-Sequence-Number: 17076 On Tuesday 05 June 2007 16:09:54 Heikki Linnakangas wrote: > Raghavendra MB wrote: > > I am using PostgresSQL 8.2 server. I would like to use JDBC connecton > > pool: My application is pure core java desktop. Is there any readily > > available pool for postgres ? > > There's plenty of generic implementations. For example, Apache commons > DBCP: http://jakarta.apache.org/commons/dbcp/ I recommend C3PO, it's much simpler to set up in a standard application: DataSource pooled =3D null; try { DataSource unpooled =3D=20 DataSources.unpooledDataSource("jdbc:postgresql://localhost:5432/mydb", "username", "password"); pooled =3D DataSources.pooledDataSource( unpooled ); } catch (Exception e) { e.printStackTrace(); } =2D-=20 Andreas Joseph Krogh Senior Software Developer / Manager =2D-----------------------+---------------------------------------------+ OfficeNet AS | The most difficult thing in the world is to | Karenslyst All=E9 11 | know how to do a thing and to watch | PO. Box 529 Sk=F8yen | somebody else doing it wrong, without | 0214 Oslo | comment. | NORWAY | | Tlf: +47 24 15 38 90 | | =46ax: +47 24 15 38 91 | | Mobile: +47 909 56 963 | | =2D-----------------------+---------------------------------------------+