- Notifications
You must be signed in to change notification settings - Fork4.9k
Commit0de091a

Amit Kapila
Fix an oversight in3f28b2f.
Commit3f28b2f tried to ensure that the replication origin shouldn't beadvanced in case of an ERROR in the apply worker, so that it can requestthe same data again after restart. However, it is possible that an ERRORwas caught and handled by a (say PL/pgSQL) function, and the apply workercontinues to apply further changes, in which case, we shouldn't reset thereplication origin.Ensure to reset the origin only when the apply worker exits after anERROR.Commit3f28b2f added new function geterrlevel, which we removed in HEADas part of this commit, but kept it in backbranches to avoid breaking anyapplications. A separate case can be made to have such a function even forHEAD.Reported-by: Shawn McCoy <shawn.the.mccoy@gmail.com>Author: Hayato Kuroda <kuroda.hayato@fujitsu.com>Reviewed-by: Masahiko Sawada <sawada.mshk@gmail.com>Reviewed-by: vignesh C <vignesh21@gmail.com>Reviewed-by: Amit Kapila <amit.kapila16@gmail.com>Backpatch-through: 16, where it was introducedDiscussion:https://postgr.es/m/CALsgZNCGARa2mcYNVTSj9uoPcJo-tPuWUGECReKpNgTpo31_Pw@mail.gmail.com1 parente9ab867 commit0de091a
File tree
2 files changed
+87
-11
lines changed- src
- backend/replication/logical
- test/subscription/t
2 files changed
+87
-11
lines changedLines changed: 10 additions & 11 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
436 | 436 |
| |
437 | 437 |
| |
438 | 438 |
| |
| 439 | + | |
| 440 | + | |
439 | 441 |
| |
440 | 442 |
| |
441 | 443 |
| |
| |||
4431 | 4433 |
| |
4432 | 4434 |
| |
4433 | 4435 |
| |
| 4436 | + | |
| 4437 | + | |
| 4438 | + | |
| 4439 | + | |
| 4440 | + | |
| 4441 | + | |
| 4442 | + | |
| 4443 | + | |
4434 | 4444 |
| |
4435 | 4445 |
| |
4436 | 4446 |
| |
| |||
4940 | 4950 |
| |
4941 | 4951 |
| |
4942 | 4952 |
| |
4943 |
| - | |
4944 | 4953 |
| |
4945 | 4954 |
| |
4946 | 4955 |
| |
4947 | 4956 |
| |
4948 | 4957 |
| |
4949 | 4958 |
| |
4950 |
| - | |
4951 |
| - | |
4952 |
| - | |
4953 |
| - | |
4954 |
| - | |
4955 |
| - | |
4956 |
| - | |
4957 |
| - | |
4958 |
| - | |
4959 |
| - | |
4960 | 4959 |
| |
4961 | 4960 |
| |
4962 | 4961 |
| |
|
Lines changed: 77 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
491 | 491 |
| |
492 | 492 |
| |
493 | 493 |
| |
| 494 | + | |
| 495 | + | |
| 496 | + | |
| 497 | + | |
| 498 | + | |
| 499 | + | |
| 500 | + | |
| 501 | + | |
| 502 | + | |
| 503 | + | |
| 504 | + | |
| 505 | + | |
| 506 | + | |
| 507 | + | |
| 508 | + | |
| 509 | + | |
| 510 | + | |
| 511 | + | |
| 512 | + | |
| 513 | + | |
| 514 | + | |
| 515 | + | |
| 516 | + | |
| 517 | + | |
| 518 | + | |
| 519 | + | |
| 520 | + | |
| 521 | + | |
| 522 | + | |
| 523 | + | |
| 524 | + | |
| 525 | + | |
| 526 | + | |
| 527 | + | |
| 528 | + | |
| 529 | + | |
| 530 | + | |
| 531 | + | |
| 532 | + | |
| 533 | + | |
| 534 | + | |
| 535 | + | |
| 536 | + | |
| 537 | + | |
| 538 | + | |
| 539 | + | |
| 540 | + | |
| 541 | + | |
| 542 | + | |
| 543 | + | |
| 544 | + | |
| 545 | + | |
| 546 | + | |
| 547 | + | |
| 548 | + | |
| 549 | + | |
| 550 | + | |
| 551 | + | |
| 552 | + | |
| 553 | + | |
| 554 | + | |
| 555 | + | |
| 556 | + | |
| 557 | + | |
| 558 | + | |
| 559 | + | |
| 560 | + | |
| 561 | + | |
| 562 | + | |
| 563 | + | |
| 564 | + | |
| 565 | + | |
| 566 | + | |
| 567 | + | |
| 568 | + | |
| 569 | + | |
| 570 | + | |
494 | 571 |
|
0 commit comments
Comments
(0)