Re: [HACKERS] REINDEX CONCURRENTLY 2.0

Andrew Gierth <andrew@tao11.riddles.org.uk>

From: Andrew Gierth <andrew@tao11.riddles.org.uk>
To: Alvaro Herrera <alvherre@2ndquadrant.com>
Cc: Stephen Frost <sfrost@snowman.net>, Peter Eisentraut <peter.eisentraut@2ndquadrant.com>, Sergei Kornilov <sk@zsrv.org>, Michael Paquier <michael.paquier@gmail.com>, Andreas Karlsson <andreas@proxel.se>, PostgreSQL mailing lists <pgsql-hackers@postgresql.org>, Craig Ringer <craig@2ndquadrant.com>
Date: 2018-12-31T21:35:57Z
Lists: pgsql-hackers
>>>>> "Alvaro" == Alvaro Herrera <alvherre@2ndquadrant.com> writes:

 Alvaro> After looking at the proposed grammar again today and in danger
 Alvaro> of repeating myself, IMO allowing the concurrency keyword to
 Alvaro> appear outside the parens would be a mistake. Valid commands:

 Alvaro>   REINDEX (VERBOSE, CONCURRENTLY) TABLE foo;
 Alvaro>   REINDEX (CONCURRENTLY) INDEX bar;

We burned that bridge with CREATE INDEX CONCURRENTLY; to make REINDEX
require different syntax would be too inconsistent.

If we didn't have all these existing uses of CONCURRENTLY without
parens, your argument might have more merit; but we do.

-- 
Andrew (irc:RhodiumToad)


Commits

  1. Prevent reindex of invalid indexes on TOAST tables

  2. Rework handling of invalid indexes with REINDEX CONCURRENTLY

  3. Split builtins.h to a new header ruleutils.h