Re: [Patch]The Case For WAL-Logging pg_upgrade
Re: [Patch]The Case For WAL-Logging pg_upgrade
От:
Heikki Linnakangas <hlinnaka@iki.fi>
Дата:
On 05/08/2026 08:15, John Naylor wrote: > I think my phrasing was ambiguous: When I said "the system must know > what file paths to stick into the WAL stream", I didn't mean creating > path strings, I meant the enumeration done by capture_all_relfiles() > etc. Normally, a WAL record enters the stream because a logged write > happens. In the patch, the input to WAL comes from a directory walk of > already-written files. If this walk misses anything, then the standby > diverges from the primary. It'd be pretty hard to screw up walking all files in a directory ;-). I don't think missing some files is a serious concern. For comparison, the GIN and GiST index build also work by first building the whole index, and then WAL-logging the result as a separate step. There's precedent in pg_rewing too, which also walks the data directory, copies all files it doesn't recognize as is, and has special handling for relation files. - Heikki