Re: pg_settings.pending_restart not set when line removed
Alvaro Herrera <alvherre@alvh.no-ip.org>
From: Alvaro Herrera <alvherre@alvh.no-ip.org>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: Pg Hackers <pgsql-hackers@lists.postgresql.org>
Date: 2021-07-27T14:29:32Z
Lists: pgsql-hackers
On 2021-Jul-27, Tom Lane wrote: > Alvaro Herrera <alvherre@alvh.no-ip.org> writes: > > You could argue that this is *weird* (why does reading pg_file_settings > > set a flag in global state?) ... but that weirdness is not something > > this patch is introducing. > > Ugh. I think this patch is likely to create more problems than it fixes. I doubt that; as I said, the code already behaves in exactly that way for closely related operations, so this patch isn't doing anything new. Note that that loop this code is modifying only applies to lines that are removed from the config file. > We should be looking to get rid of that flag, not make its behavior even > more complex. Are you proposing to remove the pending_restart column from pg_settings? That seems a step backwards. What I know is that the people behind management interfaces need some way to know if changes to the config need a system restart. Now maybe we want that feature to be implemented in a different way than it currently is. I frankly don't care enough to do that myself. I agree that the current mechanism is weird, but it's going to take more than a one-liner to fix it. The one-liner is only intended to fix a very specific problem. -- Álvaro Herrera 39°49'30"S 73°17'W — https://www.EnterpriseDB.com/ "After a quick R of TFM, all I can say is HOLY CR** THAT IS COOL! PostgreSQL was amazing when I first started using it at 7.2, and I'm continually astounded by learning new features and techniques made available by the continuing work of the development team." Berend Tober, http://archives.postgresql.org/pgsql-hackers/2007-08/msg01009.php
Commits
-
Set pg_setting.pending_restart when pertinent config lines are removed
- ddd1eac99369 11.13 landed
- b8f91d7f9263 13.4 landed
- ad3b40eb26a3 14.0 landed
- 93a0bf239032 15.0 landed
- 85ec6c322650 9.6.23 landed
- 6feb229f53f8 12.8 landed
- 04fa0e11ac20 10.18 landed