Results 1 to 2 of 2
  1. #1
    ajeeb is offline Member
    Join Date
    Dec 2008
    Posts
    30
    Rep Power
    0

    Default Tomcat 5.0 and struts-config.xml

    Hi,
    How can I know (looking at the tomcat log) that my struts-config.xml is loaded during server startup.

    My web.xml points to the struts-config.xml as:
    <servlet>
    <servlet-name>action</servlet-name>
    <servlet-class>org.apache.struts.action.Action</servlet-class>
    <init-param>
    <param-name>config</param-name>
    <param-value>/WEB-INF/struts-config.xml</param-value>
    </init-param>
    <load-on-startup>2</load-on-startup>
    </servlet>

    I looked at the tomcat log while startup:

    Jun 7, 2009 3:53:39 PM org.apache.coyote.http11.Http11Protocol init
    INFO: Initializing Coyote HTTP/1.1 on port 8080
    Jun 7, 2009 3:53:39 PM org.apache.catalina.startup.Catalina load
    INFO: Initialization processed in 1219 ms
    Jun 7, 2009 3:53:39 PM org.apache.catalina.core.StandardService start
    INFO: Starting service Catalina
    Jun 7, 2009 3:53:39 PM org.apache.catalina.core.StandardEngine start
    INFO: Starting Servlet Engine: Apache Tomcat/5.0.19
    Jun 7, 2009 3:53:39 PM org.apache.catalina.core.StandardHost start
    INFO: XML validation disabled
    Jun 7, 2009 3:53:40 PM org.apache.catalina.core.StandardHost getDeployer
    INFO: Create Host deployer for direct deployment ( non-jmx )
    Jun 7, 2009 3:53:40 PM org.apache.coyote.http11.Http11Protocol start
    INFO: Starting Coyote HTTP/1.1 on port 8080
    Jun 7, 2009 3:53:40 PM org.apache.jk.common.ChannelSocket init
    INFO: JK2: ajp13 listening on /0.0.0.0:8009
    Jun 7, 2009 3:53:40 PM org.apache.jk.server.JkMain start
    INFO: Jk running ID=0 time=0/219 config=null
    Jun 7, 2009 3:53:40 PM org.apache.catalina.startup.Catalina start
    INFO: Server startup in 1203 ms


    The third last line shows "INFO: Jk running ID=0 time=0/219 config=null". Does this mean that the struts-config.xml is not laoded. In that case, what should be done?

  2. #2
    RamyaSivakanth's Avatar
    RamyaSivakanth is offline Senior Member
    Join Date
    Apr 2009
    Location
    Chennai
    Posts
    832
    Rep Power
    6

    Default

    Hi,
    If any problem is there with struts-config then it might have thrown some parser exception.I don't think problem is there.
    Ramya:cool:

Similar Threads

  1. How do i get connection string from struts-config.xml ?
    By Md Saim in forum Web Frameworks
    Replies: 1
    Last Post: 09-05-2008, 01:20 PM
  2. How to pass two parameter in struts-config using dynaActionForm
    By 82rathi.angara in forum Web Frameworks
    Replies: 2
    Last Post: 06-10-2008, 02:43 PM
  3. Using a variable in Struts config, to redirect
    By vijayr in forum JavaServer Pages (JSP) and JSTL
    Replies: 0
    Last Post: 05-12-2008, 08:33 PM
  4. question about struts-config.xml
    By christina in forum Web Frameworks
    Replies: 2
    Last Post: 02-15-2008, 10:45 AM
  5. struts-config.xml
    By Heather in forum Web Frameworks
    Replies: 2
    Last Post: 01-17-2008, 11:23 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •