Re: fix stats_fetch_consistency value in postgresql.conf.sample

From: Justin Pryzby <pryzby(at)telsasoft(dot)com>
To: Kyotaro Horiguchi <horikyota(dot)ntt(at)gmail(dot)com>
Cc: andres(at)anarazel(dot)de, michael(at)paquier(dot)xyz, nathandbossart(at)gmail(dot)com, pgsql-hackers(at)postgresql(dot)org
Subject: Re: fix stats_fetch_consistency value in postgresql.conf.sample
Date: 2022-06-11 14:41:37
Message-ID: 20220611144137.GC29853@telsasoft.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Mon, May 30, 2022 at 05:27:19PM +0900, Kyotaro Horiguchi wrote:
> At Sat, 28 May 2022 13:22:45 -0700, Andres Freund <andres(at)anarazel(dot)de> wrote in
> > Hi,
> >
> > On 2022-05-26 16:27:53 +0900, Kyotaro Horiguchi wrote:
> > > It could be in SQL, but *I* prefer to use perl for this, since it
> > > allows me to write a bit complex things (than simple string
> > > comparison) simpler.
> >
> > I wonder if we shouldn't just expose a C function to do this, rather than
> > having a separate implementation in a tap test.
>
> It was annoying that I needed to copy the unit-conversion stuff. I
> did that in the attached. parse_val() and check_val() and the duped
> data is removed.

Note that this gives:

guc.c:7573:9: warning: ‘dst’ may be used uninitialized in this function [-Wmaybe-uninitialized]

with gcc version 9.2.1 20191008 (Ubuntu 9.2.1-9ubuntu2)

I wonder whether you'd consider renaming pg_normalize_config_value() to
pg_pretty_config_value() or similar.

--
Justin

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Andrew Dunstan 2022-06-11 18:08:54 Subscription tests vs log_error_verbosity
Previous Message houzj.fnst@fujitsu.com 2022-06-11 09:06:16 RE: Replica Identity check of partition table on subscriber