tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Adam Posner <cuco2...@gmail.com>
Subject servlet unavailable
Date Sat, 03 Sep 2011 21:36:45 GMT
 Posner to users
show details 8:16 PM (2 minutes ago)

Hello all:


I am hoping someone can help with this.  Tomcat 6.0.28 keeps giving me,
saying 'Servlet Front Controller is not available'
I am using struts 1, the jar file is struts-core-1.3.10 located in
install_dir/myapp/WEB-INF/lib

Please help



?xml version="1.0" encoding="UTF-8"?>
<web-app version="2.5" xmlns="http://java.sun.com/xml/ns/javaee"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd">

    <listener>
    <listener-class>com.listeners.TrailsContextListener</listener-class>
    </listener>

     <context-param>
            <param-name>
            trailsDBConnName
        </param-name>
        <param-value>
          jdbc:mysql://localhost:3306/trailsDB
        </param-value>
    </context-param>


    <!--Define the controller servlet -->

     <servlet>
        <servlet-name>FrontController</servlet-name>

<servlet-class>org.apache.struts.action.ActionServlet</servlet-class>


        <!-- Name the Struts configuration file -->

        <init-param>
            <param-name>config</param-name>
            <param-value>/WEB-INF/struts-config.xml</param-value>
        </init-param>

        <!-- Guarantees that this servlet is loaded on startup  I'm hoping
that this won't interfere with my -->
        <!--    listener declaration above since that also needs to be
initialized first before anything runs -->

       <load-on-startup>2</load-on-startup>
   </servlet>

    <servlet-mapping>
        <servlet-name>FrontController</servlet-name>
        <url-pattern>*.do</url-pattern>
   </servlet-mapping>

    <!-- These other servlets will become Actions, and go in
struts-config.xml file -->
    <!-- I'll leave them here but commented out for now in case you need to
see them

    <servlet>
    <servlet-name>Show Bikes</servlet-name>
    <servlet-class>com.bikes.controller.BikeModelsServlet</servlet-class>
    </servlet>
   <servlet-mapping>
    <servlet-name>Show Bikes</servlet-name>
    <url-pattern>/getBikes.do</url-pattern>
   </servlet-mapping>


    <servlet>
    <servlet-name>Display Characteristics</servlet-name>

<servlet-class>com.bikes.controller.DisplayModelRatingsServlet</servlet-class>
    </servlet>
   <servlet-mapping>
    <servlet-name>Display Characteristics</servlet-name>
    <url-pattern>/getModelInfo.do</url-pattern>
   </servlet-mapping>

   -->

   <!-- Leaving this as is for now -->

      <welcome-file-list>
        <welcome-file>index.jsp</welcome-file>
    </welcome-file-list>

</web-app>

 Reply

Forward



 Ada

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message