Add parallel vacuum worker usage to VACUUM (VERBOSE) and autovacuum logs.
Masahiko Sawada <msawada@postgresql.org>
Author:
Masahiko Sawada <msawada@postgresql.org>
Date: 2026-03-19T22:01:47Z
Releases:
19 (unreleased)
Add parallel vacuum worker usage to VACUUM (VERBOSE) and autovacuum logs. This commit adds both the number of parallel workers planned and the number of parallel workers actually launched to the output of VACUUM (VERBOSE) and autovacuum logs. Previously, this information was only reported as an INFO message during VACUUM (VERBOSE), which meant it was not included in autovacuum logs in practice. Although autovacuum does not yet support parallel vacuum, a subsequent patch will enable it and utilize these logs in its regression tests. This change also improves observability by making it easier to verify if parallel vacuum is utilizing the expected number of workers. Author: Daniil Davydov <3danissimo@gmail.com> Reviewed-by: Masahiko Sawada <sawada.mshk@gmail.com> Reviewed-by: Sami Imseih <samimseih@gmail.com> Discussion: https://postgr.es/m/CACG=ezZOrNsuLoETLD1gAswZMuH2nGGq7Ogcc0QOE5hhWaw=cw@mail.gmail.com
Files
| Path | Change | +/− |
|---|---|---|
| src/backend/access/heap/vacuumlazy.c | modified | +29 −2 |
| src/backend/commands/vacuumparallel.c | modified | +17 −6 |
| src/include/commands/vacuum.h | modified | +26 −2 |
| src/tools/pgindent/typedefs.list | modified | +2 −0 |
Discussion
- POC: Parallel processing of indexes in autovacuum 114 messages · 2025-04-16 → 2026-04-09