IDEA用childAndParent.join(parentAndChild).var自动生成的代码报错Incompatible equality constraint: String and T2
改了好几次也解决不了。
然后山不转水转,我改写了
List<Tuple2<String, Tuple2<String, String>>> collect = childAndParent.join(parentAndChild).collect();
JavaRDD<Tuple2<String, Tuple2<String, String>>> parallelize = jsc.parallelize(collect);
先转换成List再换回RDD