forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commit89f3973
committed
Fix WAL format incompatibility introduced by backpatching of52ac6cd
52ac6cd added new field to ginxlogDeletePage and was backpatched to 9.4.That led to problems when patched postgres instance applies WAL recordsgenerated by non-patched one. WAL records generated by non-patched instancedon't contain new field, which patched one is expecting to see.Thankfully, we can distinguish patched and non-patched WAL records by their datasize. If we see that WAL record is generated by non-patched instance, we skipprocessing of new field. This commit comes with some assertions. Inparticular, if it appears that on some platform struct data size didn't changethen static assertion will trigger.Reported-by: Simon RiggsDiscussion:https://postgr.es/m/CANP8%2Bj%2BK4whxf7ET7%2BgO%2BG-baC3-WxqqH%3DnV4X2CgfEPA3Yu3g%40mail.gmail.comAuthor: Alexander KorotkovReviewed-by: Simon Riggs, Alvaro HerreraBackpatch-through: 9.41 parent7d7435c commit89f3973
2 files changed
+28
-1
lines changedLines changed: 18 additions & 1 deletion
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
531 | 531 |
| |
532 | 532 |
| |
533 | 533 |
| |
534 |
| - | |
| 534 | + | |
| 535 | + | |
| 536 | + | |
| 537 | + | |
| 538 | + | |
| 539 | + | |
| 540 | + | |
| 541 | + | |
| 542 | + | |
| 543 | + | |
| 544 | + | |
| 545 | + | |
| 546 | + | |
| 547 | + | |
| 548 | + | |
| 549 | + | |
| 550 | + | |
| 551 | + | |
535 | 552 |
| |
536 | 553 |
| |
537 | 554 |
| |
|
Lines changed: 10 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
161 | 161 |
| |
162 | 162 |
| |
163 | 163 |
| |
| 164 | + | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
| 169 | + | |
| 170 | + | |
| 171 | + | |
| 172 | + | |
| 173 | + | |
164 | 174 |
| |
165 | 175 |
| |
166 | 176 |
| |
|
0 commit comments
Comments
(0)