Re: pg_stat_progress_basebackup - progress reporting forpg_basebackup, in the server side - Mailing list pgsql-hackers

From Amit Langote
Subject Re: pg_stat_progress_basebackup - progress reporting forpg_basebackup, in the server side
Date
Msg-id CA+HiwqEtLghwQyArvckNAGBqvN-gtoBxWA__LUBnGG3o59A=cQ@mail.gmail.com
Whole thread Raw
In response to Re: pg_stat_progress_basebackup - progress reporting forpg_basebackup, in the server side  (Fujii Masao <masao.fujii@oss.nttdata.com>)
Responses Re: pg_stat_progress_basebackup - progress reporting forpg_basebackup, in the server side
List pgsql-hackers
On Mon, Feb 17, 2020 at 10:00 PM Fujii Masao
<masao.fujii@oss.nttdata.com> wrote:
> On 2020/02/06 11:07, Amit Langote wrote:
> > On Thu, Feb 6, 2020 at 9:51 AM Kyotaro Horiguchi <horikyota.ntt@gmail.com> wrote:
> >> I thought of "establishing checkpoint" or "running a checkpoint" as
> >> other candidates.
> >
> > Okay, I understand.  I am fine with "running checkpoint", although I
> > think "waiting for checkpoint" isn't totally wrong either.
>
> Yeah, but if "waiting for XXX" sounds a bit confusing to some people,
> I'm OK to back to "waiting for XXX to finish" that you originally
> proposed.
>
> Attached the updated version of the patch. This patch uses the following
> descriptions of the phases.
>
>    waiting for checkpoint to finish
>    estimating backup size
>    streaming database files
>    waiting for wal archiving to finish
>    transferring wal files

Thanks for the new patch.

I noticed that there is missing </para> tag in the documentation changes:

+     <row>
+      <entry><literal>waiting for checkpoint to finish</literal></entry>
+      <entry>
+       The WAL sender process is currently performing
+       <function>pg_start_backup</function> to set up for
+       taking a base backup, and waiting for backup start
+       checkpoint to finish.
+      </entry>
+     <row>

There should be a </row> between </entry> and <row> at the end of the
hunk shown above.

Sorry for not saying it before, but the following text needs revisiting:

+  <para>
+   Whenever <application>pg_basebackup</application> is taking a base
+   backup, the <structname>pg_stat_progress_basebackup</structname>
+   view will contain a row for each WAL sender process that is currently
+   running <command>BASE_BACKUP</command> replication command
+   and streaming the backup.

I understand that you wrote "Whenever pg_basebackup is taking a
backup...", because description of other views contains a similar
starting line.  But, it may not only be pg_basebackup that would be
served by this view, no?  It could be any tool that speaks Postgres'
replication protocol and thus be able to send a BASE_BACKUP command.
If that is correct, I would write something like "When an application
is taking a backup" or some such without specific reference to
pg_basebackup.  Thoughts?

Thanks,
Amit



pgsql-hackers by date:

Previous
From: Michael Paquier
Date:
Subject: Re: Clean up some old cruft related to Windows
Next
From: Kyotaro Horiguchi
Date:
Subject: False failure during repeated windows build.