Explain the lifecycle of a Servlet?
Servlert’s life cycle is the entire process from its creation until its destruction. A Servlet follows this path:
- Initialized by calling init( ) method
- Calls service( ) method to process request
- Terminated by destroy( ) method
Finally, the servlet is nothing but the garbage that gets collected by JVM's garbage collector.