pgsql: Small code simplification for REINDEX CONCURRENTLY

2019-03-29 Thread Peter Eisentraut
Small code simplification for REINDEX CONCURRENTLY This was left over from an earlier code structure. Branch -- master Details --- https://git.postgresql.org/pg/commitdiff/6b8b5364ddd0e4d882562615c6b6c28638ade9f2 Modified Files -- src/backend/commands/indexcmds.c | 10 +-

pgsql: doc: Small documentation review for REINDEX CONCURRENTLY

2019-03-29 Thread Peter Eisentraut
doc: Small documentation review for REINDEX CONCURRENTLY Author: Justin Pryzby Branch -- master Details --- https://git.postgresql.org/pg/commitdiff/173268f4d011fcae1f909c811e264baf6c838e7a Modified Files -- doc/src/sgml/ref/reindex.sgml | 24 1 file

pgsql: doc: Fix typo

2019-03-29 Thread Peter Eisentraut
doc: Fix typo Author: Bossart, Nathan Branch -- master Details --- https://git.postgresql.org/pg/commitdiff/0267629e1889b3e1e2e6b2f1b41e8993eff86a9b Modified Files -- doc/src/sgml/ref/reindex.sgml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)

pgsql: Tweak some nbtree-related code comments.

2019-03-29 Thread Peter Geoghegan
Tweak some nbtree-related code comments. Branch -- master Details --- https://git.postgresql.org/pg/commitdiff/9c7fb7e6d8d0fdcabbdc32daad2159812e538bd5 Modified Files -- contrib/amcheck/verify_nbtree.c | 2 +- src/backend/access/nbtree/nbtsearch.c | 3 ++- src/backend/a

Re: pgsql: Add support for multivariate MCV lists

2019-03-29 Thread Tomas Vondra
On Fri, Mar 29, 2019 at 12:06:26PM -0700, Peter Geoghegan wrote: On Fri, Mar 29, 2019 at 11:20 AM Tomas Vondra wrote: I've pushed a fix for this. The short version is that the serialized representation was not respecting memory alignment requirements, which was causing issues in machines sensit

Re: pgsql: Add support for multivariate MCV lists

2019-03-29 Thread Peter Geoghegan
On Fri, Mar 29, 2019 at 11:20 AM Tomas Vondra wrote: > I've pushed a fix for this. The short version is that the serialized > representation was not respecting memory alignment requirements, which was > causing issues in machines sensitive to this (ia64, sparc, hppa). It's a > blind attempt, as I

Re: pgsql: Add support for multivariate MCV lists

2019-03-29 Thread Tomas Vondra
On Thu, Mar 28, 2019 at 08:37:11PM +0100, Tomas Vondra wrote: On Thu, Mar 28, 2019 at 07:33:36PM +0100, Tomas Vondra wrote: On Thu, Mar 28, 2019 at 11:29:12AM -0700, Peter Geoghegan wrote: On Wed, Mar 27, 2019 at 6:27 PM Tomas Vondra wrote: It's a bit too late for pushing emergency fixes over

pgsql: Fix memory alignment in pg_mcv_list serialization

2019-03-29 Thread Tomas Vondra
Fix memory alignment in pg_mcv_list serialization Blind attempt at fixing ia64, hppa an sparc builds. The serialized representation of MCV lists did not enforce proper memory alignment for internal fields, resulting in deserialization issues on platforms that are more sensitive to this (ia64, spa

Re: pgsql: Compute XID horizon for page level index vacuum on primary.

2019-03-29 Thread Andres Freund
On 2019-03-29 16:20:54 +, Simon Riggs wrote: > On Fri, 29 Mar 2019 at 16:12, Andres Freund wrote: > > > > On 2019-03-29 15:58:14 +, Simon Riggs wrote: > > > On Fri, 29 Mar 2019 at 15:29, Andres Freund wrote: > > > > That's far from a trivial feature imo. It seems quite possible that > >

Re: pgsql: Compute XID horizon for page level index vacuum on primary.

2019-03-29 Thread Peter Geoghegan
On Fri, Mar 29, 2019 at 9:12 AM Andres Freund wrote: > But even so, you can't have unlogged changes that you then rely on. Even > if there's no torn page issue. Currently BTP_HAS_GARBAGE and > ItemIdMarkDead() are treated as hints - if we want to guarantee all > these are accurate, I don't quite

Re: pgsql: Compute XID horizon for page level index vacuum on primary.

2019-03-29 Thread Simon Riggs
On Fri, 29 Mar 2019 at 16:12, Andres Freund wrote: > On 2019-03-29 15:58:14 +, Simon Riggs wrote: > > On Fri, 29 Mar 2019 at 15:29, Andres Freund wrote: > > > That's far from a trivial feature imo. It seems quite possible that > we'd > > > end up with increased overhead, because the current

Re: pgsql: Compute XID horizon for page level index vacuum on primary.

2019-03-29 Thread Andres Freund
Hi, On 2019-03-29 15:58:14 +, Simon Riggs wrote: > On Fri, 29 Mar 2019 at 15:29, Andres Freund wrote: > > That's far from a trivial feature imo. It seems quite possible that we'd > > end up with increased overhead, because the current logic can get away > > with only doing hint bit style writ

pgsql: Show table access methods as such in psql's \dA.

2019-03-29 Thread Andres Freund
Show table access methods as such in psql's \dA. Previously we didn't display a type for table access methods. Author: Haribabu Kommi Discussion: CAJrrPGeeYOqP3hkZyohDx_8dot4zvPuPMDBmhJ=ic85ctbn...@mail.gmail.com Branch -- master Details --- https://git.postgresql.org/pg/commitdiff/d3a5

Re: pgsql: Compute XID horizon for page level index vacuum on primary.

2019-03-29 Thread Simon Riggs
On Fri, 29 Mar 2019 at 15:29, Andres Freund wrote: > On 2019-03-29 09:37:11 +, Simon Riggs wrote: > > > While trying to understand this, I see there is an even better way to > > optimize this. Since we are removing dead index tuples, we could alter > the > > killed index tuple interface so

pgsql: tableam: Comment fixes.

2019-03-29 Thread Andres Freund
tableam: Comment fixes. Author: Haribabu Kommi Discussion: CAJrrPGeeYOqP3hkZyohDx_8dot4zvPuPMDBmhJ=ic85ctbn...@mail.gmail.com Branch -- master Details --- https://git.postgresql.org/pg/commitdiff/ffa8444ce4828108e49d961cfa64e31078d978f0 Modified Files -- src/backend/access/h

Re: pgsql: Compute XID horizon for page level index vacuum on primary.

2019-03-29 Thread Andres Freund
Hi, On 2019-03-29 09:37:11 +, Simon Riggs wrote: > This commit message was quite confusing. It took me a while to realize this > relates to btree index deletes and that what you mean is that we are > calculcating the latestRemovedXid for index entries. That is related to but > not same thing a

pgsql: Reorganize Notes section in documentation of pg_checksums

2019-03-29 Thread Michael Paquier
Reorganize Notes section in documentation of pg_checksums This commit reorders the paragraphs of the Notes section in order of importance, and clarifies better the safe uses of pg_checksums for replication setups. Author: Fabien Coelho Discussion: https://postgr.es/m/alpine.DEB.2.21.1903231404280

pgsql: doc: Refine README.links further

2019-03-29 Thread Peter Eisentraut
doc: Refine README.links further suggested by Chapman Flack Branch -- master Details --- https://git.postgresql.org/pg/commitdiff/c0a2ff474a47216031d1835f5878fa4f445f44fe Modified Files -- doc/src/sgml/README.links | 10 +++--- 1 file changed, 7 insertions(+), 3 deletion

pgsql: Allow existing VACUUM options to take a Boolean argument.

2019-03-29 Thread Robert Haas
Allow existing VACUUM options to take a Boolean argument. This makes VACUUM work more like EXPLAIN already does without changing the meaning of any commands that already work. It is intended to facilitate the addition of future VACUUM options that may take non-Boolean parameters or that default t

pgsql: Warn more strongly about the dangers of exclusive backup mode.

2019-03-29 Thread Robert Haas
Warn more strongly about the dangers of exclusive backup mode. Especially, warn about the hazards of mishandling the backup_label file. Adjust a couple of server messages to be more clear about the hazards associated with removing backup_label files, too. David Steele and Robert Haas, reviewed b

pgsql: Fix incorrect code in new REINDEX CONCURRENTLY code

2019-03-29 Thread Peter Eisentraut
Fix incorrect code in new REINDEX CONCURRENTLY code The previous code was adding pointers to transient variables to a list, but by the time the list was read, the variable might be gone, depending on the compiler. Fix it by making copies in the proper memory context. Branch -- master Detail

Re: pgsql: Compute XID horizon for page level index vacuum on primary.

2019-03-29 Thread Simon Riggs
On Wed, 27 Mar 2019 at 00:06, Andres Freund wrote: > Compute XID horizon for page level index vacuum on primary. > > Previously the xid horizon was only computed during WAL replay. This commit message was quite confusing. It took me a while to realize this relates to btree index deletes and tha

Re: pgsql: REINDEX CONCURRENTLY

2019-03-29 Thread Michael Paquier
Hi Peter, On Fri, Mar 29, 2019 at 07:26:53AM +, Peter Eisentraut wrote: > REINDEX CONCURRENTLY > > This adds the CONCURRENTLY option to the REINDEX command. A REINDEX > CONCURRENTLY on a specific index creates a new index (like CREATE > INDEX CONCURRENTLY), then renames the old index away an

pgsql: REINDEX CONCURRENTLY

2019-03-29 Thread Peter Eisentraut
REINDEX CONCURRENTLY This adds the CONCURRENTLY option to the REINDEX command. A REINDEX CONCURRENTLY on a specific index creates a new index (like CREATE INDEX CONCURRENTLY), then renames the old index away and the new index in place and adjusts the dependencies, and then drops the old index (li