forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commit4fbe609

Amit Kapila
Fix executing invalidation messages generated by subtransactions during decoding.
This problem has been introduced by commit272248a where we startedassigning the subtransactions to the top-level transaction when we markboth the top-level transaction and its subtransactions as containingcatalog changes. After we assign subtransactions to the top-leveltransaction, we were not allowed to execute any invalidations associatedwith it when we decide to skip the transaction.The reason to assign the subtransactions to the top-level transaction wasto avoid the assertion failure in AssertTXNLsnOrder() as they have thesame LSN when we sometimes start accumulating transaction changes forpartial transactions after the restart. Now that with commit64ff0fe,we skip this assertion check until we reach the LSN at which we startdecoding the contents of the transaction, so, there is no reason for suchan assignment anymore.The assignment change was introduced in 15 and prior versions but this bugdoesn't exist in branches prior to 14 since we don't add invalidationmessages to subtransactions. We decided to backpatch through 11 forconsistency but not for 10 since its final release is near.Reported-by: Kuroda HayatoAuthor: Masahiko SawadaReviewed-by: Amit KapilaBackpatch-through: 11Discussion:https://postgr.es/m/TYAPR01MB58660803BCAA7849C8584AA4F57E9%40TYAPR01MB5866.jpnprd01.prod.outlook.comDiscussion:https://postgr.es/m/a89b46b6-0239-2fd5-71a9-b19b1f7a7145%40enterprisedb.com1 parentf892150 commit4fbe609
File tree
3 files changed
+52
-3
lines changed- contrib/test_decoding
- expected
- specs
- src/backend/replication/logical
3 files changed
+52
-3
lines changedLines changed: 45 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
87 | 87 |
| |
88 | 88 |
| |
89 | 89 |
| |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
| 129 | + | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
| 134 | + |
Lines changed: 7 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
53 | 53 |
| |
54 | 54 |
| |
55 | 55 |
| |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + |
Lines changed: 0 additions & 3 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
2113 | 2113 |
| |
2114 | 2114 |
| |
2115 | 2115 |
| |
2116 |
| - | |
2117 |
| - | |
2118 | 2116 |
| |
2119 |
| - | |
2120 | 2117 |
| |
2121 | 2118 |
|
0 commit comments
Comments
(0)