[SERVER-49104] Futurize ServiceStateMachine transitions Created: 25/Jun/20 Updated: 29/Oct/23 Resolved: 07/Aug/20 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | 4.7.0 |
| Type: | New Feature | Priority: | Major - P3 |
| Reporter: | Benjamin Caimano (Inactive) | Assignee: | Andrew Chen (Inactive) |
| 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 2020-07-27, Service Arch 2020-08-10 | ||||||||||||||||||||||||
| Participants: | |||||||||||||||||||||||||
| Linked BF Score: | 0 | ||||||||||||||||||||||||
| Description |
|
ServiceStateMachine currently dispatches and schedules through a central function here. We should convert it to a future chain with four callbacks:
This will make maintaining this code easier and it also allows us to do future continuations in any of these callbacks. For source and sink steps, they are already futurized via the SessionASIO. For the process step, we can convert ServiceEntryPoint::handleRequest() to return a Future<DbResponse> instead of a DbResponse. This means that command responses that would block on thread can now be fully asynchronous instead. It also means that if a request should be processed on a dedicated thread, we can schedule onto the right executor and return a future that runs inline on it. |
| Comments |
| Comment by Githook User [ 14/Sep/20 ] |
|
Author: {'name': 'Ben Caimano', 'email': 'ben.caimano@10gen.com'}Message: This reverts these commits: |
| Comment by Githook User [ 14/Sep/20 ] |
|
Author: {'name': 'Ben Caimano', 'email': 'ben.caimano@10gen.com'}Message: This reverts these commits: |
| Comment by Githook User [ 06/Aug/20 ] |
|
Author: {'name': 'Andrew Chen', 'email': 'a.chen@mongodb.com', 'username': 'AndrooTheChen'}Message: |