A web application with Jsp and Servlet is deployed in Tomcat. And we start accessing that application through web browser. After this if we make any change in servlet and redeploy that new servlet, then we have restart Tomcat to see the changed servlet. But if we make any changes to Jsp we dont have to restart Tomcat. Why is so? Means behind the scene, jsp is translated to servlet and this servlet is catering to requests sent by client.
It is so because for each request,the JSP engine checks the timestamps of the source JSP page and the corresponding servlet class file to determine if the JSP page is new or if it has already been converted into a class file. However, no such check occurs for a servlet. This is why when we access a modified JSP, the JSP engine re-translates it,re-compiles it and then creates a new instance. Hope it helps.