Re: BUG #17485: Records missing from Primary Key index when doing REINDEX INDEX CONCURRENTLY

From: Michael Paquier <michael(at)paquier(dot)xyz>
To: Alvaro Herrera <alvherre(at)alvh(dot)no-ip(dot)org>
Cc: Andres Freund <andres(at)anarazel(dot)de>, Andrey Borodin <x4mmm(at)yandex-team(dot)ru>, Robert Haas <robertmhaas(at)gmail(dot)com>, Peter Geoghegan <pg(at)bowt(dot)ie>, Петър Славов <pet(dot)slavov(at)gmail(dot)com>, PostgreSQL mailing lists <pgsql-bugs(at)lists(dot)postgresql(dot)org>
Subject: Re: BUG #17485: Records missing from Primary Key index when doing REINDEX INDEX CONCURRENTLY
Date: 2022-05-31 12:03:17
Message-ID: YpYEBdG59FJ8s0FI@paquier.xyz
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

On Tue, May 31, 2022 at 11:19:01AM +0200, Alvaro Herrera wrote:
> Hmm, I wonder if it's possible to use an index ON tab (pg_sleep(100ms))
> or something like that (perhaps even use an expresion involving an
> advisory lock acquisition, which is being held by the other session), to
> widen the window.

I have not considered the use of expressions to enforce a lock at this
stage. I'll give it a shot, even if it comes to the abuse of an
immutable function with volatile internals :)

> The stop events patch that A. Korotkov posted [0] would likely be very
> useful here.
>
> [0] https://postgr.es/m/CAPpHfdtSEOHX8dSk9Qp+Z++i4BGQoffKip6JDWngEA+g7Z-XmQ@mail.gmail.com

Thanks for the reference. I've wanted to resurrect this stuff,
actually, after dealing with 6dced63 to be able to have a stop point
in the middle of a restart point.
--
Michael

In response to

Browse pgsql-bugs by date

  From Date Subject
Next Message Gregory Jensen 2022-05-31 12:44:08 Re: Inconsistent time zone output for JSON at UTC
Previous Message David G. Johnston 2022-05-31 12:00:34 Re: Inconsistent time zone output for JSON at UTC