X-Original-To: pgsql-jdbc-postgresql.org@postgresql.org Received: from localhost (mx1.hub.org [200.46.208.251]) by postgresql.org (Postfix) with ESMTP id 195729FA4D1 for ; Sat, 16 Sep 2006 06:00:19 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.208.251]) (amavisd-new, port 10024) with ESMTP id 44823-05 for ; Sat, 16 Sep 2006 06:00:07 -0300 (ADT) X-Greylist: delayed 00:33:03.245889 by SQLgrey- Received: from mail.tacotec.de (mail.tacotec.de [83.137.101.41]) by postgresql.org (Postfix) with ESMTP id C78E49FA395 for ; Sat, 16 Sep 2006 06:00:06 -0300 (ADT) Received: from localhost (localhost [127.0.0.1]) by mail.tacotec.de (Postfix) with ESMTP id E7AC811D572; Sat, 16 Sep 2006 10:26:50 +0200 (CEST) Received: from mail.tacotec.de ([83.137.101.41]) by localhost (hera.tacotec.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 10172-02; Sat, 16 Sep 2006 10:26:50 +0200 (CEST) Received: from lunix.schabi.de (p549D3E8F.dip0.t-ipconnect.de [84.157.62.143]) by mail.tacotec.de (Postfix) with ESMTP id BA3F111D519; Sat, 16 Sep 2006 10:26:50 +0200 (CEST) Received: from [127.0.0.1] (localhost [127.0.0.1]) by lunix.schabi.de (Postfix) with ESMTP id DC8DB78A3F; Sat, 16 Sep 2006 10:26:48 +0200 (CEST) Message-ID: <450BB548.2070506@logix-tt.com> Date: Sat, 16 Sep 2006 10:26:48 +0200 From: Markus Schaber Reply-To: "pgsql-jdbc@postgresql.org" User-Agent: Thunderbird 1.5.0.5 (X11/20060812) MIME-Version: 1.0 To: Sriram Dandapani Cc: pgsql-jdbc@postgresql.org Subject: Re: idle in transaction References: <6992E470F12A444BB787B5C937B9D4DF05DF1974@ca-mail1.cis.local> In-Reply-To: <6992E470F12A444BB787B5C937B9D4DF05DF1974@ca-mail1.cis.local> X-Enigmail-Version: 0.94.0.0 Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: quoted-printable X-Virus-Scanned: by amavisd-new at mail.tacotec.de X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=0.171 tagged_above=0 required=5 tests=AWL, FORGED_RCVD_HELO, SPF_HELO_PASS X-Spam-Level: X-Archive-Number: 200609/61 X-Sequence-Number: 15779 Hi, Sriram, Sriram Dandapani wrote: > I use postgres 8.1.2 database and postgres 8.1.404 jdbc driver . >=20 > I keep seeing =93idle in transaction=94 connections on the postgres box= all > the time. The application logic closes all connections, so it makes me > wonder if the driver is issuing a begin statement after every commit to= > leave a floating transaction open. Current driver versions (and 8.1.404 is current enough) should not show this behaviour any more, which was annoying in older drivers. Are you shure that you have the correct driver version? We occasionally get reports from users thinking they run a certain driver version, but they accidentally have another driver earlier in the class search path. Especially the $JRE/lib/ext directory is dangerous, people tend to drop =2Ejars there and then forget them. Another possibility is that you use a broken connection pooling that fails to reset the connections properly. Could you modify your application logic to set all connections to autocommit mode before closing / returning them to the pool? HTH, Markus