pgsql: Remove unnecessary Windows-specific basebackup code.

From: Thomas Munro <tmunro(at)postgresql(dot)org>
To: pgsql-committers(at)lists(dot)postgresql(dot)org
Subject: pgsql: Remove unnecessary Windows-specific basebackup code.
Date: 2022-07-22 05:43:31
Message-ID: E1oElRi-000gjc-0j@gemulon.postgresql.org
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-committers

Remove unnecessary Windows-specific basebackup code.

Commit c6f2f016 added an explicit check for a Windows "junction point".
That turned out to be needed only because get_dirent_type() was busted
on Windows. It's been fixed by commit 9d3444dc, so remove it.

Add a TAP-test to demonstrate that in-place tablespaces are copied by
pg_basebackup. This exercises the codepath that would fail before
c6f2f016 on Windows, and shows that it still doesn't fail now that we're
using get_dirent_type() on both Windows and Unix.

Back-patch to 15, where in-place tablespaces arrived and caused this
problem (ie directories where previously only symlinks were expected).

Reviewed-by: Michael Paquier <michael(at)paquier(dot)xyz>
Discussion: https://postgr.es/m/CA%2BhUKGLzLK4PUPx0_AwXEWXOYAejU%3D7XpxnYE55Y%2Be7hB2N3FA%40mail.gmail.com

Branch
------
REL_15_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/202b56ba91cb6c0741cc9340ac57a50dbcdac549

Modified Files
--------------
src/backend/access/transam/xlog.c | 5 -----
src/bin/pg_basebackup/t/010_pg_basebackup.pl | 17 +++++++++++++++++
2 files changed, 17 insertions(+), 5 deletions(-)

Browse pgsql-committers by date

  From Date Subject
Next Message Alvaro Herrera 2022-07-22 11:15:57 pgsql: Update src/backend/parser/README
Previous Message Thomas Munro 2022-07-22 05:43:16 pgsql: Remove unnecessary Windows-specific basebackup code.