In which cases Destroy() is invoked?

Answers were Sorted based on User's Feedback



In which cases Destroy() is invoked?..

Answer / n.l.narayana

destroy() method is invoked automatically when ever the
servlet object is removed from the webcontainer
(Tomcat,weblogic,....)

Is This Answer Correct ?    4 Yes 0 No

In which cases Destroy() is invoked?..

Answer / shakir khan

When server wants to remove the servlet from pool,it will
execute the destroy().

destroy() is invoked,when servlet is unloaded from
memory.This is a good place to clean up any resources(Such
as open files or database connections).

Is This Answer Correct ?    1 Yes 0 No

Post New Answer

More Servlets Interview Questions

Why jsp is better than servlet?

0 Answers  


What is Difference between JavaBeans and taglib directives?

3 Answers  


What exactly are the functions of servlet?

0 Answers  


Why do you use session tracking in httpservlet?

0 Answers  


What are sessions in servlets?

0 Answers  






What is the use of RequestDispatcher in servlet?

18 Answers   Accenture, CTS, TCS,


What happens, when client requests for server object, which is not yet loaded into the memory?

2 Answers  


What is the difference between genericservlet and httpservlet

0 Answers  


Explain the difference between servletconfig and servletcontext in servlet?

0 Answers  


What are different Authentication options available in Servlets.

0 Answers  


Explain the servlet filter.

0 Answers  


Hi Friends, Can we make any method thread safe withour synchronized keyword?

2 Answers  


Categories