Class PartitionSorter
- java.lang.Object
-
- com.linkedin.venice.spark.datawriter.partition.PartitionSorter
-
- All Implemented Interfaces:
java.io.Serializable
,java.util.Comparator<org.apache.spark.sql.Row>
public class PartitionSorter extends java.lang.Object implements java.util.Comparator<org.apache.spark.sql.Row>, java.io.Serializable
Sort the rows based on the key and value in ascending order using unsigned byte comparison.- The sorting on the key is the same as what RocksDB and Shuffle-Sort in MapReduce use.
- The sorting on the value is to make
SparkPartitionWriter
be able to optimize the de-duping of values.
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description PartitionSorter()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
compare(org.apache.spark.sql.Row r1, org.apache.spark.sql.Row r2)
-