Re: pgsql: reindexdb: Add the index-level REINDEX with multiple jobs

2025-03-12 Thread Álvaro Herrera
On 2025-Mar-11, Alexander Korotkov wrote: > Thank you for your feedback! I also think that pipelining would be a > better options, but it's too invasive for backpatching. I've written > comments for gen_reindex_command() and run_reindex_command(). I'm > going to push this patch to master and 17

Re: pgsql: reindexdb: Add the index-level REINDEX with multiple jobs

2025-03-11 Thread Alexander Korotkov
On Mon, Mar 10, 2025 at 1:12 PM Álvaro Herrera wrote: > On 2025-Mar-09, Alexander Korotkov wrote: > > > After second thought it's not so hard to fix. The attached patch does > > it by putting REINDEX commands related to the same table into a single > > SQL statement. Possibly, that could be bett

Re: pgsql: reindexdb: Add the index-level REINDEX with multiple jobs

2025-03-10 Thread Álvaro Herrera
On 2025-Mar-09, Alexander Korotkov wrote: > After second thought it's not so hard to fix. The attached patch does > it by putting REINDEX commands related to the same table into a single > SQL statement. Possibly, that could be better than revert given we > need to handle compatibility. What do

Re: pgsql: reindexdb: Add the index-level REINDEX with multiple jobs

2025-03-09 Thread Alexander Korotkov
On Sun, Mar 9, 2025 at 4:53 AM Alexander Korotkov wrote: > On Sat, Mar 8, 2025 at 12:49 PM Alexander Korotkov > wrote: > > On Fri, Mar 7, 2025 at 8:20 PM Álvaro Herrera > > wrote: > > > > > > On 2024-Mar-25, Alexander Korotkov wrote: > > > > > > > reindexdb: Add the index-level REINDEX with mu

Re: pgsql: reindexdb: Add the index-level REINDEX with multiple jobs

2025-03-08 Thread Alexander Korotkov
On Sat, Mar 8, 2025 at 12:49 PM Alexander Korotkov wrote: > On Fri, Mar 7, 2025 at 8:20 PM Álvaro Herrera wrote: > > > > On 2024-Mar-25, Alexander Korotkov wrote: > > > > > reindexdb: Add the index-level REINDEX with multiple jobs > > > > > > Straight-forward index-level REINDEX is not supported

Re: pgsql: reindexdb: Add the index-level REINDEX with multiple jobs

2025-03-08 Thread Alexander Korotkov
On Fri, Mar 7, 2025 at 8:20 PM Álvaro Herrera wrote: > > On 2024-Mar-25, Alexander Korotkov wrote: > > > reindexdb: Add the index-level REINDEX with multiple jobs > > > > Straight-forward index-level REINDEX is not supported with multiple jobs as > > we cannot control the concurrent processing of

Re: pgsql: reindexdb: Add the index-level REINDEX with multiple jobs

2025-03-08 Thread Alexander Korotkov
On Sat, Mar 8, 2025 at 11:57 AM Álvaro Herrera wrote: > > On 2025-Mar-07, Álvaro Herrera wrote: > > > I tested this, because of a refactoring suggestion [1] and I find that > > it's rather completely broken. > > I think we need significantly more complex scheduling code if we want > this to actual

Re: pgsql: reindexdb: Add the index-level REINDEX with multiple jobs

2025-03-08 Thread Álvaro Herrera
On 2025-Mar-07, Álvaro Herrera wrote: > I tested this, because of a refactoring suggestion [1] and I find that > it's rather completely broken. I think we need significantly more complex scheduling code if we want this to actually work, possibly even having to hack the ParallelSlot API some, so t

Re: pgsql: reindexdb: Add the index-level REINDEX with multiple jobs

2025-03-07 Thread Álvaro Herrera
On 2024-Mar-25, Alexander Korotkov wrote: > reindexdb: Add the index-level REINDEX with multiple jobs > > Straight-forward index-level REINDEX is not supported with multiple jobs as > we cannot control the concurrent processing of multiple indexes depending on > the same relation. Instead, we de