[SERVER-37235] invalidateSessions calls inside the OpObserver should be registered in the RecoveryUnit onCommit callback Created: 20/Sep/18 Updated: 29/Oct/23 Resolved: 14/May/19 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | None |
| Affects Version/s: | 4.1.3 |
| Fix Version/s: | 4.1.12 |
| Type: | Bug | Priority: | Major - P3 |
| Reporter: | Randolph Tan | Assignee: | Kaloian Manassiev |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | prepare_errors | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||||||
| Backwards Compatibility: | Fully Compatible | ||||||||||||
| Operating System: | ALL | ||||||||||||
| Sprint: | Sharding 2019-01-28, Sharding 2019-02-11, Sharding 2019-02-25, Sharding 2019-03-11, Sharding 2019-03-25, Sharding 2019-04-08, Sharding 2019-04-22, Sharding 2019-05-06, Sharding 2019-05-20 | ||||||||||||
| Participants: | |||||||||||||
| Description |
|
otherwise, it is possible for another thread trying to perform a refresh as a response to being invalidated will not see the side effect that cause the invalidation. |
| Comments |
| Comment by Githook User [ 14/May/19 ] |
|
Author: {'name': 'Gregory Wlodarek', 'username': 'GWlodarek', 'email': 'gregory.wlodarek@mongodb.com'}Message: |
| Comment by Githook User [ 14/May/19 ] |
|
Author: {'name': 'Kaloian Manassiev', 'username': 'kaloianm', 'email': 'kaloian.manassiev@mongodb.com'}Message: |
| Comment by Kaloian Manassiev [ 15/Jan/19 ] |
|
The purpose of calling invalidateSessions directly in the OpObserver is so that it has a chance to "veto" the direct write if for example there is a prepared transaction on it. With the session check-out mechanism now in place, refresh can only be called by a thread which has the session checked-out and since invalidateSessions kills the session and then checks it out in order to invalidate it. Because of this, the only thing which needs to be registered in on-commit handler is the actual call to invalidate, but not the kill. |