- Notifications
You must be signed in to change notification settings - Fork4.9k
Commit520ec24
committed
Fix race condition in committing a serializable transaction
The finished transaction list can contain XIDs that are older than theserializable global xmin. It's a short-lived state;ClearOldPredicateLocks() removes any such transactions from the list,and it's called whenever the global xmin advances. But if anotherbackend calls SummarizeOldestCommittedSxact() in that window, it willcall SerialAdd() on an XID that's older than the global xmin, or ifthere are no more transactions running, when global xmin isinvalid. That trips the assertion in SerialAdd().Fixes bug #18658 reported by Andrew Bille. Thanks to Alexander Lakhinfor analysis. Backpatch to all versions.Discussion:https://www.postgresql.org/message-id/18658-7dab125ec688c70b%40postgresql.org1 parentfbbcbde commit520ec24
1 file changed
+9
-4
lines changedLines changed: 9 additions & 4 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
918 | 918 |
| |
919 | 919 |
| |
920 | 920 |
| |
921 |
| - | |
922 |
| - | |
923 |
| - | |
| 921 | + | |
| 922 | + | |
| 923 | + | |
| 924 | + | |
924 | 925 |
| |
925 | 926 |
| |
926 |
| - | |
| 927 | + | |
| 928 | + | |
| 929 | + | |
| 930 | + | |
| 931 | + | |
927 | 932 |
| |
928 | 933 |
| |
929 | 934 |
| |
|
0 commit comments
Comments
(0)