Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-48877

Create an APIParameters class

    XMLWordPrintableJSON

Details

    • Icon: Task Task
    • Resolution: Fixed
    • Icon: Major - P3 Major - P3
    • 4.7.0
    • None
    • Replication
    • None
    • Fully Compatible
    • Repl 2020-07-13, Repl 2020-07-27

    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.

      Attachments

        Activity

          People

            pridhvi.vegesna@mongodb.com Pridhvi Vegesna (Inactive)
            jesse@mongodb.com A. Jesse Jiryu Davis
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: