pgsql: Refactor code dedicated to index vacuuming in vacuumlazy.c

2019-12-26 Thread Michael Paquier
Refactor code dedicated to index vacuuming in vacuumlazy.c The part in charge of doing the vacuum on all the indexes of a relation was duplicated, with the same handling for progress reporting done. While on it, update the progress reporting for heap vacuuming in the subroutine doing the actual wo

pgsql: Fix some comments related to logical repslot advancing

2019-12-26 Thread Michael Paquier
Fix some comments related to logical repslot advancing confirmed_flush is part of a replication slot's information, but not confirmed_lsn. Author: Kyotaro Horiguchi Discussion: https://postgr.es/m/[email protected] Backpatch-through: 11 Branch -- mast

pgsql: Fix some comments related to logical repslot advancing

2019-12-26 Thread Michael Paquier
Fix some comments related to logical repslot advancing confirmed_flush is part of a replication slot's information, but not confirmed_lsn. Author: Kyotaro Horiguchi Discussion: https://postgr.es/m/[email protected] Backpatch-through: 11 Branch -- REL_

pgsql: Fix some comments related to logical repslot advancing

2019-12-26 Thread Michael Paquier
Fix some comments related to logical repslot advancing confirmed_flush is part of a replication slot's information, but not confirmed_lsn. Author: Kyotaro Horiguchi Discussion: https://postgr.es/m/[email protected] Backpatch-through: 11 Branch -- REL_

Re: pgsql: Rename files and headers related to index AM

2019-12-26 Thread Alvaro Herrera
On 2019-Dec-25, Michael Paquier wrote: > Rename files and headers related to index AM > > The following renaming is done so as source files related to index > access methods are more consistent with table access methods (the > original names used for index AMs ware too generic, and could be > con

pgsql: Refactor parser's generation of Var nodes.

2019-12-26 Thread Tom Lane
Refactor parser's generation of Var nodes. Instead of passing around a pointer to the RangeTblEntry that provides the desired column, pass a pointer to the associated ParseNamespaceItem. The RTE is trivially reachable from the nsitem, and having the ParseNamespaceItem allows access to additional

pgsql: Improve comments in utils/rel.h.

2019-12-26 Thread Tom Lane
Improve comments in utils/rel.h. Mark the fields that should be accessed via partitioning-related functions, as we already did for some other fields. Amit Langote Discussion: https://postgr.es/m/CA+HiwqFnK6LbVMACMCaqwWrvoSFTecZzufKRahg2qGvLPYMX=g...@mail.gmail.com Branch -- master Details

Re: pgsql: Rename files and headers related to index AM

2019-12-26 Thread Andres Freund
Hi, On 2019-12-26 11:46:06 -0300, Alvaro Herrera wrote: > On 2019-Dec-25, Michael Paquier wrote: > > > Rename files and headers related to index AM > > > > The following renaming is done so as source files related to index > > access methods are more consistent with table access methods (the > >

Re: pgsql: Rename files and headers related to index AM

2019-12-26 Thread Peter Geoghegan
On Thu, Dec 26, 2019 at 10:15 AM Andres Freund wrote: > Yea, this seems like a much bigger move than warranted. Especially > without a backward compat header put into place. > > Imo this ought to be reverted. I agree. -- Peter Geoghegan

pgsql: Fix possible loss of sync between rectypeid and underlying PLpgS

2019-12-26 Thread Tom Lane
Fix possible loss of sync between rectypeid and underlying PLpgSQL_type. When revalidate_rectypeid() acts to update a stale record type OID in plpgsql's data structures, it fixes the active PLpgSQL_rec struct as well as the PLpgSQL_type struct it references. However, the latter is shared across f

pgsql: Fix possible loss of sync between rectypeid and underlying PLpgS

2019-12-26 Thread Tom Lane
Fix possible loss of sync between rectypeid and underlying PLpgSQL_type. When revalidate_rectypeid() acts to update a stale record type OID in plpgsql's data structures, it fixes the active PLpgSQL_rec struct as well as the PLpgSQL_type struct it references. However, the latter is shared across f

pgsql: Fix possible loss of sync between rectypeid and underlying PLpgS

2019-12-26 Thread Tom Lane
Fix possible loss of sync between rectypeid and underlying PLpgSQL_type. When revalidate_rectypeid() acts to update a stale record type OID in plpgsql's data structures, it fixes the active PLpgSQL_rec struct as well as the PLpgSQL_type struct it references. However, the latter is shared across f

Re: pgsql: Fix compiler warning for ppoll() on Cygwin

2019-12-26 Thread Andrew Dunstan
On Thu, Dec 26, 2019 at 4:12 PM Tom Lane wrote: > Peter Eisentraut writes: > > I think the config.cache of lorikeet needs to be cleaned, because the > > return type of strerror_r() has changed as a result of this commit, but > > the build farm logs still show the old test result being used from

pgsql: Revert "Rename files and headers related to index AM"

2019-12-26 Thread Michael Paquier
Revert "Rename files and headers related to index AM" This follows multiple complains from Peter Geoghegan, Andres Freund and Alvaro Herrera that this issue ought to be dug more before actually happening, if it happens. Discussion: https://postgr.es/m/[email protected] Branch

Re: pgsql: Rename files and headers related to index AM

2019-12-26 Thread Michael Paquier
On Thu, Dec 26, 2019 at 10:26:51AM -0800, Peter Geoghegan wrote: > On Thu, Dec 26, 2019 at 10:15 AM Andres Freund wrote: >> Yea, this seems like a much bigger move than warranted. Especially >> without a backward compat header put into place. Hm, I am not sure that it is actually that much used,

Re: pgsql: Fix compiler warning for ppoll() on Cygwin

2019-12-26 Thread Tom Lane
Andrew Dunstan writes: > On Thu, Dec 26, 2019 at 4:12 PM Tom Lane wrote: >> Next question is why the buildfarm client got that wrong. Seems like >> its accache logic needs to notice changes in src/template/* as well as >> the configure script proper. > The problem with that is that a change in

Re: pgsql: Fix compiler warning for ppoll() on Cygwin

2019-12-26 Thread Andrew Dunstan
On Fri, Dec 27, 2019 at 10:24 AM Tom Lane wrote: > > Andrew Dunstan writes: > > On Thu, Dec 26, 2019 at 4:12 PM Tom Lane wrote: > >> Next question is why the buildfarm client got that wrong. Seems like > >> its accache logic needs to notice changes in src/template/* as well as > >> the configur