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

Allow writeErrors to be specified via failCommand

    • Type: Icon: Improvement Improvement
    • Resolution: Unresolved
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: None
    • Component/s: None
    • Service Arch
    • 4

      Drivers can currently use failCommand to have the server return {ok: 0} errors and errors in a writeConcernError document. Would it be possible to augment this functionality to return errors in a writeErrors array as well? The motivation for doing so is to test DRIVERS-555. One of the requirements for the project is to convert errors with code 50 (MaxTimeMSExpired) into a client-side TimeoutException. This error can be returned via {ok: 0}, writeErrors, or writeConcernError, so we'd like to be able to test all three formats via failpoints.


      Acceptance Criteria: 

      Add a new option to the failCommand command that allows users to inject an array of write errors. 

            backlog-server-servicearch [DO NOT USE] Backlog - Service Architecture
            divjot.arora@mongodb.com Divjot Arora (Inactive)
            1 Vote for this issue
            5 Start watching this issue