When the methods init() and Distroy() will be called?
Answer Posted / abhijitbaji
both init() and destroy() are called only once.
init() at the begining when servlet object is cerated.
destroy() when the servlet object is removed from server(at
shoutdown).
service() is called each time when request comes to servlet.
| Is This Answer Correct ? | 2 Yes | 1 No |
Post New Answer View All Answers
Which method of the httpservletrequest object is used?
What is the difference between using getSession(true) and getSession(false) methods?
What is lazy loading and what is Generic Servlet Class?
Tell us something about servletconfig interface.
What is the GenericServlet class?
When jsessionid is created?
What mechanisms are used by a Servlet Container to maintain session information?
Explain is servlet mapping?
What is the use of servlet wrapper classes?
Which exception is thrown if the servlet is not initialized properly?
What is servlet in web technology?
What are the uses of servlet and what is servlet chaining?
Define the lifecycle for executing a jsp page.
Why do we have servlet wrapper classes?
What's the difference between authentication and authorization?