ExternalSorter
Support sort, aggregate, etc. complicated operations.
Sorts and potentially merges a number of key-value pairs of type (K, V) to produce key-combinerpairs of type (K, C). Uses a Partitioner to first group the keys into partitions, and then optionally sorts keys within each partition using a custom Comparator. Can output a single partitioned file with a different byte range for each partition, suitable for shuffle fetches.