Re: Idle In Transaction Session Timeout, revived - Mailing list pgsql-hackers

From Jim Nasby
Subject Re: Idle In Transaction Session Timeout, revived
Date
Msg-id 56B280E2.2090203@BlueTreble.com
Whole thread Raw
In response to Re: Idle In Transaction Session Timeout, revived  (David Steele <david@pgmasters.net>)
Responses Re: Idle In Transaction Session Timeout, revived
Re: Idle In Transaction Session Timeout, revived
List pgsql-hackers
On 2/3/16 4:05 PM, David Steele wrote:
> On 2/3/16 4:25 PM, Tom Lane wrote:
>> Robert Haas <robertmhaas@gmail.com> writes:
>>> On Wed, Feb 3, 2016 at 3:41 PM, Jim Nasby <Jim.Nasby@bluetreble.com> wrote:
>>>> Wouldn't it be more sensible to just roll the transaction back and not
>>>> disconnect?
>>
>> I'm not sure how messy this would be in practice.  But if we think that
>> killing the whole session is not desirable but something we're doing for
>> expediency, then it would be worth looking into that approach.
>
> I think killing the session is a perfectly sensible thing to do in this
> case.  Everything meaningful that was done in the session will be rolled
> back - no need to waste resources keeping the connection open.

Except you end up losing stuff like every GUC you've set, existing temp 
tables, etc. For an application that presumably doesn't matter, but for 
a user connection it would be a PITA.

I wouldn't put a bunch of effort into it though. Dropping the connection 
is certainly better than nothing.
-- 
Jim Nasby, Data Architect, Blue Treble Consulting, Austin TX
Experts in Analytics, Data Architecture and PostgreSQL
Data in Trouble? Get it in Treble! http://BlueTreble.com



pgsql-hackers by date:

Previous
From: David Steele
Date:
Subject: Re: Idle In Transaction Session Timeout, revived
Next
From: Vik Fearing
Date:
Subject: Re: Idle In Transaction Session Timeout, revived