5 Using which one of the given choices will you create an RDD with specific partitioning

0 votes
5)Using which one of the given choices will you create an RDD with specific partitioning?

a)partition(until)

b)rdd.partitioner=Hash

c)Specific partition in transformation

d)We cant create RDD in partition
Nov 22, 2020 in Apache Spark by ritu
• 980 points
212 views

2 answers to this question.

0 votes

Hi@ritu,

Hash Partitioning attempts to spread the data evenly across various partitions based on the key. Object.hashCode method is used to determine the partition in Spark as partition = key.hashCode () % numPartitions. According to me, option B is the right answer.

answered Nov 23, 2020 by MD
• 95,140 points
0 votes

Hi, @Ritu,

option b for you, as Hash Partitioning attempts to spread the data evenly across various partitions based on the key. Object.hashCode method is used to determine the partition in Spark as partition = key.hashCode () % numPartitions.

answered Nov 23, 2020 by Gitika
• 65,870 points

Related Questions In Apache Spark

0 votes
1 answer

7)From Schema RDD, data can be cache by which one of the given choices?

Hi, @Ritu, According to the official documentation of Spark 1.2, ...READ MORE

answered Nov 23, 2020 in Apache Spark by Gitika
• 65,870 points
139 views
0 votes
1 answer
0 votes
1 answer
0 votes
1 answer

12)Which one of the given flows correctly describe the Spark Streaming Architecture?

Hi@ritu, You need to learn the Architecture of ...READ MORE

answered Nov 23, 2020 in Apache Spark by MD
• 95,140 points
143 views
0 votes
1 answer

How can I compare the elements of the RDD using MapReduce?

You have to use the comparison operator ...READ MORE

answered May 24, 2018 in Apache Spark by Shubham
• 13,480 points
1,722 views
0 votes
1 answer

What happens to RDD when one of the nodes goes down?

Whenever a node goes down, Spark knows ...READ MORE

answered Sep 3, 2018 in Apache Spark by nitinrawat895
• 11,380 points
544 views
0 votes
1 answer

4)Spark streaming converts streaming data into DStreams. which one of the given statements about DStreams is True?

Hi@ritu, Spark DStream (Discretized Stream) is the basic ...READ MORE

answered Nov 23, 2020 in Apache Spark by MD
• 95,140 points
160 views