Fix incorrect comment about nbtree WAL record.
authorPeter Geoghegan <[email protected]>
Mon, 17 Apr 2023 16:58:18 +0000 (09:58 -0700)
committerPeter Geoghegan <[email protected]>
Mon, 17 Apr 2023 16:58:18 +0000 (09:58 -0700)
The nbtree VACUUM WAL record stores its page offset number payload in
blk 0 (just like the closely related nbtree DELETE WAL record).  Commit
ebd551f5 fixed a similar issue with the DELETE WAL record, but missed
this one.

src/include/access/nbtxlog.h

index a0310c96fb1afba6b6b6ed85d8f7d473b006686f..7dd9fd020658a28b1cddf788eda1c743ec1b5a3b 100644 (file)
@@ -201,7 +201,7 @@ typedef struct xl_btree_reuse_page
  * when btinsert() is called.
  *
  * The records are very similar.  The only difference is that xl_btree_delete
- * has a snapshotConflictHorizon field to generate recovery conflicts.
+ * have snapshotConflictHorizon/isCatalogRel fields for recovery conflicts.
  * (VACUUM operations can just rely on earlier conflicts generated during
  * pruning of the table whose TIDs the to-be-deleted index tuples point to.
  * There are also small differences between each REDO routine that we don't go
@@ -225,9 +225,13 @@ typedef struct xl_btree_vacuum
        uint16          ndeleted;
        uint16          nupdated;
 
-       /* DELETED TARGET OFFSET NUMBERS FOLLOW */
-       /* UPDATED TARGET OFFSET NUMBERS FOLLOW */
-       /* UPDATED TUPLES METADATA (xl_btree_update) ARRAY FOLLOWS */
+       /*----
+        * In payload of blk 0 :
+        * - DELETED TARGET OFFSET NUMBERS
+        * - UPDATED TARGET OFFSET NUMBERS
+        * - UPDATED TUPLES METADATA (xl_btree_update) ITEMS
+        *----
+        */
 } xl_btree_vacuum;
 
 #define SizeOfBtreeVacuum      (offsetof(xl_btree_vacuum, nupdated) + sizeof(uint16))
@@ -244,7 +248,7 @@ typedef struct xl_btree_delete
         * In payload of blk 0 :
         * - DELETED TARGET OFFSET NUMBERS
         * - UPDATED TARGET OFFSET NUMBERS
-        * - UPDATED TUPLES METADATA (xl_btree_update) ARRAY
+        * - UPDATED TUPLES METADATA (xl_btree_update) ITEMS
         *----
         */
 } xl_btree_delete;