RE: [Proposal] Add foreign-server health checks infrastructure
Hayato Kuroda (Fujitsu) <kuroda.hayato@fujitsu.com>
From: "kuroda.hayato@fujitsu.com" <kuroda.hayato@fujitsu.com>
To: 'Fujii Masao' <masao.fujii@oss.nttdata.com>
Cc: "pgsql-hackers@lists.postgresql.org" <pgsql-hackers@lists.postgresql.org>, "Shinya11.Kato@oss.nttdata.com" <Shinya11.Kato@oss.nttdata.com>, "zyu@yugabyte.com" <zyu@yugabyte.com>, 'Kyotaro Horiguchi' <horikyota.ntt@gmail.com>
Date: 2022-09-21T11:56:56Z
Lists: pgsql-hackers
Attachments
- v15-0001-Add-an-infrastracture-for-checking-remote-server.patch (application/octet-stream) patch v15-0001
- v15-0002-postgres_fdw-Implement-health-check-feature.patch (application/octet-stream) patch v15-0002
- v15-0003-add-doc.patch (application/octet-stream) patch v15-0003
- v15-0004-add-test.patch (application/octet-stream) patch v15-0004
Dear Fujii-san,
Thanks for checking!
> These failed to be applied to the master branch cleanly. Could you update them?
PSA rebased patches. I reviewed my myself and they contain changes.
E.g., move GUC-related code to option.c.
> + this option relies on kernel events exposed by Linux, macOS,
>
> s/this/This
Fixed.
>
> + GUC_check_errdetail("pgfdw_health_check_interval must be set
> to 0 on this platform");
>
> The actual parameter name "postgres_fdw.health_check_interval"
> should be used for the message instead of internal variable name.
Fixed.
> This registered signal handler does lots of things. But that's not acceptable
> and they should be performed outside signal handler. No?
I modified like v09 or earlier versions, which has a mechanism for registering CheckingRemoteServersCallback.
It had been removed because we want to keep core simpler, but IIUC it is needed
if the signal handler just sets some flags.
The core-side does not consider the current status of transaction and running query for simpleness.
Best Regards,
Hayato Kuroda
FUJITSU LIMITED
Commits
-
postgres_fdw: Extend postgres_fdw_get_connections to return user name.
- 4f08ab554577 18.0 landed
-
postgres_fdw: Fix bug in connection status check.
- 454aab4b738e 18.0 landed
-
postgres_fdw: Add connection status check to postgres_fdw_get_connections().
- 857df3cef7be 18.0 landed
-
postgres_fdw: Add "used_in_xact" column to postgres_fdw_get_connections().
- c297a47c5f8d 18.0 landed
-
doc: Enhance documentation for postgres_fdw_get_connections() output columns.
- 284c030a10b8 18.0 landed
-
Avoid reference to nonexistent array element in ExecInitAgg().
- 92957ed98c5c 16.0 cited
-
Add WL_SOCKET_CLOSED for socket shutdown events.
- 50e570a59e7f 15.0 cited
-
postgres_fdw: reestablish new connection if cached one is detected as broken.
- 32a9c0bdf493 14.0 cited