Uploaded image for project: 'Drivers'
  1. Drivers
  2. DRIVERS-1385

Make retryable write test error labels behave consistently with server

    XMLWordPrintableJSON

Details

    • Spec Change
    • Status: Implementing
    • Major - P3
    • Resolution: Unresolved
    • None
    • Retryability
    • Needed
    • Hide

      Drivers should sync the retryable-writes and transaction spec tests updated in the following commits:

      Show
      Drivers should sync the retryable-writes and transaction spec tests updated in the following commits: mongodb/specifications@ab48c57 (legacy and unified tests) mongodb/specifications@5645474 (legacy tests)

    Description

      Summary

      Drivers should sync the tests updated in this commit.

      In our retryable writes spec tests, when a RetryableWriteError label is returned on a writeConcernError, we use fail points to include the label in the writeConcernError object, rather than as a top-level field on the error itself. Here's an example.

      The server always returns error labels as top-level fields, so we should modify our spec tests to do so as well so that drivers do not need to check both the writeConcernError object and the error object for the presence of an error label.

      Motivation

      User reported running while testing Atlas by looping an update one operation during a failover with the default connection string.
      "Test Failover" is often used to mimic Atlas Planned Maintenance by users who are on the Atlas Platform and consists of a very simple election/stepdown process that all clusters/user applications should be able to handle without any downtime.

      If the problem does occur, what are the consequences and how severe are they?

      The write may or may not have been propagated to the servers.

      See also SERVER-51329, SERVER-53624, SERVER-55648, HELP-23256, HELP-30952. In particular, implementations of this ticket should note the more recent observations in JAVA-4244.

      Attachments

        Issue Links

          Activity

            People

              isabel.atkinson@mongodb.com Isabel Atkinson
              emily.giurleo@mongodb.com Emily Giurleo (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              9 Start watching this issue

              Dates

                Created:
                Updated: