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

Add tests to ensure drivers advance $clusterTime from command error responses

    • Type: Icon: Spec Change Spec Change
    • Resolution: Unresolved
    • Priority: Icon: Unknown Unknown
    • None
    • Component/s: Sessions
    • None
    • Needed

      Summary

      Currently the session spec is missing tests to ensure the driver advances $clusterTime from command error responses. This is a problem because it means that an invalid $clusterTime on a session (or worse a client) can causes all commands to fail. If the session doesn't process the $clusterTime from the {ok:0} command response than the session will never advance past the invalid $clusterTime. This becomes more of a problem after DRIVERS-2798 become SDAM no longer ensures the client's $clusterTime will be advanced.

      Add tests to ensure drivers advance $clusterTime from command error responses.

      Motivation

      Who is the affected end user?

      Users.

      How does this affect the end user?

      Availability can suffer.

      How likely is it that this problem or use case will occur?

      After DRIVERS-2798, this can only happen if the server returns an invalid $clusterTime or if the app creates a session with an invalid $clusterTime. So it is unlikely but not impossible.

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

      Outage/unavailability.

      Is this issue urgent?

      Should be completed soon so it can be implemented alongside DRIVERS-2798.

      Is this ticket required by a downstream team?

      No.

      Is this ticket only for tests?

      Drivers should already behavior correctly and will pass the new test(s) automatically.

      Acceptance Criteria

      Tests for various command paths like runCommand, insertOne, bulkWrite, find, aggregate, etc...

            Assignee:
            Unassigned Unassigned
            Reporter:
            shane.harvey@mongodb.com Shane Harvey
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated: