Without Book Interview Questions and Answers | Online Test | Moct Test
Download Android App in your Android Device from Google Play Store
- Search for "Withoutbook Practice Exam Test" in Mobile/Tablet Play Store
Institute Training Search by Name or Email

Exams Attended

Make Homepage

Bookmark this page

Subscribe Email Address

Servlets Interview Questions and Answers

Ques 1. What is Servlet?

Ans. A servlet is a Java technology-based Web component, managed by a container called servlet container or servlet engine, that generates dynamic content and interacts with web clients via a request\/response paradigm.

Is it helpful? Add Comment View Comments
Ques 2. Why is Servlet so popular?
Ans. Because servlets are platform-independent Java classes that are compiled to platform-neutral byte code that can be loaded dynamically into and run by a Java technology-enabled Web server.
Is it helpful? Add Comment View Comments
Ques 3. What is servlet container?
Ans. The servlet container is a part of a Web server or application server that provides the network services over which requests and responses are sent, decodes MIME-based requests, and formats MIME-based responses. A servlet container also contains and manages servlets through their lifecycle.
Is it helpful? Add Comment View Comments
Ques 4. When a client request is sent to the servlet container, how does the container choose which servlet to invoke?
Ans. The servlet container determines which servlet to invoke based on the configuration of its servlets, and calls it with objects representing the request and response.
Is it helpful? Add Comment View Comments
Ques 5. If a servlet is not properly initialized, what exception may be thrown?
Ans. During initialization or service of a request, the servlet instance can throw an UnavailableException or a ServletException.
Is it helpful? Add Comment View Comments

Most helpful rated by users:

©2016 WithoutBook