[SERVER-85326] Remove instances of `shared_ptr` from `ServiceEntryPointCommon` Created: 17/Jan/24 Updated: 18/Jan/24 |
|
| Status: | Open |
| Project: | Core Server |
| Component/s: | Internal Code |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Task | Priority: | Major - P3 |
| Reporter: | Amirsaman Memaripour | Assignee: | Backlog - Service Architecture |
| Resolution: | Unresolved | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||
| Assigned Teams: |
Service Arch
|
||||||||
| Participants: | |||||||||
| Description |
|
The command processing path is blocking today: each user operation is assigned a thread that it will use to complete the operation. As a result, using shared pointers to reference any state that doesn't outlive an operation (e.g. ExecutionContext) is not necessary, and will introduce performance overhead on the hot path (e.g. the cost of heap allocation and ref-counting the shared object). The idea is to remove these shared pointers from the command path to save on the cost and simplify the code. |