What are the lifecycle phases of a JSP?

JSP page looks like a HTML page but is a servlet. When presented with JSP page the JSP engine does the following 7 phases.
  1. Page translation: -page is parsed, and a java file which is a servlet is created.
  2. Page compilation: page is compiled into a class file
  3. Page loading : This class file is loaded.
  4. Create an instance :- Instance of servlet is created
  5. jspInit() method is called
  6. _jspService is called to handle service calls
  7. _jspDestroy is called to destroy it when the servlet is not required.

Search Topics

Popular Posts