You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@myfaces.apache.org by Todd Patrick <To...@dtn.com> on 2006/05/04 21:37:24 UTC

1.1.3 returns the error: java.lang.IllegalStateException: ExtensionsFilter not correctly configured. JSF mapping missing. JSF pages not covered.

I downloaded 1.1.3 Nightly build and I am trying to configure my web.xml
file as such:
 
<?xml version="1.0" encoding="UTF-8"?>
<web-app version="2.4" xmlns="http://java.sun.com/xml/ns/j2ee
<http://java.sun.com/xml/ns/j2ee> "
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance
<http://www.w3.org/2001/XMLSchema-instance> "
xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee
<http://java.sun.com/xml/ns/j2ee>
http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd
<http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd> ">
    <context-param>
        <param-name>com.sun.faces.verifyObjects</param-name>
        <param-value>true</param-value>
    </context-param>
    <context-param>
        <param-name>com.sun.faces.validateXml</param-name>
        <param-value>true</param-value>
    </context-param>
    <context-param>
        <param-name>javax.faces.CONFIG_FILES</param-name>
        <param-value>/WEB-INF/faces-config.xml</param-value>
    </context-param>
    <context-param>
        <param-name>javax.faces.STATE_SAVING_METHOD</param-name>
        <param-value>client</param-value>
    </context-param>
    <context-param>
 
<param-name>org.apache.myfaces.CHECK_EXTENSIONS_FILTER</param-name>
        <param-value>false</param-value>
    </context-param>
    <servlet>
        <servlet-name>Faces Servlet</servlet-name>
        <servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
        <load-on-startup>1</load-on-startup>
    </servlet>
    <servlet-mapping>
        <servlet-name>Faces Servlet</servlet-name>
        <url-pattern>/transactionbrowser/*</url-pattern>
    </servlet-mapping>
    <session-config>
        <session-timeout>
            30
        </session-timeout>
    </session-config>
    <welcome-file-list>
        <welcome-file>
            index.jsp
        </welcome-file>
    </welcome-file-list>
    <!-- Extensions Filter -->
    <filter>
        <filter-name>MyFacesExtensionsFilter</filter-name>
 
<filter-class>org.apache.myfaces.webapp.filter.ExtensionsFilter</filter-
class>
        <init-param>
            <param-name>maxFileSize</param-name>
            <param-value>20m</param-value>
        </init-param>
    </filter>
    <filter-mapping>
        <filter-name>MyFacesExtensionsFilter</filter-name>
        <servlet-name>Faces Servlet</servlet-name>
    </filter-mapping>
    <filter-mapping>
        <filter-name>MyFacesExtensionsFilter</filter-name>
        <url-pattern>/transactionbrowser/*</url-pattern>
    </filter-mapping>
</web-app>

 
However, I keep receiving the error message:
 
java.lang.IllegalStateException: ExtensionsFilter not correctly
configured. JSF mapping missing. JSF pages not covered. Please see:
http://myfaces.apache.org/tomahawk/extensionsFilter.html
<http://myfaces.apache.org/tomahawk/extensionsFilter.html> 
 
 
I found a similar thread about 1.1.2, however how do I fix this issue in
1.1.3?
 
I am using Sun Java System Application Server 8.2
 
Thanks,
 
--Todd

Re: 1.1.3 returns the error: java.lang.IllegalStateException: ExtensionsFilter not correctly configured. JSF mapping missing. JSF pages not covered.

Posted by Mario Ivankovits <ma...@ops.co.at>.
Hi Todd!
>     <context-param>
>        
> <param-name>org.apache.myfaces.CHECK_EXTENSIONS_FILTER</param-name>
>         <param-value>false</param-value>
>     </context-param>

Given that you already told the system to disable this filter check I
bet that the web.xml you edit is not the used by tomcat. Just a wild
guess, dont get it personal :-) - its something happend here now and
then when the deployment didnt do what I expected it to do.
Do you use somethink like a "exploded" tomcat directory, or a
eclipse/idea whatever automatic deployment?
If so, please look at the exploded web.xml.

Ciao,
Mario


Re: 1.1.3 returns the error: java.lang.IllegalStateException: ExtensionsFilter not correctly configured. JSF mapping missing. JSF pages not covered.

Posted by Mike Kienenberger <mk...@gmail.com>.
On 5/4/06, Todd Patrick <To...@dtn.com> wrote:
>
> I downloaded 1.1.3 Nightly build and I am trying to configure my web.xml
> file as such:
>
> <?xml version="1.0" encoding="UTF-8"?>
> <web-app version="2.4" xmlns="http://java.sun.com/xml/ns/j2ee"
> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
> xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee
> http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd">
>     <context-param>
>         <param-name>com.sun.faces.verifyObjects</param-name>
>         <param-value>true</param-value>
>     </context-param>
>     <context-param>
>         <param-name>com.sun.faces.validateXml</param-name>
>         <param-value>true</param-value>
>     </context-param>
>     <context-param>
>         <param-name>javax.faces.CONFIG_FILES</param-name>
>         <param-value>/WEB-INF/faces-config.xml</param-value>
>     </context-param>
>     <context-param>
>         <param-name>javax.faces.STATE_SAVING_METHOD</param-name>
>         <param-value>client</param-value>
>     </context-param>
>     <context-param>
>
> <param-name>org.apache.myfaces.CHECK_EXTENSIONS_FILTER</param-name>
>         <param-value>false</param-value>
>     </context-param>
>     <servlet>
>         <servlet-name>Faces Servlet</servlet-name>
>         <servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
>         <load-on-startup>1</load-on-startup>
>     </servlet>
>     <servlet-mapping>
>         <servlet-name>Faces Servlet</servlet-name>
>         <url-pattern>/transactionbrowser/*</url-pattern>
>     </servlet-mapping>
>     <session-config>
>         <session-timeout>
>             30
>         </session-timeout>
>     </session-config>
>     <welcome-file-list>
>         <welcome-file>
>             index.jsp
>         </welcome-file>
>     </welcome-file-list>
>     <!-- Extensions Filter -->
>     <filter>
>         <filter-name>MyFacesExtensionsFilter</filter-name>
>
> <filter-class>org.apache.myfaces.webapp.filter.ExtensionsFilter</filter-class>
>         <init-param>
>             <param-name>maxFileSize</param-name>
>             <param-value>20m</param-value>
>         </init-param>
>     </filter>
>     <filter-mapping>
>         <filter-name>MyFacesExtensionsFilter</filter-name>
>         <servlet-name>Faces Servlet</servlet-name>
>     </filter-mapping>
>     <filter-mapping>
>         <filter-name>MyFacesExtensionsFilter</filter-name>
>         <url-pattern>/transactionbrowser/*</url-pattern>
>     </filter-mapping>
> </web-app>
>
>
>
> However, I keep receiving the error message:
>
> java.lang.IllegalStateException: ExtensionsFilter not correctly configured.
> JSF mapping missing. JSF pages not covered. Please see:
> http://myfaces.apache.org/tomahawk/extensionsFilter.html
>
>
> I found a similar thread about 1.1.2, however how do I fix this issue in
> 1.1.3?

Follow the link given :)

Basically, you've double-configured the part that modifies your JSF
pages, but haven't configured the part that serves independent
resources.

Delete this one:

>     <filter-mapping>
>         <filter-name>MyFacesExtensionsFilter</filter-name>
>         <url-pattern>/transactionbrowser/*</url-pattern>
>     </filter-mapping>

And add in the one on the web page.

Re: 1.1.3 returns the error: java.lang.IllegalStateException: ExtensionsFilter not correctly configured. JSF mapping missing. JSF pages not covered.

Posted by Mike Kienenberger <mk...@gmail.com>.
Todd, in the example below, you have the elements incorrectly ordered
in your file.

The filter then filter-mapping sections of configuration MUST appear
before the servlet sections!

If you're looking at your log files, I'm sure that your container is
complaining about dtd errors in your web.xml file, since the config
you posted below is not a valid dtd ordering.


On 5/4/06, Todd Patrick <To...@dtn.com> wrote:
>
> I downloaded 1.1.3 Nightly build and I am trying to configure my web.xml
> file as such:
>
> <?xml version="1.0" encoding="UTF-8"?>
> <web-app version="2.4" xmlns="http://java.sun.com/xml/ns/j2ee"
> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
> xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee
> http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd">
>     <context-param>
>         <param-name>com.sun.faces.verifyObjects</param-name>
>         <param-value>true</param-value>
>     </context-param>
>     <context-param>
>         <param-name>com.sun.faces.validateXml</param-name>
>         <param-value>true</param-value>
>     </context-param>
>     <context-param>
>         <param-name>javax.faces.CONFIG_FILES</param-name>
>         <param-value>/WEB-INF/faces-config.xml</param-value>
>     </context-param>
>     <context-param>
>         <param-name>javax.faces.STATE_SAVING_METHOD</param-name>
>         <param-value>client</param-value>
>     </context-param>
>     <context-param>
>
> <param-name>org.apache.myfaces.CHECK_EXTENSIONS_FILTER</param-name>
>         <param-value>false</param-value>
>     </context-param>
>     <servlet>
>         <servlet-name>Faces Servlet</servlet-name>
>         <servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
>         <load-on-startup>1</load-on-startup>
>     </servlet>
>     <servlet-mapping>
>         <servlet-name>Faces Servlet</servlet-name>
>         <url-pattern>/transactionbrowser/*</url-pattern>
>     </servlet-mapping>
>     <session-config>
>         <session-timeout>
>             30
>         </session-timeout>
>     </session-config>
>     <welcome-file-list>
>         <welcome-file>
>             index.jsp
>         </welcome-file>
>     </welcome-file-list>
>     <!-- Extensions Filter -->
>     <filter>
>         <filter-name>MyFacesExtensionsFilter</filter-name>
>
> <filter-class>org.apache.myfaces.webapp.filter.ExtensionsFilter</filter-class>
>         <init-param>
>             <param-name>maxFileSize</param-name>
>             <param-value>20m</param-value>
>         </init-param>
>     </filter>
>     <filter-mapping>
>         <filter-name>MyFacesExtensionsFilter</filter-name>
>         <servlet-name>Faces Servlet</servlet-name>
>     </filter-mapping>
>     <filter-mapping>
>         <filter-name>MyFacesExtensionsFilter</filter-name>
>         <url-pattern>/transactionbrowser/*</url-pattern>
>     </filter-mapping>
> </web-app>
>
>
>
> However, I keep receiving the error message:
>
> java.lang.IllegalStateException: ExtensionsFilter not correctly configured.
> JSF mapping missing. JSF pages not covered. Please see:
> http://myfaces.apache.org/tomahawk/extensionsFilter.html
>
>
> I found a similar thread about 1.1.2, however how do I fix this issue in
> 1.1.3?
>
> I am using Sun Java System Application Server 8.2
>
> Thanks,
>
> --Todd