2012-08-17 28 views

回答

0

您還可以通過設置配置運行在本地JobTracker的JVM的開發測試:

Configuration conf = new Configuration(); 
conf.set("fs.default.name", "file:///"); 
conf.set("mapred.job.tracker", "local"); 

Path input = new Path(getClass().getResource("/") + "testfile"); 
Path output = new Path(getClass().getResource("/") + "testfile_output"); 

你可以參考書籍 「Hadoop Definitive Guide」 的第5章

相關問題