Re: allow online change primary_conninfo
Sergei Kornilov <sk@zsrv.org>
From: Sergei Kornilov <sk@zsrv.org>
To: Fujii Masao <masao.fujii@gmail.com>
Cc: Michael Paquier <michael@paquier.xyz>, Andres Freund <andres@anarazel.de>, David Steele <david@pgmasters.net>, Kyotaro HORIGUCHI <horiguchi.kyotaro@lab.ntt.co.jp>, "pgsql-hackers@postgresql.org" <pgsql-hackers@postgresql.org>
Date: 2019-09-19T08:02:57Z
Lists: pgsql-hackers
Attachments
- v4_allow_reload_walreceiver_conninfo.patch (text/x-diff) patch v4
Hello Thank you for review! > ISTM that you need to update the above parts in postgresql.conf.sample. Good catch, I forgot about conf sample. > ISTM that you need to update the above comment in walreceiver.c. Changed > If primary_conninfo is set to an empty string, walreceiver just shuts down, > not restarts. The above description in the doc is not always true. > So I'm thinking something like the following description is better. > Thought? > > If primary_conninfo is changed while WAL receiver is running, > the WAL receiver shuts down and then restarts with new setting, > except when primary_conninfo is an empty string. Ok, changed. I leave primary_slot_name description as before. > There is the case where walreceiver doesn't shut down immediately > after the change of primary_conninfo. If the change happens while > the startup process in paused state (e.g., by pg_wal_replay_pause(), > recovery_min_apply_delay, recovery conflict, etc), the startup > process tries to terminate walreceiver after it gets out of such state. > Shouldn't this fact be documented as a note? Hmm. Is somewhere documented that walreceiver will receive WAL while the startup process in paused state? (didn't add such note in current version) regards, Sergei
Commits
-
Allow walreceiver configuration to change on reload
- 1e6148032e4d 13.0 landed