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

branch-1-win TestJobTrackerQuiescence and TestFileLengthOnClusterRestart failed caused by incorrect DFS path construction on Windows

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 1-win
    • Fix Version/s: 1-win
    • Component/s: test
    • Labels:
      None
    • Environment:

      Windows

    • Target Version/s:
    • Hadoop Flags:
      Reviewed

      Description

      TestJobTrackerQuiescence is a test case introduced in https://issues.apache.org/jira/browse/MAPREDUCE-4328.
      Here is the code generating a file path on DFS:

       final Path testDir = 
          new Path(System.getProperty("test.build.data", "/tmp"), "jt-safemode");
      

      This doesn't work on Windows because "test.build.data" would have a driver name with ":" (e.g. D:/hadoop/build/test). However, this is not a valid path name on DFS because colon is disallowed (See DFSUtil#isValidName()).

      A similar problem happens to TestFileLengthOnClusterRestart#testFileLengthWithHSyncAndClusterRestartWithOutDNsRegister()

        Path path = new Path(MiniDFSCluster.getBaseDir().getPath(), "test");
      

        Attachments

        1. HADOOP-9687.1.patch
          1 kB
          Douma Fang

          Issue Links

            Activity

              People

              • Assignee:
                xifang Douma Fang
                Reporter:
                xifang Douma Fang
              • Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: