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

ShardingDataTransformInstanceMetrics Unit Test Suite Does Not Cover Interactions with Cumulative Metrics

    • Fully Compatible
    • ALL
    • v6.1
    • Sharding 2022-09-19, Sharding 2022-10-03
    • 2

      Part of the contract between ShardingDataTransformInstanceMetrics (and its child classes) is that they increment their associated cumulative metrics when certain events happen that the cumulative metrics are interested in tracking. For example, reads during the critical section should increment both the instance metrics counter and the cumulative metrics counter. As seen by the bug that currently exists in those permalinks, our unit test suite does not cover this behavior.

      Unit tests should be implemented for all methods in ShardingDataTransformInstanceMetrics and ReshardingMetrics which should update cumulative metrics to be sure that they really do. For example, when a new oplog entry is fetched or when a read comes in during the critical section.

            brett.nawrocki@mongodb.com Brett Nawrocki
            brett.nawrocki@mongodb.com Brett Nawrocki
            0 Vote for this issue
            3 Start watching this issue