최신 HCAHD Apache-Hadoop-Developer 무료샘플문제:
1. You are developing a combiner that takes as input Text keys, IntWritable values, and emits Text keys, IntWritable values. Which interface should your class implement?
A) Combiner <Text, IntWritable, Text, IntWritable>
B) Reducer <Text, Text, IntWritable, IntWritable>
C) Combiner <Text, Text, IntWritable, IntWritable>
D) Reducer <Text, IntWritable, Text, IntWritable>
E) Mapper <Text, IntWritable, Text, IntWritable>
2. Which two of the following are true about this trivial Pig program' (choose Two)
A) ABC has a schema associated with it
B) myfile is read from the user's home directory in HDFS
C) Pig assumes the contents of myfile are comma delimited
D) The contents of myfile appear on stdout
3. You want to count the number of occurrences for each unique word in the supplied input data. You've decided to implement this by having your mapper tokenize each word and emit a literal value 1, and then have your reducer increment a counter for each literal 1 it
receives. After successful implementing this, it occurs to you that you could optimize this by specifying a combiner. Will you be able to reuse your existing Reduces as your combiner in this case and why or why not?
A) No, because the Reducer and Combiner are separate interfaces.
B) Yes, because the sum operation is both associative and commutative and the input and output types to the reduce method match.
C) No, because the Combiner is incompatible with a mapper which doesn't use the same data type for both the key and value.
D) No, because the sum operation in the reducer is incompatible with the operation of a Combiner.
E) Yes, because Java is a polymorphic object-oriented language and thus reducer code can be reused as a combiner.
4. In the reducer, the MapReduce API provides you with an iterator over Writable values. What does calling the next () method return?
A) It returns a reference to a Writable object. The API leaves unspecified whether this is a reused object or a new object.
B) It returns a reference to a Writable object from an object pool.
C) It returns a reference to the same Writable object each time, but populated with different data.
D) It returns a reference to a different Writable object time.
E) It returns a reference to the same Writable object if the next value is the same as the previous value, or a new Writable object otherwise.
5. Which one of the following statements is true regarding a MapReduce job?
A) The Mapper must sort its output of (key.value) pairs in descending order based on value
B) The job's Partitioner shuffles and sorts all (key.value) pairs and sends the output to all reducers
C) The default Hash Partitioner sends key value pairs with the same key to the same Reducer
D) The reduce method is invoked once for each unique value
질문과 대답:
질문 # 1 정답: D | 질문 # 2 정답: B,D | 질문 # 3 정답: B | 질문 # 4 정답: C | 질문 # 5 정답: B |