When the Session ends in PGSQL?

From: Durumdara <durumdara(at)gmail(dot)com>
To: pgsql-general(at)postgresql(dot)org
Subject: When the Session ends in PGSQL?
Date: 2011-06-30 14:11:32
Message-ID: BANLkTi=FKnk9_Vc7pVNd33Dv-vtpooUqjA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Hi!

I asked same thing in the list formerly,
http://archives.postgresql.org/pgsql-general/2011-06/msg00888.php

And because of lack of answers now I asked here also:
http://stackoverflow.com/questions/6534654/postgresql-session-timeout

I'm very wondering that I don't (and can't) found a system variable
that define the timeout of the client session. Maybe I'm a real lama,
or search with wrong terms... :-)

The manual often refers to "Session end" - when the resources
released, but never I saw a section that describe when it happens.

The RDBMS-s needs some rule to mark a Session inactive or/and dead.

Commonly they are uses a "Timeout" parameter that control how many
minutes has ellapsed to session marked as Dead.

FireBird and ElevateDB do this too. If the client is do anything, this
time period extends again.

The cleanup is needed for remove the locks, unfinished (limbo or
started) transactions, and decrease the deadlock, or lock situations;
and to never reach the maximum connections.

So: is anybody here that can tell me how this working in PGSQL?

And if there is no control, when the Session ends?

Practical example (real):
A client program died on a transaction, and it leaves many locks in
the DataBase.

If Session Timeout is 5 minutes, then we can tell the other users who
got "Row lock", or "Transaction Timeout" errors to wait 6-7 minutes
and then trying again, because after 5 minutes the problematic session
is cleaned up, and locks/transactions removed from the objects.

Thanks for your help:
dd

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Miroslav Šulc 2011-06-30 14:18:14 VACUUM FULL cannot be VERBOSE?
Previous Message Grace Batumbya 2011-06-30 13:52:59 Re: Windows x64 : How do I get OSSP-UUID.sql contrib for postgresql x64