0 Replies Latest reply on Jan 25, 2008 2:44 PM by David Reed

    default servlet handling welcome page prior to filter runnin

    David Reed Newbie

      I'm running JBoss 4.2.2 and have a filter in the ROOT.war WEB-INF/web.xml of the jboss-web.deployer. For some reason though when I request a page like http://host.domain.name/, the default servlet tacks on the index.html (which is a valid file and is one of the entries in the welcome file list of the web.xml) prior to my filter running. My filter is basically like the following:

      <filter>
       <filter-name>RewriteFilter</filter-name>
       <filter-class>my.class.RewriteFilter</filter-class>
      </filter>
      
      <filter-mapping>
       <filter-name>RewriteFilter</filter-name>
       <url-pattern>/*</url-pattern>
      </filter-mapping>
      


      The default servlet portion of the jboss-web.deployer/conf/web.xml is like the following:

      <servlet>
       <servlet-name>default</servlet-name>
       <servlet-class>org.apache.catalina.servlets.DefaultServlet</servlet-class>
       <init-param>
       <param-name>debug</param-name>
       <param-value>0</param-value>
       </init-param>
       <init-param>
       <param-name>listings</param-name>
       <param-value>false</param-value>
       </init-param>
       <load-on-startup>1</load-on-startup>
      </servlet>
      


      Is there something I'm missing? Or will the default servlet always process before my filter?

      Thanks,
      Dave