From: | Michael Paquier <michael(at)paquier(dot)xyz> |
---|---|
To: | Julien Rouhaud <rjuju123(at)gmail(dot)com> |
Cc: | Sergei Kornilov <sk(at)zsrv(dot)org>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org> |
Subject: | Re: Add parallelism and glibc dependent only options to reindexdb |
Date: | 2019-07-27 13:27:18 |
Message-ID: | 20190727132718.GA22377@paquier.xyz |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Sat, Jul 27, 2019 at 11:44:47AM +0200, Julien Rouhaud wrote:
> That's probably still more intuitive than having the count coming from
> either main() or from get_parallel_object_list() depending on the
> process type, so I'm fine with that alternative. Maybe we could bite
> the bullet and add a count meber to Simple*List, also providing a
> macro to initialize a new list so that next time a field is added
> there won't be a massive boilerplate code change?
Perhaps, we could discuss about that on a separate thread. For now I
have gone with the simplest approach of counting the items, and
stopping the count if there are more items than jobs. While reviewing
I have found a double-free in your patch when building a list of
relations for schemas or databases. If the list finishes empty,
PQfinish() was called twice on the connection, leading to a crash. I
have added a test for that, done an extra pass on the patch adjusting
a couple of things then committed the patch with the restriction on
--index and --jobs. This entry is now marked as committed in the CF
app.
--
Michael
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2019-07-27 16:46:51 | Testing LISTEN/NOTIFY more effectively |
Previous Message | Thomas Munro | 2019-07-27 11:49:10 | Re: Built-in connection pooler |