Re: Transaction timeout
Junwang Zhao <zhjwpku@gmail.com>
From: Junwang Zhao <zhjwpku@gmail.com>
To: Japin Li <japinli@hotmail.com>
Cc: "Andrey M. Borodin" <x4mmm@yandex-team.ru>, 邱宇航 <iamqyh@gmail.com>, Fujii Masao <masao.fujii@oss.nttdata.com>, Andrey Borodin <amborodin86@gmail.com>, Andres Freund <andres@anarazel.de>, Michael Paquier <michael.paquier@gmail.com>, Nikolay Samokhvalov <samokhvalov@gmail.com>, pgsql-hackers <pgsql-hackers@postgresql.org>, pgsql-hackers@lists.postgresql.org
Date: 2023-12-22T15:30:56Z
Lists: pgsql-hackers
Attachments
- v15-0001-Introduce-transaction_timeout.patch (application/octet-stream) patch v15-0001
- v15-0002-set-transaction_timeout-before-next-command.patch (application/octet-stream) patch v15-0002
On Fri, Dec 22, 2023 at 10:44 PM Japin Li <japinli@hotmail.com> wrote: > > > On Fri, 22 Dec 2023 at 22:37, Junwang Zhao <zhjwpku@gmail.com> wrote: > > On Fri, Dec 22, 2023 at 10:25 PM Japin Li <japinli@hotmail.com> wrote: > >> I try to set idle_in_transaction_session_timeout after begin transaction, > >> it changes immediately, so I think transaction_timeout should also be take > >> immediately. > > > > Ah, right, idle_in_transaction_session_timeout is set after the set > > command finishes and before the backend send *ready for query* > > to the client, so the value of the GUC is already set before > > next command. > > > > I mean, is it possible to set transaction_timeout before next comand? > Yeah, it's possible, set transaction_timeout in the when it first goes into *idle in transaction* mode, see the attached files. > > -- > Regrads, > Japin Li > ChengDu WenWu Information Technology Co., Ltd. -- Regards Junwang Zhao
Commits
-
Add TAP tests for timeouts
- eeefd4280f6e 17.0 landed
-
Remove flaky isolation tests for timeouts
- a661bf7b0f56 17.0 landed
-
Followup fixes for transaction_timeout
- bf82f43790a6 17.0 landed
-
Introduce transaction_timeout
- 51efe38cb92f 17.0 landed
-
On systems that have setsid(2) (which should be just about everything except
- 3ad0728c817b 8.2.0 cited