Re: Connection Idle in transaction

From: Gaetano Mendola <mendola(at)bigfoot(dot)com>
To: pgsql-jdbc(at)postgresql(dot)org
Cc: David Wall <d(dot)wall(at)computer(dot)org>
Subject: Re: Connection Idle in transaction
Date: 2004-04-09 00:29:44
Message-ID: 4075EE78.6030704@bigfoot.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-jdbc

Gaetano Mendola wrote:

> David Wall wrote:
>
>>> I'm facing a problem with the unfamous:
>>>
>>> "idle in transaction"
>>
>>
>>
>> Why is this "infamous"? Does it cause problems somewhere? I
>> understand it
>> may "look unusual" to you, but there's really no issue in that each
>> connection that doesn't use autocommit is always in a transaction, so
>> that
>> any statements you issue are done under that transaction until you
>> commit/rollback, at which time a new transaction is initiated in
>> preparation
>> for further statements being issued.
>>
>> Is there some issue that Postgresql has problems because such
>> transactions
>> are held open for a long time? I've never seen any such problem in the
>> years using PG. After all, maintaining the open connection is the
>> expensive
>> operation, and I think the open transaction is a nit (but I certainly
>> can be
>> wrong!).
>
>
> Yes a "idle in transaction" connection for example block each vacuum
> full, just not to mention all the rows kidnapped by that transaction.

Not block sorry, but the vacuum is not able to free all the row updated
by other connections.

try to connect to your DB, do a "begin" and leave that transaction
sitting there for days...

Regards
Gaetano Mendola.

In response to

Responses

Browse pgsql-jdbc by date

  From Date Subject
Next Message David Wall 2004-04-09 01:28:06 Re: Connection Idle in transaction
Previous Message Gaetano Mendola 2004-04-09 00:20:58 Re: Connection Idle in transaction