2 两种支持得类型 (1)Broadcast 广播变量保存所有节点数据备份。该变量缓存在所有机器上,而不是在有任务的机器上发送。下面的代码块包含了PySpark的广播类的详细信息 1frompysparkimportSparkContext, SparkConf234sc =SparkContext()5words_new = sc.broadcast(['scala'
D.Returning values to the driver 5. How do you create a broadcast variable in PySpark? A.Using sc.broadcast() B.Using sc.createBroadcast() C.Using broadcast() method D.Using createVariable() Show Answer Print Page SubmitReview Advertisements...
Variables of broadcast allow the developers of Spark to keep a secured read only cached variable on different nodes. With the needed tasks, only shipping a copy merely. Without having to waste a lot of time and transfer of network input and output, they can be used in giving a node a la...