From: | Dmitry Dolgov <9erthalion6(at)gmail(dot)com> |
---|---|
To: | Michael Paquier <michael(at)paquier(dot)xyz> |
Cc: | Postgres hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org> |
Subject: | Re: pg_index.indisreplident and invalid indexes |
Date: | 2020-08-28 08:15:37 |
Message-ID: | 20200828081537.2j2ur6jtnmbpuvw5@localhost |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
> On Thu, Aug 27, 2020 at 11:57:21AM +0900, Michael Paquier wrote:
>
> I think that this problem is similar to indisclustered, and that we
> had better set indisreplident to false when clearing indisvalid for an
> index concurrently dropped. This would prevent problems with ALTER
> TABLE of course, but also the relcache.
>
> Any objections to the attached? I am not sure that this is worth a
> backpatch as that's unlikely going to be a problem in the field, so
> I'd like to fix this issue only on HEAD. This exists since 9.4 and
> the introduction of replica identities.
Thanks for the patch. It sounds right, so no objections from me. But I
wonder if something similar has to be done also for
index_concurrently_swap function?
/*
* Mark the new index as valid, and the old index as invalid similarly to
* what index_set_state_flags() does.
*/
newIndexForm->indisvalid = true;
oldIndexForm->indisvalid = false;
oldIndexForm->indisclustered = false;
From | Date | Subject | |
---|---|---|---|
Next Message | Michael Paquier | 2020-08-28 08:21:36 | Re: pg_index.indisreplident and invalid indexes |
Previous Message | Masahiko Sawada | 2020-08-28 08:06:27 | Re: recovering from "found xmin ... from before relfrozenxid ..." |