解決MapReduce輸出路徑已存在的問題

當我們寫好一個MapReduce函數時,由於測試,經常需要手動將之前的輸出路徑刪除掉,不然的話,就會報以下的錯誤: 這個時候,我們只需要在我們的Driver端代碼裏面添加以下幾行代碼即可: FileSystem fileSystem = FileSystem.get(configuration); Path outputPath = new Path("output/d=20180
相關文章
相關標籤/搜索