Exam Certified Associate Developer for Apache Spark All QuestionsBrowse all questions from this exam
Question 141

The code block shown below should adjust the number of partitions used in wide transformations like join() to 32. Choose the response that correctly fills in the numbered blanks within the code block to complete this task.

Code block:

__1__(__2__, __3__)

    Correct Answer: E

    To adjust the number of partitions used in wide transformations like join() to 32 in Spark, the correct method is spark.conf.set. The configuration property that controls the number of partitions for such operations is 'spark.sql.shuffle.partitions', and it should be set to the desired number of partitions as a string. Hence, the correct code block completion is spark.conf.set('spark.sql.shuffle.partitions', '32').

Discussion
cd6a625Option: E

A and E same

cd6a625

nevermind

Sowwy1Option: E

E. 1. spark.conf.set 2. "spark.sql.shuffle.partitions" 3. "32"