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

Invariant on error codes with ErrorExtraInfo for OperationContext markKilled() and timeout

    XMLWordPrintableJSON

Details

    • Icon: Improvement Improvement
    • Resolution: Fixed
    • Icon: Major - P3 Major - P3
    • 4.1.9
    • 4.1.5
    • None
    • None
    • Fully Compatible
    • Service Arch 2018-12-31, Service Arch 2019-01-14, Service Arch 2019-01-28, Service Arch 2019-02-11, Service Arch 2019-02-25, Service Arch 2019-03-11

    Description

      The OperationContext class accepts an ErrorCodes::Error for markKilled() and deadline-setting methods. This error code may be converted to a Status object on checkForInterruptNoAssert() or waitForConditionOrInterruptNoAssertUntil() call. When the error code is one that is associated with an ErrorExtraInfo object, Status construction will fail as we expect Status construction to either include a subclass of ErrorExtraInfo or a BSONObj from which it can be serialized. 

      Until a use case comes up, add an invariant to prevent passing an error code with extra info

      Attachments

        Activity

          People

            mira.carey@mongodb.com Mira Carey
            james.wahlin@mongodb.com James Wahlin
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: