struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dale Newfield <D...@Newfield.org>
Subject Re: [struts] What actually processes a JSP file?
Date Sat, 27 Oct 2007 04:18:40 GMT
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


Mime
View raw message