[SERVER-75907] Do not use const_cast in sdamServerSelector::_getCandidateServers() Created: 10/Apr/23 Updated: 29/Oct/23 Resolved: 01/Aug/23 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | 7.1.0-rc0 |
| Type: | Improvement | Priority: | Major - P3 |
| Reporter: | Wenqin Ye | Assignee: | Kruti Shah |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | neweng, sharding-nyc-subteam2 | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Assigned Teams: |
Sharding NYC
|
| Backwards Compatibility: | Fully Compatible |
| Sprint: | Sharding NYC 2023-07-24, Sharding NYC 2023-08-07 |
| Participants: | |
| Story Points: | 2 |
| Description |
|
The server_selector uses a const_cast to update the passed in criteria in `sdamServerSelector::_getCandidateServers`. const_cast is not great to use because it is modifying a const reference that should not be modified. Right now this does not cause a bug, and is more of a code cleanup ticket. |
| Comments |
| Comment by Githook User [ 02/Aug/23 ] |
|
Author: {'name': 'Kruti Shah', 'email': 'kruti139@gmail.com', 'username': 'krutishah139'}Message: |
| Comment by Githook User [ 01/Aug/23 ] |
|
Author: {'name': 'Kruti Shah', 'email': 'kruti139@gmail.com', 'username': 'krutishah139'}Message: |