pgsql: Clarify some errors in pg_receivewal when closing WAL segments

2021-09-16 Thread Michael Paquier
Clarify some errors in pg_receivewal when closing WAL segments A WAL segment closed during a WAL stream for pg_receivewal would generate incorrect error messages depending on the context, as the file name used when referring to a WAL segment ignored partial files or the compression method used. I

Re: pgsql: Support "postgres -C" with runtime-computed GUCs

2021-09-16 Thread Alvaro Herrera
On 2021-Sep-17, Michael Paquier wrote: > On Fri, Sep 17, 2021 at 08:08:44AM +0900, Michael Paquier wrote: > > I am not completely sure what's going on here yet, so I'll just switch > > the test to be skipped when Msys is involved for now. That should be > > enough to bring back those machines to

Re: pgsql: Support "postgres -C" with runtime-computed GUCs

2021-09-16 Thread Michael Paquier
On Fri, Sep 17, 2021 at 08:08:44AM +0900, Michael Paquier wrote: > I am not completely sure what's going on here yet, so I'll just switch > the test to be skipped when Msys is involved for now. That should be > enough to bring back those machines to green. So, after drinking down a coffee, I have

pgsql: Disable test for postgres -C on Msys

2021-09-16 Thread Michael Paquier
Disable test for postgres -C on Msys The output generated on Msys is incorrect because of the different way IPC::Run processes outputs with native Perl (converts natively \r\n to \n) and Msys perl (\r\n kept as-is), causing this test to fail. For now, just disable the test to bring the buildfarm

Re: pgsql: Support "postgres -C" with runtime-computed GUCs

2021-09-16 Thread Michael Paquier
On Thu, Sep 16, 2021 at 05:56:49PM -0400, Tom Lane wrote: > Test case for this seems to have newline-related issues on Windows. Thanks. I missed it. > https://buildfarm.postgresql.org/cgi-bin/show_log.pl?nm=fairywren&dt=2021-09-16%2018%3A36%3A14 > > # Failed test 'data_checksums=on is reporte

Re: pgsql: Support "postgres -C" with runtime-computed GUCs

2021-09-16 Thread Tom Lane
Michael Paquier writes: > Support "postgres -C" with runtime-computed GUCs Test case for this seems to have newline-related issues on Windows. https://buildfarm.postgresql.org/cgi-bin/show_log.pl?nm=fairywren&dt=2021-09-16%2018%3A36%3A14 # Failed test 'data_checksums=on is reported on an offl

pgsql: Fix EXPLAIN to handle SEARCH BREADTH FIRST queries.

2021-09-16 Thread Tom Lane
Fix EXPLAIN to handle SEARCH BREADTH FIRST queries. The rewriter transformation for SEARCH BREADTH FIRST produces a FieldSelect on a Var of type RECORD, where the Var references the recursive union's worktable output. EXPLAIN VERBOSE failed to handle this case, because it only expected such Vars

pgsql: Fix EXPLAIN to handle SEARCH BREADTH FIRST queries.

2021-09-16 Thread Tom Lane
Fix EXPLAIN to handle SEARCH BREADTH FIRST queries. The rewriter transformation for SEARCH BREADTH FIRST produces a FieldSelect on a Var of type RECORD, where the Var references the recursive union's worktable output. EXPLAIN VERBOSE failed to handle this case, because it only expected such Vars

pgsql: Message style improvements

2021-09-16 Thread Peter Eisentraut
Message style improvements Branch -- master Details --- https://git.postgresql.org/pg/commitdiff/4ac0f450b698442c3273ddfe8eed0e1a7e56645f Modified Files -- src/backend/commands/typecmds.c | 6 +++--- src/backend/libpq/auth.c| 4 ++-- src/backend/libpq/

pgsql: Message style improvements

2021-09-16 Thread Peter Eisentraut
Message style improvements Branch -- REL_14_STABLE Details --- https://git.postgresql.org/pg/commitdiff/f46dc96fcc652d5c29343e0eb4fa8e86a9468c36 Modified Files -- src/backend/commands/typecmds.c | 6 +++--- src/backend/libpq/auth.c| 4 ++-- src/backend

pgsql: process startup: Do InitProcess() at the same time regardless of

2021-09-16 Thread Andres Freund
process startup: Do InitProcess() at the same time regardless of EXEC_BACKEND. An upcoming patch splits single user mode into its own function. This makes that easier. Split out for easier review / testing. Reviewed-By: Kyotaro Horiguchi Author: Andres Freund Discussion: https://postgr.es/m/20

pgsql: Fix performance regression from session statistics.

2021-09-16 Thread Andres Freund
Fix performance regression from session statistics. Session statistics, as introduced by 960869da08, had several shortcomings: - an additional GetCurrentTimestamp() call that also impaired the accuracy of the data collected This can be avoided by passing the current timestamp we already have

pgsql: Fix performance regression from session statistics.

2021-09-16 Thread Andres Freund
Fix performance regression from session statistics. Session statistics, as introduced by 960869da08, had several shortcomings: - an additional GetCurrentTimestamp() call that also impaired the accuracy of the data collected This can be avoided by passing the current timestamp we already have