Uploaded image for project: 'Hadoop HDFS'
  1. Hadoop HDFS
  2. HDFS-9919

TestStandbyCheckpoints#testNonPrimarySBNUploadFSImage waitForCheckpoint incorrectly

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 3.0.0-alpha1
    • Component/s: test
    • Labels:
      None
    • Target Version/s:

      Description

      In HDFS-9787, it sloved the problem that standby NNs can upload FSImage to ANN after become non-primary standby NN. But in its unit test, it seems there is a small problem. when ANN change state to standby and standby nns should do a checkpoint. And in test, it makes a checpoint check as follow:

          for (int i = 0; i < NUM_NNS; i++) {
            // Once the standby catches up, it should do a checkpoint
            // and save to local directories.
            HATestUtil.waitForCheckpoint(cluster, 1, ImmutableList.of(12));
          }
      

      And in these code, the nnIdx for waitForCheckpoint is always 1, not i. It seems there is no need to check one standby nn's checkpoint NUM_NNS times.

        Attachments

          Activity

            People

            • Assignee:
              linyiqun Yiqun Lin
              Reporter:
              linyiqun Yiqun Lin
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: