Re: add PROCESS_MAIN to VACUUM

Michael Paquier <michael@paquier.xyz>

From: Michael Paquier <michael@paquier.xyz>
To: Melanie Plageman <melanieplageman@gmail.com>
Cc: Nathan Bossart <nathandbossart@gmail.com>, pgsql-hackers@postgresql.org
Date: 2023-03-07T00:20:12Z
Lists: pgsql-hackers
On Mon, Mar 06, 2023 at 06:12:36PM -0500, Melanie Plageman wrote:
> LGTM.

-    * Do the actual work --- either FULL or "lazy" vacuum
+    * If PROCESS_MAIN is set (the default), it's time to vacuum the main
+    * relation.  Otherwise, we can skip this part.  If required, we'll process
+    * the TOAST table later.

Should we mention that this part could be used for a toast table once
we've already looped once through vacuum_rel() when toast_relid was
set?  VACOPT_PROCESS_MAIN is enforced a few lines down the road,
still..
--
Michael

Commits

  1. Improve readability of code PROCESS_MAIN in vacuum_rel()

  2. Add PROCESS_MAIN to VACUUM

  3. Improve the regression tests of VACUUM (PROCESS_TOAST)

  4. Display the leader apply worker's PID for parallel apply workers.