Uploaded image for project: 'Documentation'
  1. Documentation
  2. DOCS-7498

clarify $currentDate behavior does not assure monotonic sequence

    • Type: Icon: Task Task
    • Resolution: Done
    • Priority: Icon: Major - P3 Major - P3
    • Server_Docs_20231030
    • Affects Version/s: None
    • Component/s: Server
    • Labels:
      None

      RE: https://docs.mongodb.org/manual/reference/operator/update/currentDate/

      $currentDate does not provide any assurance that consecutive updates will show an increasing (or even static) value. It is possible for an external client to perform consecutive reads where a field being updated using $currentDate is observed to go backwards.

      This effect can theoretically occur on a standalone server without any changes to the system clock. Although the opportunity for the effect increases with a replica-set (elections) or system clock changes.

            Assignee:
            steve.renaker@mongodb.com Steve Renaker (Inactive)
            Reporter:
            andrew.ryder@mongodb.com Andrew Ryder (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved:
              8 years, 7 weeks, 5 days ago