PrepAway - Latest Free Exam Questions & Answers

what the map method accepts and emits?

Which best describes what the map method accepts and emits?

PrepAway - Latest Free Exam Questions & Answers

A.
It accepts a single key-value pair as input and emits a single key and list of corresponding
values as output.

B.
It accepts a single key-value pairs as input and can emit only one key-value pair as output.

C.
It accepts a list key-value pairs as input and can emit only one key-value pair as output.

D.
It accepts a single key-value pairs as input and can emit any number of key-value pair as
output, including zero.

Explanation:
public class Mapper<KEYIN,VALUEIN,KEYOUT,VALUEOUT>
extends Object
Maps input key/value pairs to a set of intermediate key/value pairs.
Maps are the individual tasks which transform input records into a intermediate records. The
transformed intermediate records need not be of the same type as the input records. A given input
pair may map to zero or many output pairs.
Reference: org.apache.hadoop.mapreduce
Class Mapper<KEYIN,VALUEIN,KEYOUT,VALUEOUT>

2 Comments on “what the map method accepts and emits?


Leave a Reply

Your email address will not be published. Required fields are marked *