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

Replace explicit instantiation of OperationContextImpl with cc().makeOperationContext()

    XMLWordPrintable

    Details

    • Type: Task
    • Status: Closed
    • Priority: Major - P3
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 3.3.5
    • Component/s: Internal Code
    • Labels:
      None
    • Backwards Compatibility:
      Fully Compatible
    • Sprint:
      Sharding 13 (04/22/16)
    • Linked BF Score:
      0

      Description

      Rather than instantiating OperationContextImpl directly on the stack and letting its constructor use thread-local variables to initialize itself, tests and other code needing an OperationContext should construct it from the current thread's client object, via cc().makeOperationContext(). This is more consistent with the Service/Client/Operation software architecture in place, and is what mongod and mongos user operations already do.

        Attachments

          Activity

            People

            • Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: