[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:
Depends
depends on SERVER-48866 Parse Versioned API parameters Closed
is depended on by SERVER-49376 Ensure cursors inherit API settings o... Closed
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: SERVER-48877 Create an APIParameters class
Branch: master
https://github.com/mongodb/mongo/commit/cfd99814027a4972be64742b3dd3de2695c88b84

Generated at Thu Feb 08 05:18:18 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.