93949596979899100101102103
// Run examples TestMiniMRWithDFS.runPI(mr, mr.createJobConf(mrConf)); TestMiniMRWithDFS.runWordCount(mr, mr.createJobConf(mrConf)); } finally { if (dfs != null) { dfs.shutdown(); } if (mr != null) { mr.shutdown(); } } } private static final String DUMMY_ACL = "nouser nogroup";
90919293949596979899100
runProgram(mr, dfs, wordCountPart, inputPath, outputPath, 3, 2, fixedPartitionOutput, null); runNonPipedProgram(mr, dfs, wordCountNoPipes, null); mr.waitUntilIdle(); } finally { mr.shutdown(); dfs.shutdown(); } }
422423424425426427428429430431432
}; validateSeenHistoryEvents(seenEvents, goldLinesExpected); } finally { // stop the MR cluster mrCluster.shutdown(); if (ris != null) { ris.close(); } if (parser != null) {
8889909192939495969798
mr = new MiniMRCluster(2, "file:///", 3); Configuration conf = mr.createJobConf(); runWordCount(conf); runMultiFileWordCount(conf); } finally { if (mr != null) { mr.shutdown(); } } } public static class TrackingTextInputFormat extends TextInputFormat {
780781782783784785786787788789790
logs = fs.globStatus(new Path(namenode+"/logs/part*")); assertTrue("Unexpected map count, logs.length=" + logs.length, logs.length == 1); } finally { if (dfs != null) { dfs.shutdown(); } if (mr != null) { mr.shutdown(); } } } public void testLimits() throws Exception { Configuration conf = new Configuration();
129130131132133134135136137138139
// nothing we can do ignored.printStackTrace(); } if (mr != null) { try { mr.shutdown(); } catch (Exception ignored) { ignored.printStackTrace(); } } }
179180181182183184185186187188189
assertTrue(fileList.length == numMappers); } finally { if (dfs != null) { dfs.shutdown(); } if (mr != null) { mr.shutdown(); } } } }
13711372137313741375137613771378137913801381
logs = fs.listStatus(new Path(namenode+"/logs")); assertTrue("Unexpected map count, logs.length=" + logs.length, logs.length == 2); } finally { if (dfs != null) { dfs.shutdown(); } if (mr != null) { mr.shutdown(); } } } public void testMapCount() throws Exception { String namenode = null;
14241425142614271428142914301431143214331434
logs = fs.listStatus(new Path(namenode+"/logs")); assertTrue("Unexpected map count, logs.length=" + logs.length, logs.length == 2); } finally { if (dfs != null) { dfs.shutdown(); } if (mr != null) { mr.shutdown(); } } } public void testCopyByChunkLimits() throws Exception { Configuration conf = new Configuration();