Re: Add parallelism and glibc dependent only options to reindexdb

From: Michael Paquier <michael(at)paquier(dot)xyz>
To: Julien Rouhaud <rjuju123(at)gmail(dot)com>
Cc: Alvaro Herrera <alvherre(at)2ndquadrant(dot)com>, Peter Eisentraut <peter(dot)eisentraut(at)2ndquadrant(dot)com>, Thomas Munro <thomas(dot)munro(at)gmail(dot)com>, Daniel Verite <daniel(at)manitou-mail(dot)org>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>, Kevin Grittner <kgrittn(at)gmail(dot)com>
Subject: Re: Add parallelism and glibc dependent only options to reindexdb
Date: 2019-07-22 04:11:14
Message-ID: 20190722041114.GD1757@paquier.xyz
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Fri, Jul 19, 2019 at 08:29:27AM +0200, Julien Rouhaud wrote:
> On Fri, Jul 19, 2019 at 2:35 AM Michael Paquier <michael(at)paquier(dot)xyz> wrote:
>> For the second patch, could you send a rebase with a fix for the
>> connection slot when processing the reindex commands?
>
> Attached, I also hopefully removed all the now unneeded progname usage.

+ Note that this mode is not compatible the <option>-i / --index</option>
+ or the <option>-s / --system</option> options.
Nits: this is not a style consistent with the documentation. When
referring to both the long and short options the formulation "-i or
--index" gets used. Here we could just use the long option. This
sentence is missing a "with".

simple_string_list_append(&tables, optarg);
+ tbl_count++;
break;
The number of items in a simple list is not counted, and vacuumdb does
the same thing to count objects. What do you think about extending
simple lists to track the number of items stored?

+$node->issues_sql_like([qw(reindexdb -j2)],
+ qr/statement: REINDEX TABLE public.test1/,
+ 'Global and parallel reindex will issue per-table REINDEX');
Would it make sense to have some tests for schemas here?

One of my comments in [1] has not been answered. What about
the decomposition of a list of schemas into a list of tables when
using the parallel mode?

[1]: https://www.postgresql.org/message-id/20190711040433.GG4500@paquier.xyz
--
Michael

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2019-07-22 04:14:39 Re: Fix typos and inconsistencies for HEAD (take 7)
Previous Message Alvaro Herrera 2019-07-22 03:29:18 Re: Psql patch to show access methods info