-3
A
回答
1
這是字面上上的減速機的Hadoop documentation給出的示例。
public class IntSumReducer extends Reducer {
private IntWritable result = new IntWritable();
public void reduce(Key key, Iterable values,
Context context) throws IOException {
int sum = 0;
for (IntWritable val : values) {
sum += val.get();
}
result.set(sum);
context.collect(key, result);
}
}
相關問題
- 1. HbaseTestingUtility和MapReduce作業
- 2. 剖析MapReduce作業
- 3. GAE的MapReduce:定義參數作業
- 4. 爲MongoDB調度MapReduce作業
- 5. Avro Mapreduce作業失敗org.apache.avro.AvroTypeException
- 6. MapReduce或批處理作業?
- 7. Mapfile作爲MapReduce作業的輸入
- 8. 爲什麼AWS MapReduce中的彈性MapReduce作業流失敗?
- 9. 亞馬遜MapReduce沒有reducer作業
- 10. python mapreduce作業返回錯誤
- 11. 在Hadoop中鏈接多個MapReduce作業
- 12. 包含HTML標記的Hadoop MapReduce作業
- 13. MapReduce作業所花費的時間
- 14. 在Hadoop mapreduce作業中重用JVM
- 15. 編寫一個空的MapReduce作業
- 16. 停止MapReduce作業,RunningJob#killJob vs YarnClient#killApplication
- 17. 遠程啓動Amazon Elastic MapReduce作業?
- 18. Hadoop MapReduce作業權限被拒絕
- 19. (Hadoop)MapReduce - 鏈作業 - JobControl不停止
- 20. mapreduce - 找不到帶作業ID的MR
- 21. 如何遠程運行mapreduce作業
- 22. 配置的MapReduce作業提交
- 23. MapReduce作業中的多個鍵
- 24. 從jsp運行mapreduce作業servlet
- 25. 使用純文本輸入和avro輸出的mapreduce作業
- 26. 使用mapreduce作業連接到MySql數據庫時出錯
- 27. Mapreduce combinefileinputformat java.lang.reflect.InvocationTargetException當兩個作業訪問相同的數據時
- 28. 在mapreduce作業中,何時將數據寫入磁盤?
- 29. 如何增加WSO2 BAM上的MapReduce作業的數量
- 30. Cassandra和MapReduce - 最低設置要求