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

LazyPersistTestCase wait logic is error-prone

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Minor
    • Resolution: Fixed
    • None
    • 3.3.0, 3.1.4, 3.2.2, 2.10.1
    • None
    • None
    • Reviewed

    Description

      LazyPersistTestCase has some issues hat lead to inconsistent result of the test cases:

      • the wait periods to change of status is too long. It reaches 10 secs in some cases.
      • triggerBlockReport() only triggers FBR of DN with index 0. This is counter intuitive because the JUnit tests restart the DN assuming that the restarted DN will send a FBR. However, this never happens because the DN will get a new index post restart.
        protected final void triggerBlockReport()
            throws IOException, InterruptedException {
          // Trigger block report to NN
          DataNodeTestUtils.triggerBlockReport(cluster.getDataNodes().get(0));
          Thread.sleep(10 * 1000);
        }
      

      inigoiri suggested that we propagate the findings and fixes from HDFS-13179 and HDFS-15144 into LazyPersistTestCase.java. This will eventually reduce the runtime and make the test cases more stable.

      Attachments

        1. HDFS-15147-branch-3.2.001.patch
          41 kB
          Ahmed Hussein
        2. HDFS-15147-branch-2.10.001.patch
          26 kB
          Ahmed Hussein
        3. HDFS-15147.003.patch
          41 kB
          Ahmed Hussein
        4. HDFS-15147.002.patch
          40 kB
          Ahmed Hussein
        5. HDFS-15147.001.patch
          26 kB
          Ahmed Hussein

        Activity

          People

            ahussein Ahmed Hussein
            ahussein Ahmed Hussein
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: