博文

目前显示的是标签为“load-on-startup”的博文

load-on-startup in Servlet

<servlet>           <servlet-name>TimeServlet</servlet-name>           <servlet-class>TimeServlet</servlet-class>           < load-on-startup >1</load-on-startup>      </servlet>      <servlet-mapping>           <servlet-name>TimeServlet</servlet-name>           <url-pattern>/servlet/TestServlet</url-pattern>      </servlet-mapping> The load-on-startup element indicates that this servlet should be loaded (instantiated and have its init() called) on the startup of the web application. The optional contents of these element must be an integer indicating the order in which the servlet should be lo...