JavaPairRDD<String, Integer> pairdd=maprdd.mapToPair(line->{
String arr[] = line.split(",");
return new Tuple2<String,Integer>(arr[0],Integer.parseInt(arr[1]));
}).reduceByKey((x,y)->{
return x+y;
}).filter(我要过滤,这里的参数是 Tuple2的类型,该怎么写);
JavaPairRDD<String, Integer> pairdd=maprdd.mapToPair(line->{
String arr[] = line.split(",");
return new Tuple2<String,Integer>(arr[0],Integer.parseInt(arr[1]));
}).reduceByKey((x,y)->{
return x+y;
}).filter(我要过滤,这里的参数是 Tuple2的类型,该怎么写);