1
0
mirror of https://github.com/postgres/postgres.git synced 2025-05-03 22:24:49 +03:00
Thomas Munro 75818b3afb RelationTruncate() must set DELAY_CHKPT_START.
Previously, it set only DELAY_CHKPT_COMPLETE. That was important,
because it meant that if the XLOG_SMGR_TRUNCATE record preceded a
XLOG_CHECKPOINT_ONLINE record in the WAL, then the truncation would also
happen on disk before the XLOG_CHECKPOINT_ONLINE record was
written.

However, it didn't guarantee that the sync request for the truncation
was processed before the XLOG_CHECKPOINT_ONLINE record was written. By
setting DELAY_CHKPT_START, we guarantee that if an XLOG_SMGR_TRUNCATE
record is written to WAL before the redo pointer of a concurrent
checkpoint, the sync request queued by that operation must be processed
by that checkpoint, rather than being left for the following one.

This is a refinement of commit 412ad7a5563.  Back-patch to all supported
releases, like that commit.

Author: Robert Haas <robertmhaas@gmail.com>
Reported-by: Thomas Munro <thomas.munro@gmail.com>
Discussion: https://postgr.es/m/CA%2BhUKG%2B-2rjGZC2kwqr2NMLBcEBp4uf59QT1advbWYF_uc%2B0Aw%40mail.gmail.com
2024-12-03 10:12:05 +13:00
..
2024-11-28 08:27:20 +01:00
2024-11-28 08:27:20 +01:00
2024-11-28 08:27:20 +01:00
2024-10-08 10:51:20 +09:00
2024-11-28 12:01:14 +13:00
2024-12-02 13:30:07 -06:00
2024-11-28 08:27:20 +01:00
2024-11-28 08:27:20 +01:00
2024-06-24 13:11:27 +02:00
2024-11-28 08:27:20 +01:00
2024-11-28 08:27:20 +01:00
2024-11-28 08:27:20 +01:00
2024-11-28 08:27:20 +01:00
2024-11-28 08:27:20 +01:00
2024-12-02 13:30:07 -06:00
2024-06-21 08:17:23 +02:00
2024-05-14 12:57:22 +02:00