Re: Add SKIP LOCKED to VACUUM and ANALYZE
Nathan Bossart <bossartn@amazon.com>
From: "Bossart, Nathan" <bossartn@amazon.com>
To: Michael Paquier <michael@paquier.xyz>
Cc: "pgsql-hackers@postgresql.org" <pgsql-hackers@postgresql.org>,
"Andres
Freund" <andres@anarazel.de>,
Masahiko Sawada <sawada.mshk@gmail.com>,
Robert
Haas <robertmhaas@gmail.com>,
Tomas Vondra <tomas.vondra@2ndquadrant.com>,
Lyes Ameddah <lyes.amd@gmail.com>
Date: 2018-09-05T15:24:21Z
Lists: pgsql-hackers
Attachments
- v9-0007-Open-up-VACOPT_SKIP_LOCKED-to-users.patch (application/octet-stream) patch v9-0007
- v9-0006-Skip-VACUUM-ANALYZE-with-VACOPT_SKIP_LOCKED-if-ex.patch (application/octet-stream) patch v9-0006
- v9-0005-Skip-ANALYZE-with-VACOPT_SKIP_LOCKED-if-acquire_i.patch (application/octet-stream) patch v9-0005
- v9-0004-Create-a-helper-function-for-cleaning-up-from-do_.patch (application/octet-stream) patch v9-0004
- v9-0003-Add-skip_locked-argument-to-find_all_inheritors.patch (application/octet-stream) patch v9-0003
- v9-0002-Add-skip_locked-argument-to-find_inheritance_chil.patch (application/octet-stream) patch v9-0002
- v9-0001-Create-a-helper-function-for-determining-the-log-.patch (application/octet-stream) patch v9-0001
On 9/4/18, 1:32 PM, "Michael Paquier" <michael@paquier.xyz> wrote:
>On Tue, Sep 04, 2018 at 03:49:09PM +0000, Bossart, Nathan wrote:
>> Yes. I've started working on this again, but the new patch set is
>> probably still a few days out.
>
> Thanks, Nathan.
And here it is. Here is a summary of the notable changes:
1) Patches v8-0003 and v8-0008 have been discarded. These patches
added SKIP_LOCKED behavior when opening a relation's indexes.
Instead, I've documented that VACUUM and ANALYZE may still block
on indexes in v9-0007.
2) Patches v8-0004 and v8-0005 have been discarded, as they have
already been committed.
3) Patch v8-0011 has been discarded. As previously noted, VACUUM
(SKIP_LOCKED, FULL) is already handled in vacuum_rel(), so no
changed are required to cluster_rel(). However, we will need
something similar to v8-0011 if we ever add SKIP_LOCKED to
CLUSTER.
4) The option has been renamed to SKIP_LOCKED (with the underscore)
for consistency with the DISABLE_PAGE_SKIPPING option.
5) In the documentation, I've listed the caveats for SKIP_LOCKED and
partitioned tables. I tried to make all the new documentation as
concise as possible.
Nathan
Commits
-
Add option SKIP_LOCKED to VACUUM and ANALYZE
- 803b1301e8c9 12.0 landed
-
Refactor relation opening for VACUUM and ANALYZE
- e3a25ab9ea56 12.0 landed
-
Refactor cluster_rel() to handle more options
- 9ebe0572ceab 12.0 landed
-
Add assertion in expand_vacuum_rel() for non-autovacuum path
- 6551f3daa256 12.0 landed