Re: GUC values - recommended way to declare the C variables?

From: Nathan Bossart <nathandbossart(at)gmail(dot)com>
To: Michael Paquier <michael(at)paquier(dot)xyz>
Cc: Peter Smith <smithpb2250(at)gmail(dot)com>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: GUC values - recommended way to declare the C variables?
Date: 2022-10-13 21:26:35
Message-ID: 20221013212635.GA1568479@nathanxps13
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Thu, Oct 13, 2022 at 09:47:25AM +0900, Michael Paquier wrote:
> So, the initial values of max_wal_senders and max_replication_slots
> became out of sync with their defaults in guc_tables.c. FWIW, I would
> argue the opposite way: rather than removing the initializations, I
> would fix and keep them as these references can be useful when
> browsing the area of the code related to such GUCs, without having to
> look at guc_tables.c for this information.

Well, those initializations are only useful when they are kept in sync,
which, as demonstrated by this patch, isn't always the case. I don't have
a terribly strong opinion about this, but I'd lean towards reducing the
number of places that track the default value of GUCs.

--
Nathan Bossart
Amazon Web Services: https://aws.amazon.com

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Bruce Momjian 2022-10-13 21:28:15 Re: New docs chapter on Transaction Management and related changes
Previous Message Corey Huinker 2022-10-13 21:06:31 WIP: Analyze whether our docs need more granular refentries.