@Test public void testGetCacheDiskCount() { CacheConfig.setCacheDataDirPrefix(conf, cacheTestDirPrefix); CacheConfig.setCacheDataDirSuffix(conf, "/fcache/"); CacheConfig.setMaxDisks(conf, maxDisks); createCacheDirectoriesForTest(conf); int diskCount = CacheUtil.getCacheDiskCount(conf); assertEquals(diskCount, maxDisks, "Sizes don't match!"); }
public static int getCacheDiskCount(Configuration conf) { return getCacheDiskPathsMap(conf).size(); }
CacheUtil { public static int getCacheDiskCount(Configuration conf) { return getCacheDiskPathsMap(conf).size(); } }
CacheUtil { public static int getCacheDiskCount(Configuration conf) { return getCacheDiskPathsMap(conf).size(); } private  CacheUtil(); }
CacheUtil { public static int getCacheDiskCount(Configuration conf) { return getCacheDiskPathsMap(conf).size(); } private  CacheUtil(); static void createCacheDirectories(Configuration conf); static int getCacheDiskCount(Configuration conf); static HashMap<Integer, String> getCacheDiskPathsMap(final Configuration conf); static String getDirPath(int dirIndex, Configuration conf); static String getLocalPath(String remotePath, Configuration conf, int generationNumber); static String getMetadataFilePath(String remotePath, Configuration conf, int generationNumber); static boolean isMetadataFile(String filePath, Configuration conf); static boolean skipCache(String path, Configuration conf); static List<String> getDirPrefixList(Configuration conf); static String getName(String remotePath); }
CacheUtil { public static int getCacheDiskCount(Configuration conf) { return getCacheDiskPathsMap(conf).size(); } private  CacheUtil(); static void createCacheDirectories(Configuration conf); static int getCacheDiskCount(Configuration conf); static HashMap<Integer, String> getCacheDiskPathsMap(final Configuration conf); static String getDirPath(int dirIndex, Configuration conf); static String getLocalPath(String remotePath, Configuration conf, int generationNumber); static String getMetadataFilePath(String remotePath, Configuration conf, int generationNumber); static boolean isMetadataFile(String filePath, Configuration conf); static boolean skipCache(String path, Configuration conf); static List<String> getDirPrefixList(Configuration conf); static String getName(String remotePath); static final int UNKONWN_GENERATION_NUMBER; static final int DUMMY_MODE_GENERATION_NUMBER; }