- Notifications
You must be signed in to change notification settings - Fork28
Commit7dce5ca
Gracefully handle concurrent aborts of uncommitted transactions that are being decoded alongside.
When a transaction aborts, it's changes are considered unnecessary forother transactions. That means the changes may be either cleaned up byvacuum or removed from HOT chains (thus made inaccessible throughindexes), and there may be other such consequences.When decoding committed transactions this is not an issue, and wenever decode transactions that abort before the decoding starts.But for in-progress transactions - for example when decoding preparedtransactions on PREPARE (and not COMMIT PREPARED as before), thismay cause failures when the output plugin consults catalogs (bothsystem and user-defined).We handle such failures by returning ERRCODE_TRANSACTION_ROLLBACKsqlerrcode from system table scan APIs to the backend decoding aspecific uncommitted transaction. The decoding logic on the receiptof such an sqlerrcode aborts the ongoing decoding and returnsgracefully.1 parent6334bec commit7dce5ca
File tree
6 files changed
+143
-9
lines changed- doc/src/sgml
- src
- backend
- access
- heap
- index
- replication/logical
- utils/time
- include/utils
6 files changed
+143
-9
lines changedOriginal file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
421 | 421 |
| |
422 | 422 |
| |
423 | 423 |
| |
424 |
| - | |
| 424 | + | |
| 425 | + | |
| 426 | + | |
| 427 | + | |
425 | 428 |
| |
426 | 429 |
| |
427 | 430 |
| |
|
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
1834 | 1834 |
| |
1835 | 1835 |
| |
1836 | 1836 |
| |
| 1837 | + | |
| 1838 | + | |
| 1839 | + | |
| 1840 | + | |
| 1841 | + | |
| 1842 | + | |
| 1843 | + | |
| 1844 | + | |
| 1845 | + | |
| 1846 | + | |
| 1847 | + | |
1837 | 1848 |
| |
1838 | 1849 |
| |
1839 | 1850 |
| |
| |||
1914 | 1925 |
| |
1915 | 1926 |
| |
1916 | 1927 |
| |
| 1928 | + | |
| 1929 | + | |
| 1930 | + | |
| 1931 | + | |
| 1932 | + | |
| 1933 | + | |
| 1934 | + | |
| 1935 | + | |
| 1936 | + | |
| 1937 | + | |
1917 | 1938 |
| |
1918 | 1939 |
| |
1919 | 1940 |
| |
| |||
2046 | 2067 |
| |
2047 | 2068 |
| |
2048 | 2069 |
| |
| 2070 | + | |
| 2071 | + | |
| 2072 | + | |
| 2073 | + | |
| 2074 | + | |
| 2075 | + | |
| 2076 | + | |
| 2077 | + | |
| 2078 | + | |
| 2079 | + | |
2049 | 2080 |
| |
2050 | 2081 |
| |
2051 | 2082 |
| |
| |||
2187 | 2218 |
| |
2188 | 2219 |
| |
2189 | 2220 |
| |
| 2221 | + | |
| 2222 | + | |
| 2223 | + | |
| 2224 | + | |
| 2225 | + | |
| 2226 | + | |
| 2227 | + | |
| 2228 | + | |
| 2229 | + | |
| 2230 | + | |
2190 | 2231 |
| |
2191 | 2232 |
| |
2192 | 2233 |
| |
| |||
2216 | 2257 |
| |
2217 | 2258 |
| |
2218 | 2259 |
| |
| 2260 | + | |
| 2261 | + | |
| 2262 | + | |
| 2263 | + | |
| 2264 | + | |
| 2265 | + | |
| 2266 | + | |
| 2267 | + | |
| 2268 | + | |
| 2269 | + | |
2219 | 2270 |
| |
2220 | 2271 |
| |
2221 | 2272 |
| |
|
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
25 | 25 |
| |
26 | 26 |
| |
27 | 27 |
| |
| 28 | + | |
28 | 29 |
| |
29 | 30 |
| |
30 | 31 |
| |
| |||
437 | 438 |
| |
438 | 439 |
| |
439 | 440 |
| |
| 441 | + | |
| 442 | + | |
| 443 | + | |
| 444 | + | |
| 445 | + | |
| 446 | + | |
| 447 | + | |
| 448 | + | |
| 449 | + | |
| 450 | + | |
| 451 | + | |
440 | 452 |
| |
441 | 453 |
| |
442 | 454 |
| |
| |||
490 | 502 |
| |
491 | 503 |
| |
492 | 504 |
| |
| 505 | + | |
| 506 | + | |
| 507 | + | |
| 508 | + | |
| 509 | + | |
| 510 | + | |
| 511 | + | |
| 512 | + | |
| 513 | + | |
| 514 | + | |
| 515 | + | |
| 516 | + | |
493 | 517 |
| |
494 | 518 |
| |
495 | 519 |
| |
| |||
607 | 631 |
| |
608 | 632 |
| |
609 | 633 |
| |
| 634 | + | |
| 635 | + | |
| 636 | + | |
| 637 | + | |
| 638 | + | |
| 639 | + | |
| 640 | + | |
| 641 | + | |
| 642 | + | |
| 643 | + | |
| 644 | + | |
610 | 645 |
| |
611 | 646 |
| |
612 | 647 |
| |
|
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
636 | 636 |
| |
637 | 637 |
| |
638 | 638 |
| |
639 |
| - | |
| 639 | + | |
640 | 640 |
| |
641 | 641 |
| |
642 | 642 |
| |
| |||
1442 | 1442 |
| |
1443 | 1443 |
| |
1444 | 1444 |
| |
| 1445 | + | |
1445 | 1446 |
| |
1446 | 1447 |
| |
1447 | 1448 |
| |
| |||
1468 | 1469 |
| |
1469 | 1470 |
| |
1470 | 1471 |
| |
1471 |
| - | |
| 1472 | + | |
1472 | 1473 |
| |
1473 | 1474 |
| |
1474 | 1475 |
| |
| |||
1709 | 1710 |
| |
1710 | 1711 |
| |
1711 | 1712 |
| |
1712 |
| - | |
| 1713 | + | |
1713 | 1714 |
| |
1714 | 1715 |
| |
1715 | 1716 |
| |
| |||
1729 | 1730 |
| |
1730 | 1731 |
| |
1731 | 1732 |
| |
1732 |
| - | |
| 1733 | + | |
1733 | 1734 |
| |
1734 | 1735 |
| |
1735 | 1736 |
| |
| |||
1814 | 1815 |
| |
1815 | 1816 |
| |
1816 | 1817 |
| |
| 1818 | + | |
| 1819 | + | |
| 1820 | + | |
| 1821 | + | |
| 1822 | + | |
| 1823 | + | |
| 1824 | + | |
| 1825 | + | |
| 1826 | + | |
| 1827 | + | |
| 1828 | + | |
| 1829 | + | |
| 1830 | + | |
| 1831 | + | |
1817 | 1832 |
| |
1818 | 1833 |
| |
1819 | 1834 |
| |
| |||
1837 | 1852 |
| |
1838 | 1853 |
| |
1839 | 1854 |
| |
1840 |
| - | |
| 1855 | + | |
| 1856 | + | |
| 1857 | + | |
| 1858 | + | |
| 1859 | + | |
| 1860 | + | |
| 1861 | + | |
| 1862 | + | |
1841 | 1863 |
| |
1842 | 1864 |
| |
1843 | 1865 |
| |
|
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
152 | 152 |
| |
153 | 153 |
| |
154 | 154 |
| |
| 155 | + | |
| 156 | + | |
| 157 | + | |
| 158 | + | |
| 159 | + | |
| 160 | + | |
| 161 | + | |
155 | 162 |
| |
156 | 163 |
| |
157 | 164 |
| |
| |||
2000 | 2007 |
| |
2001 | 2008 |
| |
2002 | 2009 |
| |
| 2010 | + | |
| 2011 | + | |
| 2012 | + | |
2003 | 2013 |
| |
2004 | 2014 |
| |
2005 | 2015 |
| |
2006 |
| - | |
| 2016 | + | |
| 2017 | + | |
2007 | 2018 |
| |
2008 | 2019 |
| |
2009 | 2020 |
| |
| |||
2012 | 2023 |
| |
2013 | 2024 |
| |
2014 | 2025 |
| |
2015 |
| - | |
2016 | 2026 |
| |
| 2027 | + | |
| 2028 | + | |
| 2029 | + | |
| 2030 | + | |
| 2031 | + | |
| 2032 | + | |
| 2033 | + | |
| 2034 | + | |
| 2035 | + | |
| 2036 | + | |
2017 | 2037 |
| |
2018 | 2038 |
| |
2019 | 2039 |
| |
| |||
2023 | 2043 |
| |
2024 | 2044 |
| |
2025 | 2045 |
| |
| 2046 | + | |
2026 | 2047 |
| |
2027 | 2048 |
| |
2028 | 2049 |
| |
|
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
103 | 103 |
| |
104 | 104 |
| |
105 | 105 |
| |
| 106 | + | |
106 | 107 |
| |
107 |
| - | |
| 108 | + | |
| 109 | + | |
108 | 110 |
| |
109 | 111 |
| |
110 | 112 |
| |
|
0 commit comments
Comments
(0)