250+ TOP MCQs on Thrift with Hadoop and Answers

1. _______ transport is required when using a non-blocking server.
a) TZlibTransport
b) TFramedTransport
c) TMemoryTransport
d) None of the mentioned

Answer: b
Clarification: TFramedTransport sends data in frames, where each frame is preceded by length information.

2. Point out the correct statement.
a) To create a Mahout service, one has to write Thrift files that describe it, generate the code in the destination language
b) Thrift is written in Java
c) Thrift is a lean and clean library
d) None of the mentioned

Answer: c
Clarification: The predefined serialization styles include: binary, HTTP-friendly and compact binary.

3. __________ uses memory for I/O in Thrift.
a) TZlibTransport
b) TFramedTransport
c) TMemoryTransport
d) None of the mentioned

Answer: c
Clarification: The Java implementation uses a simple ByteArrayOutputStream internally.

4. ________ uses blocking socket I/O for transport.
a) TNonblockingServer
b) TSimpleServer
c) TSocket
d) None of the mentioned

Answer: c
Clarification: TFramedTransport must be used with this server.

5. Point out the wrong statement.
a) There are no XML configuration files in Thrift
b) Thrift gives cross-language serialization with lower overhead than alternatives such as SOAP due to use of binary format
c) No framework to code is a feature of Thrift
d) None of the mentioned

Answer: d
Clarification: There are no build dependencies or non-standard software. No mix of incompatible software licenses.

6. Which of the following is a multi-threaded server using non-blocking I/O?
a) TNonblockingServer
b) TSimpleServer
c) TSocket
d) None of the mentioned

Answer: a
Clarification: Java implementation uses NIO channels.

7. __________ is a single-threaded server using standard blocking I/O.
a) TNonblockingServer
b) TSimpleServer
c) TSocket
d) None of the mentioned

  250+ TOP MCQs on Hadoop I/O and Answers

Answer: b
Clarification: TSimpleServer is useful for testing.

8. Which of the following performs compression using zlib?
a) TZlibTransport
b) TFramedTransport
c) TMemoryTransport
d) None of the mentioned

Answer: a
Clarification: TZlibTransport is used in conjunction with another transport. Not available in the Java implementation.

9. ________ is a multi-threaded server using standard blocking I/O.
a) TNonblockingServer
b) TThreadPoolServer
c) TSimpleServer
d) None of the mentioned

Answer: b
Clarification: TFramedTransport must be used with this server.

10. _____________ transport writes to a file.
a) TNonblockingServer
b) TFileTransport
c) TFramedTransport
d) TMemoryTransport

Answer: b
Clarification: TMemoryTransport uses memory for I/O.

Leave a Comment

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

Scroll to Top