What is Apache Spark?
Example:
SparkContext sc = new SparkContext("local", "SparkExample");
保存以便复习
保存以便复习
收藏此条目、标记为困难题,或将其加入复习集合。
WithoutBook 将分主题面试题、在线练习测试、教程和对比指南整合到一个响应式学习空间中。
了解热门 Apache Spark 面试题与答案,帮助应届生和有经验的候选人为求职面试做好准备。
了解热门 Apache Spark 面试题与答案,帮助应届生和有经验的候选人为求职面试做好准备。
搜索问题以查看答案。
Example:
SparkContext sc = new SparkContext("local", "SparkExample");
收藏此条目、标记为困难题,或将其加入复习集合。
Example:
val sc = new SparkContext("local", "SparkExample")
收藏此条目、标记为困难题,或将其加入复习集合。
Example:
object MyApp {
def main(args: Array[String]): Unit = {
val sc = new SparkContext("local", "MyApp")
}
}
收藏此条目、标记为困难题,或将其加入复习集合。
Example:
val df = spark.read.json("/path/to/data.json")
收藏此条目、标记为困难题,或将其加入复习集合。
Example:
val mappedRDD = inputRDD.map(x => x * 2)
val result = mappedRDD.reduce((x, y) => x + y)
收藏此条目、标记为困难题,或将其加入复习集合。
Example:
val filteredRDD = inputRDD.filter(x => x > 0)
filteredRDD.toDebugString
收藏此条目、标记为困难题,或将其加入复习集合。
Example:
val inputRDD = sc.parallelize(Seq(1, 2, 3, 4, 5), 2)
收藏此条目、标记为困难题,或将其加入复习集合。
Example:
spark-submit --master yarn --deploy-mode client --num-executors 3 mySparkApp.jar
收藏此条目、标记为困难题,或将其加入复习集合。
Example:
val broadcastVar = sc.broadcast(Array(1, 2, 3))
收藏此条目、标记为困难题,或将其加入复习集合。
Example:
val df = spark.sql("SELECT * FROM table")
收藏此条目、标记为困难题,或将其加入复习集合。
Example:
val cachedRDD = inputRDD.persist(StorageLevel.MEMORY_ONLY)
收藏此条目、标记为困难题,或将其加入复习集合。
Example:
Narrow: map, filter
Wide: groupByKey, reduceByKey
收藏此条目、标记为困难题,或将其加入复习集合。
Example:
val streamingContext = new StreamingContext(sparkContext, Seconds(1))
收藏此条目、标记为困难题,或将其加入复习集合。
Example:
sparkConf.set("spark.serializer", "org.apache.spark.serializer.KryoSerializer")
收藏此条目、标记为困难题,或将其加入复习集合。
Example:
val accumulator = sc.longAccumulator("MyAccumulator")
收藏此条目、标记为困难题,或将其加入复习集合。
Example:
val dag = inputRDD.map(x => x * 2).toDebugString
收藏此条目、标记为困难题,或将其加入复习集合。
Example:
val taskResult = executor.runTask(taskID, taskInfo)
收藏此条目、标记为困难题,或将其加入复习集合。
Example:
val model = new RandomForestClassifier().fit(trainingData)
收藏此条目、标记为困难题,或将其加入复习集合。
Example:
val filteredRDD = inputRDD.filter(x => x > 0)
filteredRDD.count()
收藏此条目、标记为困难题,或将其加入复习集合。
Example:
val resilientRDD = originalRDD.filter(x => x > 0)
收藏此条目、标记为困难题,或将其加入复习集合。
Example:
val groupedRDD = inputRDD.groupByKey()
收藏此条目、标记为困难题,或将其加入复习集合。
Example:
SparkContext sc = new SparkContext("local", "SparkExample")
收藏此条目、标记为困难题,或将其加入复习集合。
Example:
val skewedData = inputRDD.groupByKey(numPartitions)
收藏此条目、标记为困难题,或将其加入复习集合。
Example:
sparkConf.set("spark.locality.wait", "2s")
收藏此条目、标记为困难题,或将其加入复习集合。