Missing topOfOplog in mock donor set in RecipientForgetMigration_WaitUntilStateDocInitialized

XMLWordPrintableJSON

    • Type: Bug
    • Resolution: Fixed
    • Priority: Major - P3
    • 4.9.0
    • Affects Version/s: None
    • Component/s: None
    • None
    • Fully Compatible
    • ALL
    • Repl 2020-12-28
    • 0
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      In TenantMigrationRecipientServiceTest, we use insertTopOfOplog to add oplog entries to the mock replica set so that _getStartOpTimesFromDonor can get the startFetchingOptime in unittests. In unittest RecipientForgetMigration_WaitUntilStateDocInitialized, we are missing such step and so sometimes it would hit this uassert that the unittest doesn't expect if the interrupt from onReceiveRecipientForgetMigration comes after the instance runs _getStartOpTimesFromDonor.

      To fix this, use insertTopOfOplog to insert a dummy oplog into the mock replica set like other tests do.

            Assignee:
            Lingzhi Deng
            Reporter:
            Lingzhi Deng
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: