Make `ftdc_mirrored_reads.js` wait for FTDC to converge

XMLWordPrintableJSON

    • Type: Bug
    • Resolution: Fixed
    • Priority: Major - P3
    • 7.0.0-rc0
    • Affects Version/s: None
    • Component/s: Internal Code
    • None
    • Service Arch
    • Fully Compatible
    • ALL
    • Service Arch 2023-01-23, Service Arch 2023-02-06, Service Arch 2023-02-20
    • 5
    • None
    • 3
    • None
    • None
    • None
    • None
    • None
    • None

      This is a test only issue, currently only concerning Windows variants. The following assertion is sensitive to the number of reads successfully mirrored by the primary, and observed on secondaries:

          ...
          jsTestLog("Verifying diagnostic collection for mirrored reads on secondaries");
          let mirroredReadsSucceeded = getDiagnosticData(primary).succeeded;
          let mirroredReadsProcessedAfter = getMirroredReadsProcessedAsSecondary();
          assert.eq(mirroredReadsSucceeded, mirroredReadsProcessedAfter - mirroredReadsProcessedBefore);
      }
      rst.stopSet();
      })();
      

      Currently, the test captures FTDC on all members of the replica-set after completing the load operations, which makes the test sensitive to any temporary inaccuracies. This is the case to all linked failures, as shown by the following figure, where the number of processed reads on s0 drops to zero (due to a temporary issue in collected FTDC metrics) and goes back to 200 later on:

      A possible solution is to use assert.soon to ensure all mirrored operations are processed on secondaries, thus tolerating temporary issues with collecting FTDC.

        1. ftdc.png
          193 kB
          Amirsaman Memaripour

            Assignee:
            Jason Chan
            Reporter:
            Amirsaman Memaripour
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: