== PostgreSQL Weekly News - February 23, 2020 == - Mailing list pgsql-announce

From David Fetter
Subject == PostgreSQL Weekly News - February 23, 2020 ==
Date
Msg-id 20200223231050.GA6334@fetter.org
Whole thread Raw
List pgsql-announce
== PostgreSQL Weekly News - February 23, 2020 ==

PGConfNepal 2020 will be held April 17-18, 2020 at Kathmandu University, Dhulikhel,
Nepal.  The CfP is open until February 28, 2020 at https://pgconf.org.np/call-for-paper/
https://pgconf.org.np/

== PostgreSQL Product News ==

Pgpool-II 4.1.1, 4.0.8, 3.7.13, 3.6.20, 3.5.24 and pgpoolAdmin 4.1.0
http://www.pgpool.net/docs/latest/en/html/release.html
http://pgpool.net/mediawiki/index.php/Downloads

PostGIS 3.1.0, the industry standard geographic information system package
for PostgreSQL, released.
https://git.osgeo.org/gitea/postgis/postgis/src/tag/3.0.1/NEWS

pglogical 2.3, a logical-WAL-based replication system for PostgreSQL, released.
https://www.2ndquadrant.com/en/resources/pglogical/release-notes/

Joe bot 0.5.0, a Slack chatbot that helps backend developers and DBAs troubleshoot
and optimize PostgreSQL queries, releaesd.
https://gitlab.com/postgres-ai/joe/-/releases#0.5.0

pg_partman 4.3.0, a management system for partitioned tables, released.
https://github.com/pgpartman/pg_partman

postgres-checkup 1.4.0, a tool that automates detailed health checks of
PostgreSQL clusters, released.
https://gitlab.com/postgres-ai/postgres-checkup/-/releases

wal2json 2.2, a JSON output plugin for changeset extraction, released. As this
release fixes important bugs in PostgreSQL 9.4 and 9.5, it would be good to
upgrade ASAP.
https://github.com/eulerto/wal2json/releases

== PostgreSQL Jobs for February ==

http://archives.postgresql.org/pgsql-jobs/2020-02/

== PostgreSQL Local ==

pgDay Israel 2020 will take place on March 19, 2020 in Tel Aviv.
http://pgday.org.il/

pgDay Paris 2020 will be held in Paris, France on March 26, 2020 at Espace
Saint-Martin.
https://2020.pgday.paris/

Nordic PGDay 2020 will be held in Helsinki, Finland at the Hilton Helsinki
Strand Hotel on March 24, 2020.

PGConf India 2020 will be on February 26-28, 2020 in Bengaluru, Karnataka.
http://pgconf.in/

PostgreSQL@SCaLE is a two day, two track event which takes place on
March 5-6, 2020, at Pasadena Convention Center, as part of SCaLE 18X.
https://www.socallinuxexpo.org/scale/18x/postgresscale

The German-speaking PostgreSQL Conference 2020 will take place on May 15, 2019
in Stuttgart.

PGCon 2020 will take place in Ottawa on May 26-29, 2020.
https://www.pgcon.org/2020/

PGDay.IT 2020 will take place June 11-12 in Bergamo, Italy.
https://2020.pgday.it/en/

Swiss PGDay 2020 will take place in Rapperswil (near Zurich) on June 18-19, 2020.
The Call for Speakers is open through March 17, 2020.
https://www.pgday.ch/2020/

PostgresLondon 2020 will be July 7-8, 2020 with an optional training day on
July 6. The CfP is open at https://forms.gle/5m8ybUt9YDZG4gVU7 through March
27, 2020.
http://postgreslondon.org

PG Day Russia will be in Saint Petersburg on July 10, 2020. The CfP is open at
https://pgday.ru/en/2020/for-speakers through April 6, 2020.
https://pgday.ru/en/2020/

FOSS4G 2020, will take place in Calgary, Alberta, Canada August 24-29 2020.
the Call for Papers is currently open at https://2020.foss4g.org/speakers/
https://2020.foss4g.org/

Austrian pgDay will take place September 18, 2020 at Schloss Schoenbrunn
(Apothekertrakt) in Vienna. The CfP is open until April 19, 2020 at
https://pgday.at/en/talk-commitee/
https://pgday.at/en/

== PostgreSQL in the News ==

Planet PostgreSQL: http://planet.postgresql.org/

PostgreSQL Weekly News is brought to you this week by David Fetter

Submit news and announcements by Sunday at 3:00pm PST8PDT to david@fetter.org.

== Applied Patches ==

Fujii Masao pushed:

- Add description about LogicalRewriteTruncate wait event into document.
  Back-patch to v10 where commit 249cf070e3 introduced LogicalRewriteTruncate
  wait event.  Author: Fujii Masao Reviewed-by: Michael Paquier Discussion:
  https://postgr.es/m/949931aa-4ed4-d867-a7b5-de9c02b2292b@oss.nttdata.com
  https://git.postgresql.org/pg/commitdiff/e593148d43adb8ef1721ccd987046c02f4532920

- Add description about GSSOpenServer wait event into document. This commit also
  updates wait event enum into alphabetical order. Previously the enum entry for
  GSSOpenServer was added out-of-order.  Back-patch to v12 where commit
  b0b39f72b9 introduced GSSOpenServer wait event. In v12, the commit doesn't
  include the update of wait event enum, not to break ABI.  Author: Fujii Masao
  Reviewed-by: Michael Paquier Discussion:
  https://postgr.es/m/949931aa-4ed4-d867-a7b5-de9c02b2292b@oss.nttdata.com
  https://git.postgresql.org/pg/commitdiff/f4ae7221413d5176e4d5a49883217ea87312104a

- Make inherited LOCK TABLE perform access permission checks on parent table
  only. Previously, LOCK TABLE command through a parent table checked the
  permissions on not only the parent table but also the children tables
  inherited from it. This was a bug and inherited queries should perform access
  permission checks on the parent table only. This commit fixes LOCK TABLE so
  that it does not check the permission on children tables.  This patch is
  applied only in the master branch. We decided not to back-patch because it's
  not hard to imagine that there are some applications expecting the old
  behavior and the change breaks their security.  Author: Amit Langote
  Reviewed-by: Fujii Masao Discussion:
  https://postgr.es/m/CAHGQGwE+GauyG7POtRfRwwthAGwTjPQYdFHR97+LzA4RHGnJxA@mail.gmail.com
  https://git.postgresql.org/pg/commitdiff/b7e51b350c4e6b1cb3404588cf11801525e2336f

- Fix mesurement of elapsed time during truncating heap in VACUUM. VACUUM may
  truncate heap in several batches. The activity report is logged for each
  batch, and contains the number of pages in the table before and after the
  truncation, and also the elapsed time during the truncation. Previously the
  elapsed time reported in each batch was the total elapsed time since starting
  the truncation until finishing each batch. For example, if the truncation was
  processed dividing into three batches, the second batch reported the
  accumulated time elapsed during both first and second batches. This is strange
  and confusing because the number of pages in the table reported together is
  not total. Instead, each batch should report the time elapsed during only that
  batch.  The cause of this issue was that the resource usage snapshot was
  initialized only at the beginning of the truncation and was never reset later.
  This commit fixes the issue by changing VACUUM so that the resource usage
  snapshot is reset at each batch.  Back-patch to all supported branches.
  Reported-by: Tatsuhito Kasahara Author: Tatsuhito Kasahara Reviewed-by:
  Masahiko Sawada, Fujii Masao Discussion:
  https://postgr.es/m/CAP0=ZVJsf=NvQuy+QXQZ7B=ZVLoDV_JzsVC1FRsF1G18i3zMGg@mail.gmail.com
  https://git.postgresql.org/pg/commitdiff/007491979461ff10d487e1da9bcc87f2fd834f26

Peter Eisentraut pushed:

- Fill in extraUpdatedCols in logical replication. The extraUpdatedCols field of
  the target RTE records which generated columns are affected by an update.
  This is used in a variety of places, including per-column triggers and foreign
  data wrappers.  When an update was initiated by a logical replication
  subscription, this field was not filled in, so such an update would not affect
  generated columns in a way that is consistent with normal updates.  To fix,
  factor out some code from analyze.c to fill in extraUpdatedCols in the logical
  replication worker as well.  Reviewed-by: Pavel Stehule
  <pavel.stehule@gmail.com> Discussion:
  https://www.postgresql.org/message-id/flat/b05e781a-fa16-6b52-6738-761181204567@2ndquadrant.com
  https://git.postgresql.org/pg/commitdiff/ad3ae64770e5b4391ad07fb2a689d72aa45b4689

- Optimize update of tables with generated columns. When updating a table row
  with generated columns, only recompute those generated columns whose base
  columns have changed in this update and keep the rest unchanged.  This can
  result in a significant performance benefit.  The required information was
  already kept in RangeTblEntry.extraUpdatedCols; we just have to make use of
  it.  Reviewed-by: Pavel Stehule <pavel.stehule@gmail.com> Discussion:
  https://www.postgresql.org/message-id/flat/b05e781a-fa16-6b52-6738-761181204567@2ndquadrant.com
  https://git.postgresql.org/pg/commitdiff/c6679e4fca21d253ced84c51ac1a31c1b2aec72f

- Set gen_random_uuid() to volatile. It was set to immutable.  This was a
  mistake in the initial commit (5925e5549890416bcf588334d9d0bc99f8ad6c7f).
  Reported-by: hubert depesz lubaczewski <depesz@depesz.com> Discussion:
  https://www.postgresql.org/message-id/flat/20200218185452.GA8710%40depesz.com
  https://git.postgresql.org/pg/commitdiff/2ed19a488edb3980e054e6064e7028ccb652e5df

- Fix typo. Reported-by: Daniel Verite <daniel@manitou-mail.org>
  https://git.postgresql.org/pg/commitdiff/2f9c46a32b43d72c9384378827ee51fde896807c

- Require stdint.h. stdint.h belongs to the compiler (as opposed to inttypes.h),
  so by requiring a C99 compiler we can also require stdint.h unconditionally.
  Remove configure checks and other workarounds for it.  This also removes a few
  steps in the required portability adjustments to the imported time zone code,
  which can be applied on the next import.  When using GCC on a platform that is
  otherwise pre-C99, this will now require at least GCC 4.5, which is the first
  release that supplied a standard-conforming stdint.h if the native platform
  didn't have it.  Reviewed-by: Tom Lane <tgl@sss.pgh.pa.us> Discussion:
  https://www.postgresql.org/message-id/flat/5d398bbb-262a-5fed-d839-d0e5cff3c0d7%402ndquadrant.com
  https://git.postgresql.org/pg/commitdiff/957338418b69e9774ccc1bab59f765a62f0aa6f9

- Fix compiler warnings on 64-bit Windows. GCC reports various instances of
  warning: cast to pointer from integer of different size
  [-Wint-to-pointer-cast] warning: cast from pointer to integer of different
  size [-Wpointer-to-int-cast]  and MSVC equivalently  warning C4312: 'type
  cast': conversion from 'int' to 'void *' of greater size warning C4311: 'type
  cast': pointer truncation from 'void *' to 'long'  in ECPG test files.  This
  is because void* and long are cast back and forth, but on 64-bit Windows,
  these have different sizes.  Fix by using intptr_t instead.  The code actually
  worked fine because the integer values in use are all small.  So this is just
  to get the test code to compile warning-free.  This change is simplified by
  having made stdint.h required (commit
  957338418b69e9774ccc1bab59f765a62f0aa6f9).  Before this it would have been
  more complicated because the ecpg test source files don't use the full
  pg_config.h.  Reviewed-by: Tom Lane <tgl@sss.pgh.pa.us> Discussion:
  https://www.postgresql.org/message-id/flat/5d398bbb-262a-5fed-d839-d0e5cff3c0d7%402ndquadrant.com
  https://git.postgresql.org/pg/commitdiff/3f9c1697dca0b4964f1f5ba624d361d4e0e53051

- Allow running src/tools/msvc/mkvcbuild.pl under not Windows. This to allow
  verifying the MSVC build file generation without having to have Windows.  To
  do this, we avoid Windows-specific Perl modules and don't run the "cl"
  compiler or "nmake".  The resulting build files won't actually be completely
  correct, but it's useful enough.  Reviewed-by: Michael Paquier
  <michael@paquier.xyz> Reviewed-by: Julien Rouhaud <rjuju123@gmail.com>
  Discussion:
  https://www.postgresql.org/message-id/flat/d73b2c7b-f081-8357-8422-7564d55f1aac%402ndquadrant.com
  https://git.postgresql.org/pg/commitdiff/73c8596488fd5fd619991f56dae5d22f551b06d9

- Fix perlcritic warnings.
  https://git.postgresql.org/pg/commitdiff/b24e125696a94b6ebdd2262c0c41bf45cbeba23f

- Factor out InitControlFile() from BootStrapXLOG(). Right now this only makes
  BootStrapXLOG() a bit more manageable, but in the future there may be external
  callers.  Discussion:
  https://www.postgresql.org/message-id/e8f86ba5-48f1-a80a-7f1d-b76bcb9c5c47@2ndquadrant.com
  https://git.postgresql.org/pg/commitdiff/79c2385915dd4aa43127e766c3dce323ec562ba0

- Reformat code comment. Discussion:
  https://www.postgresql.org/message-id/e8f86ba5-48f1-a80a-7f1d-b76bcb9c5c47@2ndquadrant.com
  https://git.postgresql.org/pg/commitdiff/9745f93afc56829f9cf10ca3e43a29f0b4409fe3

- pg_resetwal: Rename function to avoid potential conflict. ReadControlFile()
  here conflicts with a function of the same name in xlog.c.  There is no actual
  conflict right now, but since pg_resetwal.c reaches deep inside backend
  headers, it's possible in the future.  Discussion:
  https://www.postgresql.org/message-id/e8f86ba5-48f1-a80a-7f1d-b76bcb9c5c47@2ndquadrant.com
  https://git.postgresql.org/pg/commitdiff/5f1b8260af961ddf05968c9c3e7f178a3ad5d2ea

Tom Lane pushed:

- Teach pg_dump to dump comments on RLS policy objects. This was unaccountably
  omitted in the original RLS patch. The SQL syntax is basically the same as for
  comments on triggers, so crib code from dumpTrigger().  Per report from Marc
  Munro.  Back-patch to all supported branches.  Discussion:
  https://postgr.es/m/1581889298.18009.15.camel@bloodnok.com
  https://git.postgresql.org/pg/commitdiff/f31364676dfd9e7a2b712ea0da7b4ab6b7d28f5e

- Fix confusion about event trigger vs. plain function in plpgsql. The function
  hash table keys made by compute_function_hashkey() failed to distinguish
  event-trigger call context from regular call context. This meant that once
  we'd successfully made a hash entry for an event trigger (either by
  validation, or by normal use as an event trigger), an attempt to call the
  trigger function as a plain function would find this hash entry and thereby
  bypass the you-can't-do-that check in do_compile().  Thus we'd attempt to
  execute the function, leading to strange errors or even crashes, depending on
  function contents and server version.  To fix, add an isEventTrigger field to
  PLpgSQL_func_hashkey, paralleling the longstanding infrastructure for regular
  triggers. This fits into what had been pad space, so there's no risk of an ABI
  break, even assuming that any third-party code is looking at these hash keys.
  (I considered replacing isTrigger with a PLpgSQL_trigtype enum field, but felt
  that that carried some API/ABI risk.  Maybe we should change it in HEAD
  though.)  Per bug #16266 from Alexander Lakhin.  This has been broken since
  event triggers were invented, so back-patch to all supported branches.
  Discussion: https://postgr.es/m/16266-fcd7f838e97ba5d4@postgresql.org
  https://git.postgresql.org/pg/commitdiff/761a5688b179d46091e7314458571c5fc537084a

- Remove support for upgrading extensions from "unpackaged" state. Andres Freund
  pointed out that allowing non-superusers to run "CREATE EXTENSION ... FROM
  unpackaged" has security risks, since the unpackaged-to-1.0 scripts don't try
  to verify that the existing objects they're modifying are what they expect.
  Just attaching such objects to an extension doesn't seem too dangerous, but
  some of them do more than that.  We could have resolved this, perhaps, by
  still requiring superuser privilege to use the FROM option.  However, it's
  fair to ask just what we're accomplishing by continuing to lug the
  unpackaged-to-1.0 scripts forward.  None of them have received any real
  testing since 9.1 days, so they may not even work anymore (even assuming that
  one could still load the previous "loose" object definitions into a v13
  database). And an installation that's trying to go from pre-9.1 to v13 or
  later in one jump is going to have worse compatibility problems than whether
  there's a trivial way to convert their contrib modules into extension style.
  Hence, let's just drop both those scripts and the core-code support for
  "CREATE EXTENSION ... FROM".  Discussion:
  https://postgr.es/m/20200213233015.r6rnubcvl4egdh5r@alap3.anarazel.de
  https://git.postgresql.org/pg/commitdiff/70a7732007bc4689f4c7a44e738eb2d892dac1e3

- Doc: discourage use of partial indexes for poor-man's-partitioning. Creating a
  bunch of non-overlapping partial indexes is generally a bad idea, so add an
  example saying not to do that.  Back-patch to v10.  Before that, the
  alternative of using (real) partitioning wasn't available, so that the
  tradeoff isn't quite so clear cut.  Discussion:
  https://postgr.es/m/CAKVFrvFY-f7kgwMRMiPLbPYMmgjc8Y2jjUGK_Y0HVcYAmU6ymg@mail.gmail.com
  https://git.postgresql.org/pg/commitdiff/6a8e5605b53561464c53006337596699f41b1de2

- Assume that we have utime() and <utime.h>. These are required by POSIX since
  SUSv2, and no live platforms fail to provide them.  On Windows, utime() exists
  and we bring our own <utime.h>, so we're good there too.  So remove the
  configure probes and ad-hoc substitute code.  We don't need to check for
  utimes() anymore either, since that was only used as a substitute.  In
  passing, make the Windows build include <sys/utime.h> only where we need it,
  not everywhere.  This is part of a series of commits to get rid of
  no-longer-relevant configure checks and dead src/port/ code.  I'm committing
  them separately to make it easier to back out individual changes if they prove
  less portable than I expect.  Discussion:
  https://postgr.es/m/15379.1582221614@sss.pgh.pa.us
  https://git.postgresql.org/pg/commitdiff/481c8e9232386e289fbd3e8f75893ae8d9814298

- Assume that we have <wchar.h>. Windows has this, and so do all other live
  platforms according to the buildfarm; it's been required by POSIX since SUSv2.
  So remove the configure probe and tests of HAVE_WCHAR_H.  This is part of a
  series of commits to get rid of no-longer-relevant configure checks and dead
  src/port/ code.  I'm committing them separately to make it easier to back out
  individual changes if they prove less portable than I expect.  Discussion:
  https://postgr.es/m/15379.1582221614@sss.pgh.pa.us
  https://git.postgresql.org/pg/commitdiff/97cf1fa4ed57cc1ed556ac4f827e7df8538f2d29

- Assume that we have isinf(). Windows has this, and so do all other live
  platforms according to the buildfarm, so remove the configure probe and
  src/port/ substitution.  This also lets us get rid of some configure probes
  that existed only to support src/port/isinf.c.  I kept the port.h hack to
  force using __builtin_isinf() on clang, though.  This is part of a series of
  commits to get rid of no-longer-relevant configure checks and dead src/port/
  code.  I'm committing them separately to make it easier to back out individual
  changes if they prove less portable than I expect.  Discussion:
  https://postgr.es/m/15379.1582221614@sss.pgh.pa.us
  https://git.postgresql.org/pg/commitdiff/7fde892bc191e4df9fcd52ce11d1502673498d97

- Assume that we have memmove(). Windows has this, and so do all other live
  platforms according to the buildfarm, so remove the configure probe and c.h's
  substitute code.  This is part of a series of commits to get rid of
  no-longer-relevant configure checks and dead src/port/ code.  I'm committing
  them separately to make it easier to back out individual changes if they prove
  less portable than I expect.  Discussion:
  https://postgr.es/m/15379.1582221614@sss.pgh.pa.us
  https://git.postgresql.org/pg/commitdiff/1200d71a09177b7e64167df440d0c9bd16111ebe

- Assume that we have cbrt(). Windows has this, and so do all other live
  platforms according to the buildfarm, so remove the configure probe and
  float.c's substitute code.  This is part of a series of commits to get rid of
  no-longer-relevant configure checks and dead src/port/ code.  I'm committing
  them separately to make it easier to back out individual changes if they prove
  less portable than I expect.  Discussion:
  https://postgr.es/m/15379.1582221614@sss.pgh.pa.us
  https://git.postgresql.org/pg/commitdiff/abe41f453a5c42129e21825d75450aced0053eb8

- Assume that we have rint(). Windows has this since _MSC_VER >= 1200, and so do
  all other live platforms according to the buildfarm, so remove the configure
  probe and src/port/ substitution.  This is part of a series of commits to get
  rid of no-longer-relevant configure checks and dead src/port/ code.  I'm
  committing them separately to make it easier to back out individual changes if
  they prove less portable than I expect.  Discussion:
  https://postgr.es/m/15379.1582221614@sss.pgh.pa.us
  https://git.postgresql.org/pg/commitdiff/f88a058200a40032e88a8bfc1aea453c22d2dcb0

- Assume that we have functional, 64-bit fseeko()/ftello(). Windows has this,
  and so do all other live platforms according to the buildfarm, so remove the
  configure probe and src/port/ substitution.  Keep the probe that detects
  whether _LARGEFILE_SOURCE has to be defined to get that, though ... that seems
  to be still relevant in some places.  This is part of a series of commits to
  get rid of no-longer-relevant configure checks and dead src/port/ code.  I'm
  committing them separately to make it easier to back out individual changes if
  they prove less portable than I expect.  Discussion:
  https://postgr.es/m/15379.1582221614@sss.pgh.pa.us
  https://git.postgresql.org/pg/commitdiff/799d22461a932aace890d61a82186e0d64de0ee8

- Assume that we have signed integral types and flexible array members. These
  compiler features are required by C99, so remove the configure probes for
  them.  This is part of a series of commits to get rid of no-longer-relevant
  configure checks and dead src/port/ code.  I'm committing them separately to
  make it easier to back out individual changes if they prove less portable than
  I expect.  Discussion: https://postgr.es/m/15379.1582221614@sss.pgh.pa.us
  https://git.postgresql.org/pg/commitdiff/f4d59369d2ddf0ad7850112752ec42fd115825d4

- Adjust Solution.pm to set HAVE_STDINT_H. We're not testing that anywhere
  anymore, but for consistency, it should get defined.
  https://git.postgresql.org/pg/commitdiff/ec4a7851d5914bbdc5b65175e2489ec19020217e

Michaël Paquier pushed:

- Fix grammar in monitoring.sgml. This is related to progress reporting for
  ANALYZE and partitioned tables.  Author: Amit Langote Reviewed-by: Daniel
  Gustafsson, Julien Rouhaud Discussion:
  https://postgr.es/m/CA+HiwqGx6C=-bFTX=ryMThyvM7CcSC3b1x8_6zh4Uo41Kvu-zw@mail.gmail.com
  https://git.postgresql.org/pg/commitdiff/ddfc3c1499b05956094a7f219fe2b6ac0c9ce5eb

- Remove duplicated words in comments. Author: Daniel Gustafsson Reviewed-by:
  Vik Fearing Discussion:
  https://postgr.es/m/EBC3BFEB-664C-4063-81ED-29F1227DB012@yesql.se
  https://git.postgresql.org/pg/commitdiff/958f9fb98da97a1d781a3766ea86bcdba3b216c5

- Clean up some code, comments and docs referring to Windows 2000 and older.
  This fixes and updates a couple of comments related to outdated Windows
  versions.  Particularly, src/common/exec.c had a fallback implementation to
  read a file's line from a pipe because stdin/stdout/stderr does not exist in
  Windows 2000 that is removed to simplify src/common/ as there are unlikely
  versions of Postgres running on such platforms.  Author: Michael Paquier
  Reviewed-by: Kyotaro Horiguchi, Juan José Santamaría Flecha Discussion:
  https://postgr.es/m/20191219021526.GC4202@paquier.xyz
  https://git.postgresql.org/pg/commitdiff/e2e02191e23379502a38a6b0436ab7f41b2efc08

- Cleanup more code related to ws2_32.dll loading in src/port/getaddrinfo.c.
  e2e0219 has removed a code path for Windows 2000 that attempts to load
  wship6.dll as fallback if ws2_32.dll is found but not getaddrinfo(), leaving
  behind a dangling pointer as the library is freed.  However, there is no point
  in this check as ws2_32.dll exists since Windows XP, so just remove the
  duplicated check.  Reported-by: Tom Lane Discussion:
  https://postgr.es/m/9781.1582146114@sss.pgh.pa.us
  https://git.postgresql.org/pg/commitdiff/d55e9ae2633ee462d554dddc08d640d725dd6494

- Doc: Fix instructions to control build environment with MSVC. The
  documentation included some outdated instructions to change the architecture,
  build type or target OS of a build done with MSVC.  This commit updates the
  documentation to include the modern options available, down to Visual Studio
  2013.  Reported-by: Kyotaro Horiguchi Author: Juan José Santamaría Flecha
  Discussion:
  https://postgr.es/m/CAC+AXB0J7tAqW_2F1fCE4Dh2=Ccz96TcLpsGXOCvka7VvWG9Qw@mail.gmail.com
  Backpatch-through: 12
  https://git.postgresql.org/pg/commitdiff/dca3911a81f0ba823b56c3d4462419c83f385e55

Peter Geoghegan pushed:

- Remove obsolete _bt_compare() comment. btbuild() has nothing to say about how
  NULL values compare in nbtree. Besides, there are _bt_compare() header
  comments that describe how NULL values are handled.
  https://git.postgresql.org/pg/commitdiff/fe9b92854e7d5f66d3abb565c5b60a879b6c9442

Amit Kapila pushed:

- Stop demanding that top xact must be seen before subxact in decoding.
  Manifested as  ERROR:  subtransaction logged without previous top-level txn
  record  this check forbids legit behaviours like  - First xl_xact_assignment
  record is beyond reading, i.e. earlier    restart_lsn.  - After restart_lsn
  there is some change of a subxact.  - After that, there is second
  xl_xact_assignment (for another subxact)    revealing the relationship between
  top and first subxact.  Such a transaction won't be streamed anyway because we
  hadn't seen it in full.  Saying for sure whether xact of some record
  encountered after the snapshot was deserialized can be streamed or not
  requires to know whether it wrote something before deserialization point --if
  yes, it hasn't been seen in full and can't be decoded. Snapshot doesn't have
  such info, so there is no easy way to relax the check.  Reported-by: Hsu, John
  Diagnosed-by: Arseny Sher Author: Arseny Sher, Amit Kapila Reviewed-by: Amit
  Kapila, Dilip Kumar Backpatch-through: 9.5 Discussion:
  https://postgr.es/m/AB5978B2-1772-4FEE-A245-74C91704ECB0@amazon.com
  https://git.postgresql.org/pg/commitdiff/e3ff789acfb2754cd7b5e87f6f4463fd08e35996

Jeff Davis pushed:

- logtape.c: allocate read buffer even for an empty tape. Prior to this commit,
  the read buffer was allocated at the time the tape was rewound; but as an
  optimization, would not be allocated at all if the tape was empty.  That
  optimization meant that it was valid to have a rewound tape with the buffer
  set to NULL, but only if a number of conditions were met and only if the API
  was used properly. After 7fdd919a refactored the code to support
  lazily-allocating the buffer, Coverity started complaining.  The optimization
  for empty tapes doesn't seem important, so just allocate the buffer whether
  the tape has any data or not.  Discussion:
  https://postgr.es/m/20351.1581868306%40sss.pgh.pa.us
  https://git.postgresql.org/pg/commitdiff/8021985d791902a9eeda51acdede759fbc67ae01

- Minor refactor of nodeAgg.c.   * Separate calculation of hash value from the
  lookup.   * Split build_hash_table() into two functions.   * Change
  lookup_hash_entry() to return AggStatePerGroup. That's all     the caller
  needed, anyway.  These changes are to support the upcoming Disk-based Hash
  Aggregation work.  Discussion:
  https://postgr.es/m/31f5ab871a3ad5a1a91a7a797651f20e77ac7ce3.camel%40j-davis.com
  https://git.postgresql.org/pg/commitdiff/5b618e1f48aecc66e3a9f60289491da520faae19

- Fixup for nodeAgg.c refactor. Commit 5b618e1f made an unintended behavior
  change.
  https://git.postgresql.org/pg/commitdiff/b7fabe80df9a65010bfe5e5d0a979bacebfec382

Etsuro Fujita pushed:

- Remove extra word from comment.
  https://git.postgresql.org/pg/commitdiff/53b01acd463d64c385db0ab728b8cc336549a315

- Avoid redundant checks in partition_bounds_copy(). Previously,
  partition_bounds_copy() checked whether the strategy for the given partition
  bounds was hash or not, and then determined the number of elements in the
  datums in the datums array for the partition bounds, on each iteration of the
  loop for copying the datums array, but there is no need to do that.  Perform
  the checks only once before the loop iteration.  Author: Etsuro Fujita
  Reported-by: Amit Langote and Julien Rouhaud Discussion:
  https://postgr.es/m/CAPmGK14Rvxrm8DHWvCjdoks6nwZuHBPvMnWZ6rkEx2KhFeEoPQ@mail.gmail.com
  https://git.postgresql.org/pg/commitdiff/032f9ae012d87c730be0e261a6bae9323c2b2d6c

Álvaro Herrera pushed:

- Simplify FK-to-partitioned regression test query. Avoid a join between
  relations having the FK to detect FK violation. The planner might optimize
  this considering the PK must exist on the referenced side at some point,
  effectively masking a bug this test tries to detect.  Tom Lane and
  Jehan-Guillaume de Rorthais Discussion:
  https://postgr.es/m/467.1581270529@sss.pgh.pa.us
  https://git.postgresql.org/pg/commitdiff/b2304a71748a3e664a1b8354d746f28c38aaa816

== Pending Patches ==

Surafel Temesgen sent in two more revisions of a patch to enable conflict
handling in COPY ... FROM ...

Asif Rehman sent in another revision of a patch to document parallel backup.

Dmitry Dolgov sent in another revision of a patch to implement index skip scans.

Álvaro Herrera sent in two more revisions of a patch to fix ALTER ... DEPENDS ON
EXTENSION ...

Sergei Kornilov and Michaël Paquier traded patches to make wal_receiver create a
temporary replication slot.

Amit Langote sent in a patch to change an "on" to an "in" in the documentation
of progress reporting.

Fujii Masao sent in another revision of a patch to ensure that wait events are
reported while waiting for WAL archiving to finish.

Álvaro Herrera sent in a patch to record parents of triggers in pg_trigger.

Kasahara Tatsuhito sent in two more revisions of a patch to make a small
improvement of the elapsed time for truncating heap in vacuum.

Fujii Masao sent in two more revisions of a patch to add
pg_stat_progress_basebackup, which reports progress for pg_basebackup, on the
server side.

Justin Pryzby sent in three more revisions of a patch to make vacuum errcontext
show the block being processed and adds a callback for truncation.

David Zhang sent in another revision of a patch to fix psql to report IO errors
on writing query results.

Alexander Korotkov sent in two more revisions of a patch to improve checking for
missing parent links by traversing from one downlink to subsequent using
rightlinks instead of collecting a lossy bitmap.

Andrew Dunstan sent in another revision of a patch to add an SSL passphrase
callback.

Hubert Zhang sent in another revision of a patch to print the physical file path
when verifying a checksum fails.

Amit Langote sent in five revisions of a patch to reduce the plan cache overhead
on plpgsql expressions.

Kyotaro HORIGUCHI sent in a patch to fix some misbehaviors for repeated builds
on Windows.

Jeff Davis sent in three more revisions of a patch to implement memory-bounded
hash aggregation.

David Zhang sent in another revision of a patch to add a Fastpath while
arranging the changes in LSN order in logical decoding.

Masahiko Sawada sent in another revision of a patch to fix some issues in
copy_slot.

Fujii Masao sent in another revision of a patch to fix the descriptions of
RecoveryWalAll and RecoveryWalStream wait events.

Hamid Akhtar sent in a patch to throw warnings when an autovacuum worker
encounters an orphaned prepared transaction and when a vacuum command is issued.
It also introduces two new GUCs: max_age_prepared_xacts, and
prepared_xacts_vacuum_warn_timeout.

Fujii Masao sent in a patch to regularize the size of password client utilities
allow.

Ildar Musin and Amit Langote traded patches to fix an issue where NO INHERIT was
ignored in CREATE TABLE LIKE.

Kyotaro HORIGUCHI sent in a patch to fix an issue where pg_regress cleans up
a tablespace twice.

Mark Dilger sent in two more revisions of a patch to turn Portal->commandTag
into an enum.

Juan José Santamaría Flecha sent in another revision of a patch to fix the
output colors on Windows.

Justin Pryzby sent in another revision of a patch to make explain HashAggregate
report bucket and memory stats.

Noah Misch and Kyotaro HORIGUCHI traded patches to fix the WAL-skipping feature.

Michaël Paquier and Bernd Helmle traded patches to make scanning pg_tblspc more
robust.

Soumyadeep Chakraborty sent in another revision of a patch to Resolve PL handler
names for JITed code instead of using const pointers.

Thomas Munro sent in a WIP patch to add infrastruction for hardware transactional
memory and use same to implement serializable snapshot isolation.

Kirill Bychik sent in another revision of a patch to calculate WAL usage.

Fabrízio de Royes Mello sent in another revision of a patch to fix an infelicity
between parallel pg_restore and event triggers.

Andres Freund sent in a PoC patch to improve heavyweight locks so they can be
used more generally.

Peter Eisentraut sent in another revision of a patch to change client-side
fsync_fname() to report errors fatally.

Álvaro Herrera sent in another revision of a patch to add uri percent-encoding
for binary data.

Yuzuko Hosoya and Amit Kapila traded patches to fix an infelicity between
autovacuum and partitioned tables.

Etsuro Fujita sent in a patch to partition_bounds_copy() to move the setting of
the hash_part and natts variables outside a loop, making it more efficient.

Michaël Paquier and Bernd Helmle traded patches to make pg_checksums skip
foreign tablespace directories.

Peter Eisentraut sent in another revision of a patch to add the optiono to
include the backend type in log_line_prefix.

Zeng Wenjing sent in another revision of a patch to implement global temporary
tables.

Ants Aasma sent in a PoC patch to use SIMD instructions to make COPY ... FROM
... CSV more efficient.

Masahiko Sawada sent in another revision of a patch to support atomic commit
among multiple foreign servers.

John Dent sent in another revision of a patch to implement UNNEST for
REFCURSORs.

Julien Rouhaud sent in two more revisions of a patch to avoid reindexing invalid
indexes on TOAST tables.

Alexander Korotkov sent in another revision of a patch to add a
pg_shmem_init_time() function returning the shmem initialization time.

Daniel Gustafsson sent in a patch to fix a bug in a previous patch to use
heap_multi_insert() for pg_attribute/depend insertions.

Tom Lane sent in a patch to account honestly for external FD usage.



pgsql-announce by date:

Previous
From: Darafei "Komяpa" Praliaskouski
Date:
Subject: PostGIS 3.0.1 released
Next
From: Nikolay Samokhvalov
Date:
Subject: Joe, an SQL optimization bot