[SERVER-48877] Create an APIParameters class Created: 15/Jun/20 Updated: 29/Oct/23 Resolved: 21/Jul/20 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Replication |
| Affects Version/s: | None |
| Fix Version/s: | 4.7.0 |
| Type: | Task | Priority: | Major - P3 |
| Reporter: | A. Jesse Jiryu Davis | Assignee: | Pridhvi Vegesna (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: | Repl 2020-07-13, Repl 2020-07-27 | ||||||||||||
| Participants: | |||||||||||||
| Description |
|
Create an APIParameters class with methods getApiVersion, getApiStrict, and getApiDeprecationErrors. This class decorates OperationContext (see the top of read_concern_args.cpp for an example). The reason we need a separate class from APIParametersFromClient is because an IDL-generated class cannot decorate an operation context. In execCommandDatabase/runCommand, add something like: APIParameters::get(opCtx) = APIParameters::fromClient(apiParamsFromClient); ... where apiParamsFromClient is the APIParametersFromClient instance. This change may not be testable until we use the new class for something, e.g. checking if the currently executing command supports the client's requested API version. |
| Comments |
| Comment by Githook User [ 17/Jul/20 ] |
|
Author: {'name': 'PV99', 'email': 'pridhvi.vegesna@mongodb.com', 'username': 'PV99'}Message: |