Re: Revisiting {CREATE INDEX, REINDEX} CONCURRENTLY improvements
Sergey Sargsyan <sergey.sargsyan.2001@gmail.com>
From: Sergey Sargsyan <sergey.sargsyan.2001@gmail.com>
To: Mihail Nikalayeu <mihailnikalayeu@gmail.com>
Cc: Álvaro Herrera <alvherre@kurilemu.de>, Andres Freund <andres@anarazel.de>, Michael Paquier <michael@paquier.xyz>, PostgreSQL Hackers <pgsql-hackers@postgresql.org>, Andrey Borodin <amborodin86@gmail.com>, Melanie Plageman <melanieplageman@gmail.com>, Matthias van de Meent <boekewurm+postgres@gmail.com>
Date: 2025-07-07T12:00:37Z
Lists: pgsql-hackers
Commits
Same data as JSON:
GET /api/v1/messages/:b64id/commits
the thread's linked commits as JSON, with link sources.
API reference →
-
Revert changes to CONCURRENTLY that "sped up" Xmin advance
- e28bb8851969 15.0 cited
-
VACUUM: ignore indexing operations with CONCURRENTLY
- d9d076222f5b 14.0 cited
-
Avoid spurious waits in concurrent indexing
- c98763bf51bf 14.0 cited
I’ve tested the patch across several thousand test cases, and no faults of any kind have been observed. Additionally, I independently built a closed banking transaction system to verify consistency during REINDEX CONCURRENTLY while multiple backends were writing simultaneously. The results showed no missing transactions, and the validation logic worked exactly as expected. On large tables, I observed a significant speedup—often several times faster. I believe this patch is highly valuable, as REINDEX CONCURRENTLY is a common maintenance operation. I also noticed that there is a separate thread working on adding support for concurrent reindexing of partitioned indexes. Without this patch, that feature would likely suffer from serious performance issues due to the need to reindex many indexes in one go—making the process both time-consuming and lock-intensive. Best regards, S On Thu, Jul 3, 2025, 3:24 AM Mihail Nikalayeu <mihailnikalayeu@gmail.com> wrote: > Hello! > > Rebased again, patch structure and comments available here [0]. Quick > introduction poster - here [1]. > > Best regards, > Mikhail. > > [0]: > https://www.postgresql.org/message-id/flat/CADzfLwVOcZ9mg8gOG%2BKXWurt%3DMHRcqNv3XSECYoXyM3ENrxyfQ%40mail.gmail.com#52c97e004b8f628473124c05e3bf2da1 > [1]: > https://www.postgresql.org/message-id/attachment/176651/STIR-poster.pdf >