When the Framework is loaded, it first loaded the Web.xml
file. Then from the Servlet tag of Web.xml, it identifies
the ActionServlet(or the Struts-Cofig.xml). Then from
welcome-file tag of web.xml, it identifies the
first JSP page and runs it. Then when the request comes
through that jsp, from acion-mappings tag of Struts-
Cofig.xml it identifies the request, through path tag
(request name) and input tag (jsp name), through name tag
it identifies which bean is needed to access the data and
through type tag it identifies which Action should be
invoked. Then through the forward tag it identifies to
which jsp it has to forward the response.
load-on-startup element in web.xml
This tips explains the few points on how to use the load-on-startup element on the web.xml file. When erver is starting, it is possible to tell the container to load a servlet on the startup. You can load any number of servlets on the startup. Normally this is done for any initialization purpose. Look into the following example:
<servlet>
<servlet-name>TestServlet</servlet-name>
<servlet-class>TestServlet</servlet-class>
<load-on-startup>1</load-on-startup>
</servlet>
The above example tells the container that the servlet will be loaded at first.The
job sites
http://www.chetanasforum.com/index.php?showforum=4
http://www.chetanasforum.com/index.php?act=announce&f=4&id=4
No comments:
Post a Comment