[Spark]Spark core的算子總結

  1. 轉換過濾算子
    map  : (map flatMap mapPartitions mapPartitionWithIndex)     
    filter
  2. ByKey算子
    分組:groupByKey
     排序:sortByKey
     統計:countByKey
     reduce處理:(reduce reduceByKey aggregateByKey)
  3. 獲取算子
    take
     takeSample
     collect
     saveAsTextFile
  4. 兩個集合算子
    交集:intersection 
     並集:union
     笛卡爾積:cartesian
     join 
     cogroup
  5. 單獨集合處理算子
    去重:distinct
     統計:count
  6. partition管理算子
    壓縮:coalesce
     重置:repartition
相關文章
相關標籤/搜索