Re: pg_resetwal tests, logging, and docs update
Peter Eisentraut <peter@eisentraut.org>
From: Peter Eisentraut <peter@eisentraut.org>
To: Aleksander Alekseev <aleksander@timescale.com>,
pgsql-hackers <pgsql-hackers@postgresql.org>
Date: 2023-11-06T08:38:36Z
Lists: pgsql-hackers
On 01.11.23 12:12, Aleksander Alekseev wrote: > Hi, > >> Hmm. I think maybe we should fix the behavior of >> GetDataDirectoryCreatePerm() to be more consistent between Windows and >> non-Windows. This is usually the first function a program uses on the >> proposed data directory, so it's also responsible for reporting if the >> data directory does not exist. But then on Windows, because the >> function does nothing, those error scenarios end up on quite different >> code paths, and I'm not sure if those are really checked that carefully. >> I think we can make this more robust if we have >> GetDataDirectoryCreatePerm() still run the stat() call on the proposed >> data directory and report the error. See attached patch. > > Yep, that would be much better. > > Attaching all three patches together in order to make sure cfbot is > still happy with them while the `master` branch is evolving. > > Assuming cfbot will have no complaints I suggest merging them. Done, thanks.
Commits
-
doc: pg_resetwal: Add comments how the multipliers are derived
- 6ceec8a1fe7a 17.0 landed
-
pg_resetwal: Add more tests and test coverage
- 7b5275eec3a5 17.0 landed
-
More consistent behavior of GetDataDirectoryCreatePerm on Windows
- 2c7c6c417fe6 17.0 landed
-
doc: Improve documentation about pg_resetwal -f option
- 5f1b00e64aee 17.0 landed
-
pg_resetwal: Use frontend logging API
- a11d8e10f226 17.0 landed
-
pg_resetwal: Regroup --help output
- b5da1b3a939a 17.0 landed
-
pg_resetwal: Improve error with wrong/missing data directory
- 1d863c250461 17.0 landed
-
pg_resetwal: Update an obsolete comment
- 7273945cafa7 17.0 landed