I want to use a RangePartitioner in my Java Spark Application, but I have no clue how to set the two scala parameters scala.math.Ordering<K> evidence$1 and scala.reflect.ClassTag<K> evidence$2. Can someone give me an example?
Here is the link to the JavaDoc of RangePartitioner (it was no help for me because I'm new to Spark and Scala...):
My Code actually looks like:
JavaPairRDD<Integer, String> partitionedRDD = rdd.partitionBy(new RangePartitioner<Integer, String>(10, rdd, true, evidence$1, evidence$2));
If you look at api for
OrderedRDDFunctionsthere is an example on how you can set implicit ordering for your key.I know its a snippet from spark-scala apis, but you can at least infer how to pass your Ordering parameter. For ClassTag type I'd suggest check for generic scala doc or forum. Adding scala tag to question.