public inbox for [email protected]
help / color / mirror / Atom feedFrom: Daniel Gustafsson <[email protected]>
To: Fujii Masao <[email protected]>
Cc: [email protected] <[email protected]>
Subject: Re: Fix data checksum progress reporting docs
Date: Fri, 10 Jul 2026 12:00:33 +0200
Message-ID: <[email protected]> (raw)
In-Reply-To: <CAHGQGwFsBjQs2fv7b72hxzGV_fJMh6LAg4E83pNfDOu1jVgWCA@mail.gmail.com>
References: <CAHGQGwHJHJYAkYZBi3_O13np-Rou9UL637=hB3Y_-qdCgcZn-w@mail.gmail.com>
<[email protected]>
<CAHGQGwEv-C9ia+rBYyePzO8F=5FVvS412ZqcOupazuOb5RafNg@mail.gmail.com>
<[email protected]>
<CAHGQGwFsBjQs2fv7b72hxzGV_fJMh6LAg4E83pNfDOu1jVgWCA@mail.gmail.com>
> On 10 Jul 2026, at 03:13, Fujii Masao <[email protected]> wrote:
>
> On Thu, Jul 9, 2026 at 5:28 PM Daniel Gustafsson <[email protected]> wrote:
>> You are absolutely right. And when looking at it I think we can simplify the
>> entry a bit as well to make it fit the style of the page better. What do you
>> think about the attached?
>
> Thanks for the patch! I like the overall approach.
> I just have a few minor comments.
>
> + A set of
> + <glossterm linkend="glossary-background-worker">background
> worker</glossterm>
> + processes which can enable, or disable, data checksums in a
>
> Wouldn't it be better to remove the two commas here?
Fixed.
> + running cluster. The process which coordinates the work is known as the
> + <firstterm>data checksums worker launcher</firstterm> and the process
>
> Only the glossary seems to use the term "data checksums worker launcher".
> Wouldn't "data checksums launcher" (i.e., dropping "worker") be a better name?
Fixed.
> + <firstterm>data checksums worker launcher</firstterm> and the process
> + which operate on the individual databases is known as the
> + <firstterm>data checksums worker</firstterm>.
>
> Shouldn't "the process which operate" be either "the process which operates"
> or "the processes which operate"? Since multiple data checksums workers
> can run, the latter seems more appropriate.
Currently the processing is limited to a single worker, so I think the proposed
wording is more appropriate. Expanding the code to handle multiple parallel
workers was left as a future enhancement (it will perhaps require better IO
throttling etc).
> While looking at the related code, I also found that
> B_DATACHECKSUMSWORKER_LAUNCHER and B_DATACHECKSUMSWORKER_WORKER
> were added as BackendType entries in miscadmin.h. Since those entries appear
> under the comment for auxiliary processes, it could give the impression that
> the data checksums launcher and workers are auxiliary processes. To avoid
> that confusion, would it make sense to add a comment such as:
>
> -------------------------
> B_WAL_WRITER,
>
> + /*
> + * XXXXXXXXXX
> + */
> B_DATACHECKSUMSWORKER_LAUNCHER,
> B_DATACHECKSUMSWORKER_WORKER,
> -------------------------
Fair point, see attached.
> BTW, I'm also wondering why dedicated BackendType entries were added for
> the data checksums processes, while other background workers don't have
> their own BackendType values.
They are need for the pgstat system though aren't they, or am I missing
something?
--
Daniel Gustafsson
Attachments:
[application/octet-stream] v2-0002-Add-a-comment-to-distinguish-backend-types.patch (976B, ../[email protected]/2-v2-0002-Add-a-comment-to-distinguish-backend-types.patch)
download | inline diff:
From 4c0ba4fd236548abfecdf0d6d242b3a57b2754f7 Mon Sep 17 00:00:00 2001
From: Daniel Gustafsson <[email protected]>
Date: Fri, 10 Jul 2026 11:37:06 +0200
Subject: [PATCH v2 2/2] Add a comment to distinguish backend types
The data checksums entries were seemingly auxiliary processes from
reading the code, but they are in fact background workers. Add a
comment to clarify.
Reported-by: Fujii Masao <[email protected]>
Discussion: https://postgr.es/m/CAHGQGwFsBjQs2fv7b72hxzGV_fJMh6LAg4E83pNfDOu1jVgWCA@mail.gmail.com
---
src/include/miscadmin.h | 1 +
1 file changed, 1 insertion(+)
diff --git a/src/include/miscadmin.h b/src/include/miscadmin.h
index 7170a4bff98..16da60721bf 100644
--- a/src/include/miscadmin.h
+++ b/src/include/miscadmin.h
@@ -370,6 +370,7 @@ typedef enum BackendType
B_WAL_SUMMARIZER,
B_WAL_WRITER,
+ /* Background worker processes */
B_DATACHECKSUMSWORKER_LAUNCHER,
B_DATACHECKSUMSWORKER_WORKER,
--
2.39.3 (Apple Git-146)
[application/octet-stream] v2-0001-doc-Fix-glossary-entry-for-data-checksums-workers.patch (3.7K, ../[email protected]/3-v2-0001-doc-Fix-glossary-entry-for-data-checksums-workers.patch)
download | inline diff:
From efaefdf09522fe2dfaf63347cd96a8ba341f340c Mon Sep 17 00:00:00 2001
From: Daniel Gustafsson <[email protected]>
Date: Thu, 9 Jul 2026 10:23:22 +0200
Subject: [PATCH v2 1/2] doc: Fix glossary entry for data checksums workers
The glossary entry for data checksums workers incorrectly stated that
they were auxiliary processes, but they are implementerd as background
workers. Fix, and while there, simplify the entry by combining the
worker and launcher into a single glossary term.
Reported-by: Fujii Masao <[email protected]>
Discussion: https://postgr.es/m/CAHGQGwEv-C9ia+rBYyePzO8F=5FVvS412ZqcOupazuOb5RafNg@mail.gmail.com
---
doc/src/sgml/glossary.sgml | 32 ++++++++++++--------------------
1 file changed, 12 insertions(+), 20 deletions(-)
diff --git a/doc/src/sgml/glossary.sgml b/doc/src/sgml/glossary.sgml
index f7f69afc922..9052f8bbf41 100644
--- a/doc/src/sgml/glossary.sgml
+++ b/doc/src/sgml/glossary.sgml
@@ -199,8 +199,6 @@
(but not the autovacuum workers),
the <glossterm linkend="glossary-background-writer">background writer</glossterm>,
the <glossterm linkend="glossary-checkpointer">checkpointer</glossterm>,
- the <glossterm linkend="glossary-data-checksums-worker">data checksums worker</glossterm>,
- the <glossterm linkend="glossary-data-checksums-worker-launcher">data checksums worker launcher</glossterm>,
the <glossterm linkend="glossary-logger">logger</glossterm>,
the <glossterm linkend="glossary-startup-process">startup process</glossterm>,
the <glossterm linkend="glossary-wal-archiver">WAL archiver</glossterm>,
@@ -236,8 +234,9 @@
which runs system- or user-supplied code.
Serves as infrastructure for several features in
<productname>PostgreSQL</productname>, such as
- <glossterm linkend="glossary-replication">logical replication</glossterm>
- and <glossterm linkend="glossary-parallel-query">parallel queries</glossterm>.
+ <glossterm linkend="glossary-replication">logical replication</glossterm>,
+ <glossterm linkend="glossary-parallel-query">parallel queries</glossterm> and
+ <glossterm linkend="glossary-data-checksums-process">data checksums processing</glossterm>.
In addition, <glossterm linkend="glossary-extension">Extensions</glossterm> can add
custom background worker processes.
</para>
@@ -588,24 +587,17 @@
<glosssee otherterm="glossary-data-directory" />
</glossentry>
- <glossentry id="glossary-data-checksums-worker">
- <glossterm>Data Checksums Worker</glossterm>
+ <glossentry id="glossary-data-checksums-process">
+ <glossterm>Data Checksums (process)</glossterm>
<glossdef>
<para>
- A <glossterm linkend="glossary-background-worker">background worker</glossterm>
- which enables data checksums in a specific database.
- </para>
- </glossdef>
- </glossentry>
-
- <glossentry id="glossary-data-checksums-worker-launcher">
- <glossterm>Data Checksums Worker Launcher</glossterm>
- <glossdef>
- <para>
- A <glossterm linkend="glossary-background-worker">background worker</glossterm>
- which starts <glossterm linkend="glossary-data-checksums-worker"> data
- checksum worker</glossterm> processes for enabling data checksums in each
- database, or disables data checksums cluster-wide.
+ A set of
+ <glossterm linkend="glossary-background-worker">background worker</glossterm>
+ processes which can enable or disable data checksums in a running cluster.
+ The process which coordinates the work is known as the
+ <firstterm>data checksums launcher</firstterm> and the process which
+ operate on the individual databases is known as the
+ <firstterm>data checksums worker</firstterm>.
</para>
</glossdef>
</glossentry>
--
2.39.3 (Apple Git-146)
view thread (6+ messages)
reply
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: [email protected]
Cc: [email protected], [email protected], [email protected]
Subject: Re: Fix data checksum progress reporting docs
In-Reply-To: <[email protected]>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox