-
Type: Task
-
Resolution: Done
-
Priority: Major - P3
-
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.
- related to
-
SERVER-23432 Add test ensuring monotonically increasing $inc of fields in a single doc
- Closed