Replace use of $currentDate with $$NOW in sessions_collection.cpp

XMLWordPrintableJSON

    • Type: Task
    • Resolution: Fixed
    • Priority: Major - P3
    • 4.3.3
    • Affects Version/s: None
    • Component/s: None
    • None
    • Fully Compatible
    • Sharding 2019-12-30, Sharding 2020-01-13
    • None
    • 3
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      $currentDate was deprecated under SERVER-42007. With this deprecation, mongod now logs the following message at server startup:

      2019-12-09T15:17:13.221-0500 W  WRITE    [LogicalSessionCacheRefresh] The $currentDate update operator is deprecated. As an alternative perform updates with an aggregation pipeline and either the 'NOW' or 'CLUSTER_TIME' system variables.
      

      As a replacement, we could use $$NOW within a $expr in the query part of the corresponding update.

            Assignee:
            Tommaso Tocci
            Reporter:
            James Wahlin
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: