Re: [PATCH] Add ALTER SYSTEM RELOAD - Mailing list pgsql-hackers

From Andreas Karlsson
Subject Re: [PATCH] Add ALTER SYSTEM RELOAD
Date
Msg-id 6ba07f06-28f6-461b-a7b6-05ed4b99bd91@proxel.se
Whole thread
In response to Re: [PATCH] Add ALTER SYSTEM RELOAD  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
On 9/24/26 9:29 PM, Tom Lane wrote:
> Chao Li <li.evan.chao@gmail.com> writes:
>>> On Sep 23, 2026, at 17:44, Yuhang Qiu <iamqyh@gmail.com> wrote:
>>> For configuration parameters that can be reloaded, administrators often need
>>> to perform two steps in succession:
>>> ```sql
>>> ALTER SYSTEM SET work_mem = '64MB';
>>> SELECT pg_reload_conf();
>>> ```
>>>
>>> I propose adding `ALTER SYSTEM RELOAD`, so the sequence can be written as:
>>> ```sql
>>> ALTER SYSTEM SET work_mem = '64MB';
>>> ALTER SYSTEM RELOAD;
>>> ```
> 
>> Thanks for the patch. After reading it, I have a concern. pg_reload_conf() relies on normal function privileges, so
asuper user can grant EXECUTE on it to a non-superuser. With this patch, the two interfaces for doing essentially the
samething would have different privilege models:
 
> 
> I'm pretty down on this proposal even without the privilege question.
> "There's more than one way to do it" isn't a great thing for
> security-relevant operations, and this surely is one.

+1

I do not see how this adds anything worth the increased maintenance 
burden. How to reload the config is clearly discoverable in the docs for 
ALTER SYSTEM.

Andreas




pgsql-hackers by date:

Previous
From: Zsolt Parragi
Date:
Subject: Re: [PATCH v1] Fix for Bug#19724 - ALTER TYPE ... ALTER ATTRIBUTE triggers internal error for base type of domain with check
Next
From: Fabrízio Mello
Date:
Subject: Add pg_stat_log_messages: cumulative statistics about server log messages (was: Add contrib module pg_stat_log: cumulative statistics about server log messages)