Uploaded image for project: 'Apache Ozone'
  1. Apache Ozone
  2. HDDS-5626 Track and Address Flaky tests
  3. HDDS-6470

Fix TestOzoneManagerHAWithData#testOMRestart()

    XMLWordPrintableJSON

Details

    • Sub-task
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • None
    • 1.3.0
    • test

    Description

      This assertion is wrong in TestOzoneManagerHAWithData#testOMRestart().

      Because the lagging follower OM may catch up asynchronously.

          // Restart the stopped OM.
          followerOM1.restart();
       
          // Get the latest snapshotIndex from the leader OM.
          long leaderOMSnaphsotIndex = leaderOM.getRatisSnapshotIndex();
       
          // The recently started OM should be lagging behind the leader OM.
          long followerOMLastAppliedIndex =
              followerOM1.getOmRatisServer().getLastAppliedTermIndex().getIndex();
          Assert.assertTrue(
              followerOMLastAppliedIndex < leaderOMSnaphsotIndex);
      

      Example of CI failure on master: https://github.com/apache/ozone/runs/5593803014

      Result of running this test 100x: https://github.com/kaijchen/ozone/actions/runs/2007487998

      Attachments

        Issue Links

          Activity

            People

              ckj Kaijie Chen
              ckj Kaijie Chen
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: