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

TestNNStorageRetentionManager#testPurgeMultipleDirs fails

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 2.1.0-beta
    • 2.4.0
    • test
    • None
    • Red Hat Enterprise 6 with Sun Java 1.7 and IBM java 1.6

    • Reviewed

    Description

      The test o.a.h.hdfs.server.namenode.TestNNStorageRetentionManager uses a HashMap(dirRoots) to store the root storages to be mocked for the purging test, which does not have any predictable order. The directories needs be purged are stored in a LinkedHashSet, which has a predictable order. So, when the directories get mocked for the test, they could be already out of
      the order that they were added. Thus, the order that the directories were
      actually purged and the order of them being added to the LinkedHashList could
      be different and cause the test to fail.

      Attachments

        1. HDFS-5244.patch
          0.9 kB
          Jinghui Wang

        Activity

          People

            jwang302 Jinghui Wang
            jwang302 Jinghui Wang
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: