草庐IT

setMapOutputKey

全部标签

hadoop - 即使我设置了 setMapOutputKey 类,但 map 中的键类型不匹配

即使我设置了map输出键类和map输出值类,我仍然从map中得到类型不匹配。这是我的示例代码。publicclassNgramCount{protectedfinalstaticStringRAWCOUNTDIR="raw−counts";publicstaticclasscountMapextendsMapper{privatefinalstaticIntWritableone=newIntWritable(1);publicvoidmap(LongWritablekey,Textvalue,OutputCollectoroutput,Reporterreporter)throwsI