Re: COPY FREEZE and setting PD_ALL_VISIBLE/visibility map bits

Darafei Komяpa Praliaskouski <me@komzpa.net>

From: Darafei Praliaskouski <me@komzpa.net>
To: pgsql-hackers@lists.postgresql.org
Cc: Pavan Deolasee <pavan.deolasee@gmail.com>
Date: 2019-03-21T14:45:23Z
Lists: pgsql-hackers
The following review has been posted through the commitfest application:
make installcheck-world:  not tested
Implements feature:       not tested
Spec compliant:           not tested
Documentation:            not tested

This patch is particularly helpful in processing OpenStreetMap Data in PostGIS.
OpenStreetMap is imported as a stream of 300-900 (depending on settings) gigabytes, that are needing a VACUUM after a COPY FREEZE.
With this patch, the first and usually the last transforming query is performed much faster after initial load.

I have read this patch and have no outstanding comments on it.
Pavan Deolasee demonstrates the expected speed improvement.

The new status of this patch is: Ready for Committer

Commits

  1. Fix COPY FREEZE with CLOBBER_CACHE_ALWAYS

  2. Set PD_ALL_VISIBLE and visibility map bits in COPY FREEZE

  3. docs: client certificates are always sent to the server

  4. Mark commit and abort WAL records with XLR_SPECIAL_REL_UPDATE.

  5. docs: land height is "elevation", not "altitude"

  6. Improve the internal implementation of ereport().