forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commit4bfe68d
committed
Run a portal's cleanup hook immediately when pushing it to FAILED state.
This extends the changes of commit6252c4fso that we run the cleanup hook earlier for failure cases as well assuccess cases. As before, the point is to avoid an assertion failure froman Assert I added in commita874fe7, whichwas meant to check that no user-written code can be called during portalcleanup. This fixes a case reported by Pavan Deolasee in which the Assertcould be triggered during backend exit (see the new regression test case),and also prevents the possibility that the cleanup hook is run afterportions of the portal's state have already been recycled. That doesn'treally matter in current usage, but it foreseeably could matter in thefuture.Back-patch to 9.1 where the Assert in question was added.1 parentedec8c8 commit4bfe68d
File tree
6 files changed
+72
-42
lines changed- src
- backend
- commands
- tcop
- utils/mmgr
- include/utils
- test/regress
- expected
- sql
6 files changed
+72
-42
lines changedLines changed: 6 additions & 2 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
224 | 224 |
| |
225 | 225 |
| |
226 | 226 |
| |
227 |
| - | |
| 227 | + | |
228 | 228 |
| |
229 | 229 |
| |
230 | 230 |
| |
| |||
234 | 234 |
| |
235 | 235 |
| |
236 | 236 |
| |
| 237 | + | |
| 238 | + | |
| 239 | + | |
| 240 | + | |
237 | 241 |
| |
238 | 242 |
| |
239 | 243 |
| |
| |||
420 | 424 |
| |
421 | 425 |
| |
422 | 426 |
| |
423 |
| - | |
| 427 | + | |
424 | 428 |
| |
425 | 429 |
| |
426 | 430 |
| |
|
Lines changed: 3 additions & 3 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
607 | 607 |
| |
608 | 608 |
| |
609 | 609 |
| |
610 |
| - | |
| 610 | + | |
611 | 611 |
| |
612 | 612 |
| |
613 | 613 |
| |
| |||
829 | 829 |
| |
830 | 830 |
| |
831 | 831 |
| |
832 |
| - | |
| 832 | + | |
833 | 833 |
| |
834 | 834 |
| |
835 | 835 |
| |
| |||
1446 | 1446 |
| |
1447 | 1447 |
| |
1448 | 1448 |
| |
1449 |
| - | |
| 1449 | + | |
1450 | 1450 |
| |
1451 | 1451 |
| |
1452 | 1452 |
| |
|
Lines changed: 46 additions & 7 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
405 | 405 |
| |
406 | 406 |
| |
407 | 407 |
| |
| 408 | + | |
| 409 | + | |
408 | 410 |
| |
409 | 411 |
| |
410 | 412 |
| |
| |||
418 | 420 |
| |
419 | 421 |
| |
420 | 422 |
| |
421 |
| - | |
422 |
| - | |
| 423 | + | |
| 424 | + | |
| 425 | + | |
| 426 | + | |
| 427 | + | |
| 428 | + | |
| 429 | + | |
| 430 | + | |
| 431 | + | |
| 432 | + | |
| 433 | + | |
| 434 | + | |
| 435 | + | |
| 436 | + | |
| 437 | + | |
| 438 | + | |
| 439 | + | |
| 440 | + | |
| 441 | + | |
| 442 | + | |
| 443 | + | |
| 444 | + | |
| 445 | + | |
| 446 | + | |
| 447 | + | |
| 448 | + | |
| 449 | + | |
| 450 | + | |
| 451 | + | |
| 452 | + | |
423 | 453 |
| |
424 | 454 |
| |
425 | 455 |
| |
| |||
455 | 485 |
| |
456 | 486 |
| |
457 | 487 |
| |
| 488 | + | |
| 489 | + | |
| 490 | + | |
458 | 491 |
| |
459 | 492 |
| |
460 | 493 |
| |
| |||
713 | 746 |
| |
714 | 747 |
| |
715 | 748 |
| |
716 |
| - | |
| 749 | + | |
717 | 750 |
| |
718 | 751 |
| |
719 | 752 |
| |
| |||
728 | 761 |
| |
729 | 762 |
| |
730 | 763 |
| |
731 |
| - | |
| 764 | + | |
732 | 765 |
| |
733 |
| - | |
| 766 | + | |
| 767 | + | |
| 768 | + | |
| 769 | + | |
734 | 770 |
| |
735 | 771 |
| |
736 | 772 |
| |
| |||
862 | 898 |
| |
863 | 899 |
| |
864 | 900 |
| |
865 |
| - | |
| 901 | + | |
866 | 902 |
| |
867 |
| - | |
| 903 | + | |
| 904 | + | |
| 905 | + | |
| 906 | + | |
868 | 907 |
| |
869 | 908 |
| |
870 | 909 |
| |
|
Lines changed: 1 addition & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
207 | 207 |
| |
208 | 208 |
| |
209 | 209 |
| |
| 210 | + | |
210 | 211 |
| |
211 | 212 |
| |
212 | 213 |
| |
|
Lines changed: 8 additions & 25 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
601 | 601 |
| |
602 | 602 |
| |
603 | 603 |
| |
604 |
| - | |
605 |
| - | |
606 |
| - | |
607 |
| - | |
608 |
| - | |
609 |
| - | |
610 |
| - | |
611 |
| - | |
612 |
| - | |
613 |
| - | |
614 |
| - | |
615 |
| - | |
616 |
| - | |
617 |
| - | |
618 |
| - | |
619 |
| - | |
620 |
| - | |
621 |
| - | |
622 |
| - | |
623 |
| - | |
624 |
| - | |
625 |
| - | |
626 |
| - | |
627 |
| - | |
628 |
| - | |
| 604 | + | |
| 605 | + | |
| 606 | + | |
| 607 | + | |
| 608 | + | |
| 609 | + | |
| 610 | + | |
| 611 | + |
Lines changed: 8 additions & 5 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
368 | 368 |
| |
369 | 369 |
| |
370 | 370 |
| |
371 |
| - | |
372 |
| - | |
373 |
| - | |
374 |
| - | |
375 |
| - | |
| 371 | + | |
| 372 | + | |
| 373 | + | |
| 374 | + | |
| 375 | + | |
| 376 | + | |
| 377 | + | |
| 378 | + |
0 commit comments
Comments
(0)