RE: idle-in-transaction timeout error does not give a hint

From: "Ideriha, Takeshi" <ideriha(dot)takeshi(at)jp(dot)fujitsu(dot)com>
To: 'Tatsuo Ishii' <ishii(at)sraoss(dot)co(dot)jp>, "pgsql-hackers(at)lists(dot)postgresql(dot)org" <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: RE: idle-in-transaction timeout error does not give a hint
Date: 2018-11-28 07:12:51
Message-ID: 4E72940DA2BF16479384A86D54D0988A6F3BDA64@G01JPEXMBKW04
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

>From: Tatsuo Ishii [mailto:ishii(at)sraoss(dot)co(dot)jp]
>Sent: Wednesday, November 28, 2018 12:18 PM
>To: pgsql-hackers(at)lists(dot)postgresql(dot)org
>Subject: idle-in-transaction timeout error does not give a hint
>
>idle-in-transaction timeout error closed the session. I think in this case the error
>message should give a hint something like other errors (for example
>ERRCODE_CRASH_SHUTDOWN or
>ERRCODE_T_R_SERIALIZATION_FAILURE) to ask users to reconnect.
>Attached patch does that.

Hi, it makes sense to me. One can submit transaction again same as other cases
you mentioned.

I didn't attach the patch but according to my simple experiment
in psql the output would become the following:

FATAL: terminating connection due to idle-in-transaction timeout
HINT: In a moment you should be able to reconnect to the
database and repeat your command.
server closed the connection unexpectedly
This probably means the server terminated abnormally
before or while processing the request.
The connection to the server was lost. Attempting reset: Succeeded.

Regards,
Takeshi Ideriha

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Amit Kapila 2018-11-28 07:47:58 Re: New function pg_stat_statements_reset_query() to reset statistics of a specific query
Previous Message Erik Rijkers 2018-11-28 07:09:10 psql --csv and other parameters