[Spark應用]-- spark 二次排序實現

1、文本格式(sort.txt) 1 5 2 4 3 6 1 3 2 1apache   2、編寫類 package com.scala /**  * scala處理二次排序的類  * 須要有參數  */ class SecondSortByK(val first:Int,val second :Int) extends Ordered[SecondSortByK] with Serializab
相關文章
相關標籤/搜索