- Notifications
You must be signed in to change notification settings - Fork4.9k
Commit6c2003f
committed
Don't force-assign transaction id when exporting a snapshot.
Previously we required every exported transaction to have an xidassigned. That was used to check that the exporting transaction isstill running, which in turn is needed to guarantee that thatnecessary rows haven't been removed in between exporting and importingthe snapshot.The exported xid caused unnecessary problems with logical decoding,because slot creation has to wait for all concurrent xid to finish,which in turn serializes concurrent slot creation. It alsoprohibited snapshots to be exported on hot-standby replicas.Instead export the virtual transactionid, which avoids the unnecessaryserialization and the inability to export snapshots on standbys. Thischanges the file name of the exported snapshot, but since we neverdocumented what that one means, that seems ok.Author: Petr Jelinek, slightly editorialized by meReviewed-By: Andres FreundDiscussion:https://postgr.es/m/f598b4b8-8cd7-0d54-0939-adda763d8c34@2ndquadrant.com1 parentb6966d4 commit6c2003f
File tree
7 files changed
+115
-67
lines changed- doc/src/sgml/ref
- src
- backend
- replication/logical
- storage
- ipc
- lmgr
- utils/time
- include/storage
7 files changed
+115
-67
lines changedLines changed: 3 additions & 3 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
222 | 222 |
| |
223 | 223 |
| |
224 | 224 |
| |
225 |
| - | |
226 |
| - | |
| 225 | + | |
| 226 | + | |
227 | 227 |
| |
228 | 228 |
| |
229 | 229 |
| |
| |||
233 | 233 |
| |
234 | 234 |
| |
235 | 235 |
| |
236 |
| - | |
| 236 | + | |
237 | 237 |
| |
238 | 238 |
| |
239 | 239 |
| |
|
Lines changed: 7 additions & 7 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
262 | 262 |
| |
263 | 263 |
| |
264 | 264 |
| |
265 |
| - | |
| 265 | + | |
266 | 266 |
| |
267 | 267 |
| |
268 | 268 |
| |
| |||
463 | 463 |
| |
464 | 464 |
| |
465 | 465 |
| |
466 |
| - | |
| 466 | + | |
467 | 467 |
| |
468 | 468 |
| |
469 | 469 |
| |
| |||
562 | 562 |
| |
563 | 563 |
| |
564 | 564 |
| |
565 |
| - | |
| 565 | + | |
566 | 566 |
| |
567 | 567 |
| |
568 | 568 |
| |
| |||
679 | 679 |
| |
680 | 680 |
| |
681 | 681 |
| |
682 |
| - | |
| 682 | + | |
683 | 683 |
| |
684 | 684 |
| |
685 | 685 |
| |
| |||
743 | 743 |
| |
744 | 744 |
| |
745 | 745 |
| |
746 |
| - | |
| 746 | + | |
747 | 747 |
| |
748 | 748 |
| |
749 | 749 |
| |
| |||
1061 | 1061 |
| |
1062 | 1062 |
| |
1063 | 1063 |
| |
1064 |
| - | |
| 1064 | + | |
1065 | 1065 |
| |
1066 | 1066 |
| |
1067 | 1067 |
| |
| |||
1831 | 1831 |
| |
1832 | 1832 |
| |
1833 | 1833 |
| |
1834 |
| - | |
| 1834 | + | |
1835 | 1835 |
| |
1836 | 1836 |
| |
1837 | 1837 |
| |
|
Lines changed: 7 additions & 4 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
1793 | 1793 |
| |
1794 | 1794 |
| |
1795 | 1795 |
| |
1796 |
| - | |
| 1796 | + | |
| 1797 | + | |
1797 | 1798 |
| |
1798 | 1799 |
| |
1799 | 1800 |
| |
1800 | 1801 |
| |
1801 | 1802 |
| |
1802 | 1803 |
| |
1803 |
| - | |
| 1804 | + | |
1804 | 1805 |
| |
1805 | 1806 |
| |
1806 | 1807 |
| |
| |||
1817 | 1818 |
| |
1818 | 1819 |
| |
1819 | 1820 |
| |
1820 |
| - | |
1821 |
| - | |
| 1821 | + | |
| 1822 | + | |
| 1823 | + | |
| 1824 | + | |
1822 | 1825 |
| |
1823 | 1826 |
| |
1824 | 1827 |
| |
|
Lines changed: 15 additions & 11 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
148 | 148 |
| |
149 | 149 |
| |
150 | 150 |
| |
151 |
| - | |
| 151 | + | |
152 | 152 |
| |
153 | 153 |
| |
154 | 154 |
| |
| |||
434 | 434 |
| |
435 | 435 |
| |
436 | 436 |
| |
437 |
| - | |
| 437 | + | |
| 438 | + | |
438 | 439 |
| |
439 | 440 |
| |
440 | 441 |
| |
| |||
1510 | 1511 |
| |
1511 | 1512 |
| |
1512 | 1513 |
| |
1513 |
| - | |
| 1514 | + | |
1514 | 1515 |
| |
1515 | 1516 |
| |
1516 | 1517 |
| |
| |||
1643 | 1644 |
| |
1644 | 1645 |
| |
1645 | 1646 |
| |
1646 |
| - | |
| 1647 | + | |
1647 | 1648 |
| |
1648 | 1649 |
| |
1649 | 1650 |
| |
| |||
1658 | 1659 |
| |
1659 | 1660 |
| |
1660 | 1661 |
| |
1661 |
| - | |
| 1662 | + | |
| 1663 | + | |
1662 | 1664 |
| |
1663 | 1665 |
| |
1664 | 1666 |
| |
| |||
1673 | 1675 |
| |
1674 | 1676 |
| |
1675 | 1677 |
| |
1676 |
| - | |
| 1678 | + | |
| 1679 | + | |
1677 | 1680 |
| |
1678 | 1681 |
| |
1679 | 1682 |
| |
| |||
1687 | 1690 |
| |
1688 | 1691 |
| |
1689 | 1692 |
| |
1690 |
| - | |
| 1693 | + | |
| 1694 | + | |
1691 | 1695 |
| |
1692 | 1696 |
| |
1693 | 1697 |
| |
| |||
1741 | 1745 |
| |
1742 | 1746 |
| |
1743 | 1747 |
| |
1744 |
| - | |
| 1748 | + | |
1745 | 1749 |
| |
1746 |
| - | |
| 1750 | + | |
1747 | 1751 |
| |
1748 | 1752 |
| |
1749 | 1753 |
| |
1750 | 1754 |
| |
1751 | 1755 |
| |
1752 | 1756 |
| |
1753 |
| - | |
1754 |
| - | |
| 1757 | + | |
| 1758 | + | |
1755 | 1759 |
| |
1756 | 1760 |
| |
1757 | 1761 |
| |
|
0 commit comments
Comments
(0)