[SERVER-67218] Remove ServiceStateMachine::setCleanupHook Created: 11/Jun/22 Updated: 29/Oct/23 Resolved: 17/Jun/22 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | 6.1.0-rc0 |
| Type: | Improvement | Priority: | Major - P3 |
| Reporter: | Billy Donahue | Assignee: | Billy Donahue |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||
| Backwards Compatibility: | Fully Compatible | ||||||||
| Sprint: | Service Arch 2022-06-27 | ||||||||
| Participants: | |||||||||
| Linked BF Score: | 124 | ||||||||
| Description |
|
This hook allows an arbitrary listener to monitor for ServiceStateMachine cleanup. ServiceStateMachine disconnects its Client as part of its cleanup process, and part of this is calling the ServiceEntryPoint::onClientDisconnect(Client*) virtual function AND THEN the installed _cleanupHook if any. The Mongod ServiceEntryPointImpl doesn't override onClientDisconnect, but does install a ssm.setCleanupHook. ServiceEntryPointMongos is the opposite: it doesn't install a ssm.setCleanupHook but DOES override onClientDisconnect. If there's some reason the onClientDisconnect must be followed by a LATER call to the installed cleanupHook we should clearly document that and change the SEP to have two SEP Client cleanup notifications with the same style of API. I suspect that we could probably be able to just combine them under the existing onClientDisconnect callback and remove ServiceStateMachine::setCleanupHook. PM-2766 |
| Comments |
| Comment by Githook User [ 17/Jun/22 ] |
|
Author: {'name': 'Billy Donahue', 'email': 'billy.donahue@mongodb.com', 'username': 'BillyDonahue'}Message: |
| Comment by Billy Donahue [ 13/Jun/22 ] |
|
The SEPImpl might affect or even fix BF-22149, for which we have no root cause, but it's a SSM lifecycle problem. |
| Comment by Billy Donahue [ 13/Jun/22 ] |
|
This is preliminary/parallel work to the design doc, reducing the interfaces to SSM. |