Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-70111

ShardingDataTransform Metrics Interface Does Not Indicate Returned Time Value May Be Invalid

    • Sharding NYC
    • ALL

      ShardingDataTransformMetrics uses atomic values to store start and end times for various phases. Since AtomicWord does not support boost::optional, a special value is used to indicate a date is not yet set.

      The interface for accessing this date, however, makes no indication that the returned value may be invalid and instead returns it directly. This is confusing for callers, who may use the value expecting that it always represents a valid time.

      The following functions should be updated to clearly indicate when their values are invalid (e.g. by returning boost::none when they are set to kNoDate):

      Callers of these functions should also be updated to properly consider and handle invalid values.

            Assignee:
            backlog-server-sharding-nyc [DO NOT USE] Backlog - Sharding NYC
            Reporter:
            brett.nawrocki@mongodb.com Brett Nawrocki
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: