pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: Further second thoughts about idle_session_timeout patch.
Date: Thu, 07 Jan 2021 16:45:47 +0000
Message-ID: <E1kxYPz-0002Oj-0o@gemulon.postgresql.org> (raw)

Further second thoughts about idle_session_timeout patch.

On reflection, the order of operations in PostgresMain() is wrong.
These timeouts ought to be shut down before, not after, we do the
post-command-read CHECK_FOR_INTERRUPTS, to guarantee that any
timeout error will be detected there rather than at some ill-defined
later point (possibly after having wasted a lot of work).

This is really an error in the original idle_in_transaction_timeout
patch, so back-patch to 9.6 where that was introduced.

Branch
------
REL9_6_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/388ec04f14366d5df0c9b7958c5d9c09d4327f3a

Modified Files
--------------
src/backend/tcop/postgres.c | 22 ++++++++++++----------
1 file changed, 12 insertions(+), 10 deletions(-)



view thread (6+ messages)  latest in thread

Message-ID: <E1kxYPz-0002Oj-0o@gemulon.postgresql.org>
Permalink:  ../E1kxYPz-0002Oj-0o@gemulon.postgresql.org/
Also on:    postgresql.org/message-id/E1kxYPz-0002Oj-0o@gemulon.postgresql.org

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-committers@postgresql.org
  Cc: tgl@sss.pgh.pa.us
  Subject: Re: pgsql: Further second thoughts about idle_session_timeout patch.
  In-Reply-To: <E1kxYPz-0002Oj-0o@gemulon.postgresql.org>
  References: <E1kxYPz-0002Oj-0o@gemulon.postgresql.org>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox