From: | Matthias van de Meent <boekewurm+postgres(at)gmail(dot)com> |
---|---|
To: | PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org> |
Subject: | Summarizing indexes allowing single-phase VACUUM? |
Date: | 2025-04-09 21:47:19 |
Message-ID: | CAEze2WhuLjv6Htftw-sGZ0XjBj7h=a-aJkj-eVB2PjA_ck0CbA@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Hi,
With PG16, we got Index AM -level indications for summarizing indexes,
improving HOT applicability.
Given that these indexes explicitly never store TIDs and thus don't
really need the cleanup part of vacuum's index cleanup, we could well
decide to not count those indexes to the indexes we need to clean up
in the index scan phase of vacuum, thus allowing tables with only
summarizing indexes to use the single-scan option of vacuum.
As a summarizing index may still want to do some housekeeping during
vacuum, it'd still need to get its cleanup functions called, but it'd
at least save the io and WAL of the cleanup scan.
Any comments/suggestions? POC patch attached.
Kind regards,
Matthias van de Meent
Neon (https://neon.tech)
Attachment | Content-Type | Size |
---|---|---|
v00-0001-WIP-Optimize-VACUUM-for-tables-with-only-summari.patch | application/octet-stream | 9.6 KB |
From | Date | Subject | |
---|---|---|---|
Next Message | David G. Johnston | 2025-04-09 21:48:24 | Re: n_ins_since_vacuum stats for aborted transactions |
Previous Message | Mark Dilger | 2025-04-09 21:23:18 | Re: n_ins_since_vacuum stats for aborted transactions |