Re: REINDEX blocks virtually any queries but some prepared queries. - Mailing list pgsql-hackers

From Guillaume Lelarge
Subject Re: REINDEX blocks virtually any queries but some prepared queries.
Date
Msg-id CAECtzeWffJaqEEyEoSf5K4SToPx8bJVDhYLdK1m5uzgasQDy6w@mail.gmail.com
Whole thread Raw
In response to Re: REINDEX blocks virtually any queries but some prepared queries.  (Frédéric Yhuel <frederic.yhuel@dalibo.com>)
Responses Re: REINDEX blocks virtually any queries but some prepared queries.  (Michael Paquier <michael@paquier.xyz>)
List pgsql-hackers
Le jeu. 7 avr. 2022 à 15:44, Frédéric Yhuel <frederic.yhuel@dalibo.com> a écrit :


On 4/7/22 14:40, Justin Pryzby wrote:
> On Thu, Apr 07, 2022 at 01:37:57PM +0200, Frédéric Yhuel wrote:
>> Maybe something along this line? (patch attached)
> Some language fixes.

Thank you Justin! I applied your fixes in the v2 patch (attached).


v2 patch sounds good.
 
> I didn't verify the behavior, but +1 to document the practical consequences.
> I guess this is why someone invented REINDEX CONCURRENTLY.
>

Indeed ;) That being said, REINDEX CONCURRENTLY could give you an
invalid index, so sometimes you may be tempted to go for a simpler
REINDEX, especially if you believe that the SELECTs won't be blocked.

Agreed.


--
Guillaume.

pgsql-hackers by date:

Previous
From: Justin Pryzby
Date:
Subject: Re: How about a psql backslash command to show GUCs?
Next
From: Robert Haas
Date:
Subject: Re: why pg_walfile_name() cannot be executed during recovery?