You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Dale Newfield <Da...@Newfield.org> on 2007/10/27 06:18:40 UTC

Re: [struts] What actually processes a JSP file?

I believe there are lots of ways that JSP engines work.  Here's how the 
one in tomcat works:
In my app I have a file named login.jsp.
Inside $CATLINA_HOME (at work/Catalina/localhost/myapp/org/apache/jsp) 
it automatically creates login_jsp.java
Which it then compiles to login_jsp.class
Which it then loads and uses.  This java code calls tag libraries, etc. 
where the OGNL you were asking about earlier might get evaluated.

That class extends org.apache.jasper.runtime.HttpJspBase and implements 
org.apache.jasper.runtime.JspSourceDependent.

HttpJspBase implements javax.servlet.jsp.HttpJspPage, 
javax.servlet.jsp.JspPage, java.io.Serializable, javax.servlet.Servlet, 
javax.servlet.ServletConfig so I assume that's the Servlet you're 
looking for, and likely dictates the lifecycle of org.apache.jsp.login_jsp.

I think this process is related to why you can't serve .jsp content from 
inside .jar's (causing strife to those building struts2 plugins).

-Dale

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org