Hadoop Questions and Answers – Thrift with Hadoop – 1

This set of Hadoop Multiple Choice Questions & Answers (MCQs) focuses on “Thrift with Hadoop – 1”.

1. Which of the following project is interface definition language for hadoop?
a) Oozie
b) Mahout
c) Thrift
d) Impala
View Answer

Answer: c
Explanation: Thrift is an interface definition language and binary communication protocol that is used to define and create services for numerous languages.

2. Point out the correct statement.
a) Thrift is developed for scalable cross-language services development
b) Thrift includes a complete stack for creating clients and servers
c) The top part of the Thrift stack is generated code from the Thrift definition
d) All of the mentioned
View Answer

Answer: d
Explanation: The services generate from this file client and processor code.

3. __________ is used as a remote procedure call (RPC) framework for facebook.
a) Oozie
b) Mahout
c) Thrift
d) Impala
View Answer

Answer: c
Explanation: In contrast to built-in types, created data structures are sent as a result in generated code.

4. Which of the following is a straightforward binary format?
a) TCompactProtocol
b) TDenseProtocol
c) TBinaryProtocol
d) TSimpleJSONProtocol
View Answer

Answer: c
Explanation: TBinaryProtocol is not optimized for space efficiency.

advertisement

5. Point out the wrong statement.
a) With Thrift, it is not possible to define a service and change the protocol and transport without recompiling the code
b) Thrift includes server infrastructure to tie protocols and transports together, like blocking, non-blocking, and multi threaded servers
c) Thrift supports a number of protocols for service definition
d) None of the mentioned
View Answer

Answer: d
Explanation: The underlying I/O part of the stack is differently implemented for different languages.

6. Which of the following is a more compact binary format?
a) TCompactProtocol
b) TDenseProtocol
c) TBinaryProtocol
d) TSimpleJSONProtocol
View Answer

Answer: a
Explanation: TCompactProtocol is typically more efficient to process as well.

Free 30-Day Python Certification Bootcamp is Live. Join Now!

7. Which of the following format is similar to TCompactProtocol?
a) TCompactProtocol
b) TDenseProtocol
c) TBinaryProtocol
d) TSimpleJSONProtocol
View Answer

Answer: b
Explanation: In TDenseProtocol, stripping off the meta information from what is transmitted.

8. ________ is a write-only protocol that cannot be parsed by Thrift.
a) TCompactProtocol
b) TDenseProtocol
c) TBinaryProtocol
d) TSimpleJSONProtocol
View Answer

Answer: d
Explanation: TSimpleJSONProtocol drops metadata using JSON. Suitable for parsing by scripting languages.

9. Which of the following Uses JSON for encoding of data?
a) TCompactProtocol
b) TDenseProtocol
c) TBinaryProtocol
d) None of the mentioned
View Answer

Answer: d
Explanation: TJSONProtocol is used JSON for encoding of data.

10. _____________ is a human-readable text format to aid in debugging.
a) TMemory
b) TDebugProtocol
c) TBinaryProtocol
d) TSimpleJSONProtocol
View Answer

Answer: b
Explanation: TBinaryProtocol is faster to process than the text protocol but more difficult to debug.

advertisement

Sanfoundry Global Education & Learning Series – Hadoop.

Here’s the list of Best Books in Hadoop.

advertisement
advertisement
Subscribe to our Newsletters (Subject-wise). Participate in the Sanfoundry Certification contest to get free Certificate of Merit. Join our social networks below and stay updated with latest contests, videos, internships and jobs!

Youtube | Telegram | LinkedIn | Instagram | Facebook | Twitter | Pinterest
Manish Bhojasia - Founder & CTO at Sanfoundry
I’m Manish - Founder and CTO at Sanfoundry. I’ve been working in tech for over 25 years, with deep focus on Linux kernel, SAN technologies, Advanced C, Full Stack and Scalable website designs.

You can connect with me on LinkedIn, watch my Youtube Masterclasses, or join my Telegram tech discussions.

If you’re in your 40s–60s and exploring new directions in your career, I also offer mentoring. Learn more here.