LocalDirsHandlerService extends AbstractService { public List<String> getLocalDirs() { return localDirs.getGoodDirs(); } LocalDirsHandlerService(); List<String> getLocalDirs(); List<String> getLogDirs(); List<String> getDiskFullLocalDirs(); List<String> getDiskFullLogDirs(); List<String> getLocalDirsForRead(); List<String> getLocalDirsForCleanup(); List<String> getLogDirsForRead(); List<String> getLogDirsForCleanup(); String getDisksHealthReport(boolean listGoodDirs); boolean areDisksHealthy(); long getLastDisksCheckTime(); Path getLocalPathForWrite(String pathStr); Path getLocalPathForWrite(String pathStr, long size,
      boolean checkWrite); Path getLogPathForWrite(String pathStr, boolean checkWrite); Path getLogPathToRead(String pathStr); static String[] validatePaths(String[] paths);  }
@Test public void testDirStructure() throws Exception { Configuration conf = new YarnConfiguration(); String localDir1 = new File("file: conf.set(YarnConfiguration.NM_LOCAL_DIRS, localDir1); String logDir1 = new File("file: conf.set(YarnConfiguration.NM_LOG_DIRS, logDir1); LocalDirsHandlerService dirSvc = new LocalDirsHandlerService(); dirSvc.init(conf); Assert.assertEquals(1, dirSvc.getLocalDirs().size()); dirSvc.close(); }