Uploaded image for project: 'Hadoop Common'
  1. Hadoop Common
  2. HADOOP-13021

Hadoop swift driver unit test should use unique directory for each run

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Open
    • Priority: Major
    • Resolution: Unresolved
    • Affects Version/s: 2.7.2
    • Fix Version/s: None
    • Component/s: fs/swift
    • Labels:

      Description

      Since all "unit test" in swift package are actually functionality test, it requires server's information in the core-site.xml file. However, multiple unit test runs on difference machines using the same core-site.xml file will result in some unit tests failure. For example:
      In TestSwiftFileSystemBasicOps.java
      public void testMkDir() throws Throwable

      { Path path = new Path("/test/MkDir"); fs.mkdirs(path); //success then -so try a recursive operation fs.delete(path, true); }

      It is possible that machine A and B are running "mvn clean install" using same core-site.xml file. However, machine A run testMkDir() first and delete the dir, but machine B just tried to run fs.delete(path,true). It will report failure. This is just an example. There are many similar cases in the unit test sets. I would propose we use a unique dir for each unit test run instead of using "Path path = new Path("/test/MkDir")" for all concurrent runs

        Attachments

        1. HADOOP-13021.001.patch
          45 kB
          Chen He

          Activity

            People

            • Assignee:
              airbots Chen He
              Reporter:
              airbots Chen He
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated: