[SERVER-41780] prepareTransaction doesn't always wait for write concern on retries Created: 14/Jun/19 Updated: 29/Oct/23 Resolved: 25/Jun/19 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Replication |
| Affects Version/s: | None |
| Fix Version/s: | 4.2.0-rc2, 4.3.1 |
| Type: | Bug | Priority: | Major - P3 |
| Reporter: | Judah Schvimer | Assignee: | Judah Schvimer |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||||||||||
| Backwards Compatibility: | Fully Compatible | ||||||||||||||||
| Operating System: | ALL | ||||||||||||||||
| Backport Requested: |
v4.2
|
||||||||||||||||
| Sprint: | Repl 2019-07-01 | ||||||||||||||||
| Participants: | |||||||||||||||||
| Linked BF Score: | 21 | ||||||||||||||||
| Description |
|
We no longer wait for write concern on the client lastOp no matter what as of |
| Comments |
| Comment by Githook User [ 25/Jun/19 ] |
|
Author: {'name': 'Judah Schvimer', 'email': 'judah@mongodb.com', 'username': 'judahschvimer'}Message: (cherry picked from commit add3f7ba3cca63f4ffbb8a5712f7e20b17f3cf28) |
| Comment by Githook User [ 25/Jun/19 ] |
|
Author: {'name': 'Judah Schvimer', 'username': 'judahschvimer', 'email': 'judah@mongodb.com'}Message: |
| Comment by Judah Schvimer [ 18/Jun/19 ] |
|
It looks like this is only a problem for prepareTransaction. I'm improving our testing a bit, especially around transactions to ensure that. |
| Comment by Judah Schvimer [ 17/Jun/19 ] |
|
Calling setLastOp or setLastOpToSystemLastOpTime will guarantee we wait for write concern no matter what. It is only a problem if we never call either. I will audit callers of those two to make sure we never have any surrounding if statements like in prepare elsewhere. |
| Comment by Esha Maharishi (Inactive) [ 17/Jun/19 ] |
|
Note, what if the client's lastOp somehow is equal to the system last OpTime? Will calling setLastOpToSystemLastOpTime still guarantee that the server waits for writeConcern? |