From: Julien Rouhaud <rjuju123@gmail.com>
To: Masahiko Sawada <masahiko.sawada@2ndquadrant.com>
Cc: Michael Paquier <michael@paquier.xyz>
Cc: Robert Haas <robertmhaas@gmail.com>
Cc: PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>
Cc: Masahiko Sawada <sawada.mshk@gmail.com>
Subject: Re: Online checksums verification in the backend
Date: Sun, 5 Apr 2020 13:17:22 +0200
Message-ID: <20200405111722.GH1206@nol> (raw)
In-Reply-To: <CA+fd4k4ymDsLam6RyrR6mquwpBqSzOC11WK7cCT69+jt6VBSCg@mail.gmail.com>
References: <CA+fd4k4B8QVxhQa8=5pf7SuDcB0vBhqzOn0c59FxVa99CF0ptQ@mail.gmail.com>
<20200328121858.GA13605@nol>
<CA+fd4k4--o41NxwN2kjfRn6W474R-P9D8aL8FW27nQmWm0++hA@mail.gmail.com>
<20200403093911.GB1206@nol>
<20200404090428.GD1206@nol>
<CA+fd4k7c83ViCvZtochX9msnyigDjcNujphFSXdnd7QOaWXSqA@mail.gmail.com>
<20200405084355.GF1206@nol>
<CA+fd4k5VS_QAkdGwU-mwsr1z78XM7egixZ2bDhfeSJm4HCrRGg@mail.gmail.com>
<20200405094459.GG1206@nol>
<CA+fd4k4ymDsLam6RyrR6mquwpBqSzOC11WK7cCT69+jt6VBSCg@mail.gmail.com>
On Sun, Apr 05, 2020 at 08:01:36PM +0900, Masahiko Sawada wrote:
> On Sun, 5 Apr 2020 at 18:45, Julien Rouhaud <rjuju123@gmail.com> wrote:
> >
> > On Sun, Apr 05, 2020 at 06:08:06PM +0900, Masahiko Sawada wrote:
> > >
> > > Why do we need two rows in the doc? For instance, replication slot
> > > functions have some optional arguments but there is only one row in
> > > the doc. So I think we don't need to change the doc from the previous
> > > version patch.
> > >
> >
> > I thought that if we document the function as pg_check_relation(regclass [,
> > fork]) users could think that the 2nd argument is optional, so that
> > pg_check_relation('something', NULL) could be a valid alias for the 1-argument
> > form, which it isn't. After checking, I see that e.g. current_setting has the
> > same semantics and is documented the way you suggest, so fixed back to previous
> > version.
> >
> > > And I think these are not necessary as we already defined in
> > > include/catalog/pg_proc.dat:
> > >
> > > +CREATE OR REPLACE FUNCTION pg_check_relation(
> > > + IN relation regclass,
> > > + OUT relid oid, OUT forknum integer, OUT failed_blocknum bigint,
> > > + OUT expected_checksum integer, OUT found_checksum integer)
> > > + RETURNS SETOF record STRICT VOLATILE LANGUAGE internal AS 'pg_check_relation'
> > > + PARALLEL RESTRICTED;
> > > +
> > > +CREATE OR REPLACE FUNCTION pg_check_relation(
> > > + IN relation regclass, IN fork text,
> > > + OUT relid oid, OUT forknum integer, OUT failed_blocknum bigint,
> > > + OUT expected_checksum integer, OUT found_checksum integer)
> > > + RETURNS SETOF record STRICT VOLATILE LANGUAGE internal
> > > + AS 'pg_check_relation_fork'
> > > + PARALLEL RESTRICTED;
> > >
> >
> > Oh right this isn't required since there's no default value anymore, fixed.
> >
> > v9 attached.
>
> Thank you for updating the patch! The patch looks good to me.
>
> I've marked this patch as Ready for Committer. I hope this patch will
> get committed to PG13.
>
Thanks a lot!
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-hackers@postgresql.org
Cc: rjuju123@gmail.com, masahiko.sawada@2ndquadrant.com, michael@paquier.xyz, robertmhaas@gmail.com, pgsql-hackers@lists.postgresql.org, sawada.mshk@gmail.com
Subject: Re: Online checksums verification in the backend
In-Reply-To: <20200405111722.GH1206@nol>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox