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

From: Tatsuo Ishii <ishii(at)sraoss(dot)co(dot)jp>
To: ideriha(dot)takeshi(at)jp(dot)fujitsu(dot)com
Cc: pgsql-hackers(at)lists(dot)postgresql(dot)org
Subject: Re: idle-in-transaction timeout error does not give a hint
Date: 2018-11-29 00:16:01
Message-ID: 20181129.091601.830026250066724330.t-ishii@sraoss.co.jp
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

>>> 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.
>>
>>Alternative HINT message would be something like:
>>
>>HINT: In a moment you should be able to reconnect to the
>> database and restart your transaction.
>>
>>This could make the meaning of the error (transaction aborted) cleaner and might give
>>a better suggestion to the user.
>
> Agreed. Changing "command" to "transaction" seems more accurate. People might think
> only the command they hit is not sent but transaction is still alive though it's of course unnatural
> that transaction is alive after connection is terminated.
>
> In this case you could change the comment issued by other errors mentioned while you're at it.
>
> Regards,
> Takeshi Ideriha

I have added this to the next CF (2019-01).

Best regards,
--
Tatsuo Ishii
SRA OSS, Inc. Japan
English: http://www.sraoss.co.jp/index_en.php
Japanese:http://www.sraoss.co.jp

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Michael Paquier 2018-11-29 00:16:02 Re: A WalSnd issue related to state WALSNDSTATE_STOPPING
Previous Message Tomas Vondra 2018-11-28 23:17:31 Re: COPY FROM WHEN condition