Re: Terminate the idle sessions
Japin Li <japinli@hotmail.com>
From: Li Japin <japinli@hotmail.com>
To: Bharath Rupireddy <bharath.rupireddyforpostgres@gmail.com>
Cc: Cary Huang <cary.huang@highgo.ca>, "david.g.johnston@gmail.com" <david.g.johnston@gmail.com>, "pgsql-hackers@lists.postgresql.org" <pgsql-hackers@lists.postgresql.org>
Date: 2020-08-14T08:02:27Z
Lists: pgsql-hackers
On Aug 14, 2020, at 2:15 PM, Bharath Rupireddy <bharath.rupireddyforpostgres@gmail.com<mailto:bharath.rupireddyforpostgres@gmail.com>> wrote: I think, since the idle_session_timeout is by default disabled, we have no problem. My thought is what if a user enables the feature(knowingly or unknowingly) on the remote backend? If the user knows about the above scenario, that may be fine. On the other hand, either we can always the feature on the remote backend(at the beginning of the remote txn, like we set for some other configuration settings see - configure_remote_session() in connection.c) or how about mentioning the above scenario in this feature documentation? Though we can disable the idle_session_timeout when using postgres_fdw, there still has locally cached connection cache entries when the remote sessions terminated by accident. AFAIK, you have provided a patch to solve this problem, and it is in current CF [1]. [1] - https://commitfest.postgresql.org/29/2651/ Best Regards, Japin Li.
Commits
-
Rethink SQLSTATE code for ERRCODE_IDLE_SESSION_TIMEOUT.
- 4edf96846a02 14.0 landed
-
Improve commentary in timeout.c.
- 9486e7b666fd 14.0 landed
-
Add idle_session_timeout.
- 9877374bef76 14.0 landed
-
Improve timeout.c's handling of repeated timeout set/cancel.
- 09cf1d522676 14.0 landed