can i call destroy() method in init() method of servlet
Answer Posted / deepesh
Yes, We can call destroy() from init() method but after
coming out from the destroy() it will again process the init
() method like the life cycle has to be. Thus we can not
control the servlet life cycle, though we can call destroy
() from init().
Thanks.
| Is This Answer Correct ? | 2 Yes | 0 No |
Post New Answer View All Answers
How to get the actual path of servlet in server?
Which java framework is most popular?
How to find whether a parameter exists in the request object?
Can servlet have a constructor ?
Is servlet synchronized?
What is servlet in simple terms?
Is dispatcher servlet a singleton?
Why session tracking is needed?
What are the important functions of filters?
What is servlet and its life cycle?
What is servlet lazy loading?
What are the servlet events?
What if you need to span your transaction across multiple servlet invocations?
What are the types of an http request?
Why the container loads server at the application startup and how?