myfaces-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Benjamin Mark <be...@bemar.de>
Subject Re: Tomahawk installation - infinite redirect when configuring extension filters
Date Tue, 19 Oct 2010 10:45:05 GMT
Hi,

thx for your help but it doesn't helped. Already the same problem with 
infinite redirect:

Thats the actuall web.xml

<?xml version="1.0" ?>
<web-app 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"
    version="2.5">

    <!-- RichFaces -->

    <context-param>
        <param-name>org.richfaces.SKIN</param-name>
        <param-value>blueSky</param-value>
    </context-param>

    <!-- Suppress spurious stylesheets -->

    <context-param>
        <param-name>org.richfaces.CONTROL_SKINNING</param-name>
        <param-value>disable</param-value>
    </context-param>

    <context-param>
        <param-name>org.richfaces.CONTROL_SKINNING_CLASSES</param-name>
        <param-value>disable</param-value>
    </context-param>

    <!--
        Change load strategy to DEFAULT to disable sending scripts/styles as
        packs
    -->

    <context-param>
        <param-name>org.richfaces.LoadStyleStrategy</param-name>
        <param-value>ALL</param-value>
    </context-param>

    <context-param>
        <param-name>org.richfaces.LoadScriptStrategy</param-name>
        <param-value>ALL</param-value>
    </context-param>

    <!-- Seam -->

    <listener>
        <listener-class>org.jboss.seam.servlet.SeamListener</listener-class>
    </listener>

    <filter>
        <filter-name>Seam Filter</filter-name>
        <filter-class>org.jboss.seam.servlet.SeamFilter</filter-class>
    </filter>

    <filter-mapping>
        <filter-name>Seam Filter</filter-name>
        <url-pattern>/*</url-pattern>
    </filter-mapping>

    <servlet>
        <servlet-name>Seam Resource Servlet</servlet-name>
        
<servlet-class>org.jboss.seam.servlet.SeamResourceServlet</servlet-class>
    </servlet>

    <servlet-mapping>
        <servlet-name>Seam Resource Servlet</servlet-name>
        <url-pattern>/seam/resource/*</url-pattern>
    </servlet-mapping>

    <!-- Facelets development mode (disable in production) -->

    <context-param>
        <param-name>facelets.DEVELOPMENT</param-name>
        <param-value>@debug@</param-value>
    </context-param>

    <!-- JSF -->

    <context-param>
        <param-name>javax.faces.DEFAULT_SUFFIX</param-name>
        <param-value>.xhtml</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>*.seam</url-pattern>
    </servlet-mapping>
   
    <servlet-mapping>
        <servlet-name>Faces Servlet</servlet-name>
        <url-pattern>/faces/</url-pattern>
    </servlet-mapping>
   

    <security-constraint>
        <display-name>Restrict raw XHTML Documents</display-name>
        <web-resource-collection>
            <web-resource-name>XHTML</web-resource-name>
            <url-pattern>*.xhtml</url-pattern>
        </web-resource-collection>
        <auth-constraint />
    </security-constraint>

    <!--
        uncomment <ejb-local-ref> entries when deploying to GlassFish and
        (optionally) JBoss AS 5
    -->
    <!--
        <ejb-local-ref>
        <ejb-ref-name>creditfriend/AuthenticatorBean/local</ejb-ref-name>
        <ejb-ref-type>Session</ejb-ref-type> <local-home/>
        <local>ch.bemar.creditfriend.action.Authenticator</local>
        </ejb-local-ref>
    -->

    <!--
        Add entries for each EJB session bean which is also a Seam component
        (not required on JBoss AS)
    -->

    <persistence-unit-ref>
        
<persistence-unit-ref-name>creditfriend/pu</persistence-unit-ref-name>
        
<persistence-unit-name>../creditfriend.jar#creditfriend</persistence-unit-name>
        <!--
            The relative reference doesn't work on GlassFish. Instead, 
set the
            <persistence-unit-name> to "creditfriend", package 
persistence.xml in
            the WAR, and add a <jar-file> element in persistence.xml 
with value
            "../../creditfriend.jar".
            <persistence-unit-name>creditfriend</persistence-unit-name>
        -->
    </persistence-unit-ref>

    <filter>
        <filter-name>MyFacesExtensionsFilter</filter-name>
        
<filter-class>org.apache.myfaces.webapp.filter.ExtensionsFilter</filter-class>
        <init-param>
            <param-name>uploadMaxFileSize</param-name>
            <param-value>20m</param-value>
        </init-param>
    </filter>

    <!--
        extension mapping for adding <script/>, <link/>, and other resource
        tags to JSF-pages
    -->
    <filter-mapping>
        <filter-name>MyFacesExtensionsFilter</filter-name>
        <!--
            servlet-name must match the name of your
            javax.faces.webapp.FacesServlet entry
        -->
        <servlet-name>Faces Servlet</servlet-name>
    </filter-mapping>

    <!--
        extension mapping for serving page-independent resources 
(javascript,
        stylesheets, images, etc.)
    -->
    <filter-mapping>
        <filter-name>MyFacesExtensionsFilter</filter-name>
        <url-pattern>/faces/myFacesExtensionResource/*</url-pattern>
    </filter-mapping>
</web-app>



Jakob Korherr schrieb:
> Hi Ben,
>
> Just a shot into the blue, but I noticed that you only mapped your
> Faces Servlet to *.seam, however Tomahawk also expects a mapping of
> "/faces/". If you add this additional mapping, it will maybe work!
>
> Regards,
> Jakob
>
> 2010/10/18 Benjamin Mark <bemar@bemar.de>:
>   
>> Hello,
>>
>> I've installed Tomahawk for JSF 1.2 on my seam-gen project (Seam 2.2.0 GA)
>> like the installation hints from the tomahawk page.
>>
>> Everything seems ok and the Jboss 5.1 server is starting up without any
>> problems. When I connect to my project I get the message from the browser,
>> that the request is redirected to an infinity redirect and can't be
>> processed (all the same Firefox, IE, Chrome). NO error will be printed to
>> log or console.
>>
>> When I remove the filter and filter-mapping stuff from web.xml its working
>> again but I can't use captchas because I'm getting a error/warning that
>> there are no extensionFilters configured.
>>
>> Someone know about that problem?
>>
>> Thx in forward for any hint
>>
>> Ben
>>
>> WEB.XML
>>
>>
>> <?xml version="1.0" ?>
>> <web-app 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"
>>        version="2.5">
>>
>>        <!-- RichFaces -->
>>
>>        <context-param>
>>                <param-name>org.richfaces.SKIN</param-name>
>>                <param-value>blueSky</param-value>
>>        </context-param>
>>
>>        <!-- Suppress spurious stylesheets -->
>>
>>        <context-param>
>>                <param-name>org.richfaces.CONTROL_SKINNING</param-name>
>>                <param-value>disable</param-value>
>>        </context-param>
>>
>>        <context-param>
>>
>> <param-name>org.richfaces.CONTROL_SKINNING_CLASSES</param-name>
>>                <param-value>disable</param-value>
>>        </context-param>
>>
>>        <!--
>>                Change load strategy to DEFAULT to disable sending
>> scripts/styles as
>>                packs
>>        -->
>>
>>        <context-param>
>>                <param-name>org.richfaces.LoadStyleStrategy</param-name>
>>                <param-value>ALL</param-value>
>>        </context-param>
>>
>>        <context-param>
>>                <param-name>org.richfaces.LoadScriptStrategy</param-name>
>>                <param-value>ALL</param-value>
>>        </context-param>
>>
>>        <!-- Seam -->
>>
>>        <listener>
>>
>> <listener-class>org.jboss.seam.servlet.SeamListener</listener-class>
>>        </listener>
>>
>>        <filter>
>>                <filter-name>Seam Filter</filter-name>
>>
>> <filter-class>org.jboss.seam.servlet.SeamFilter</filter-class>
>>        </filter>
>>
>>        <filter-mapping>
>>                <filter-name>Seam Filter</filter-name>
>>                <url-pattern>/*</url-pattern>
>>        </filter-mapping>
>>
>>        <servlet>
>>                <servlet-name>Seam Resource Servlet</servlet-name>
>>
>> <servlet-class>org.jboss.seam.servlet.SeamResourceServlet</servlet-class>
>>        </servlet>
>>
>>        <servlet-mapping>
>>                <servlet-name>Seam Resource Servlet</servlet-name>
>>                <url-pattern>/seam/resource/*</url-pattern>
>>        </servlet-mapping>
>>
>>        <!-- Facelets development mode (disable in production) -->
>>
>>        <context-param>
>>                <param-name>facelets.DEVELOPMENT</param-name>
>>                <param-value>@debug@</param-value>
>>        </context-param>
>>
>>        <!-- JSF -->
>>
>>        <context-param>
>>                <param-name>javax.faces.DEFAULT_SUFFIX</param-name>
>>                <param-value>.xhtml</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>*.seam</url-pattern>
>>        </servlet-mapping>
>>
>>        <security-constraint>
>>                <display-name>Restrict raw XHTML Documents</display-name>
>>                <web-resource-collection>
>>                        <web-resource-name>XHTML</web-resource-name>
>>                        <url-pattern>*.xhtml</url-pattern>
>>                </web-resource-collection>
>>                <auth-constraint />
>>        </security-constraint>
>>
>>        <!--
>>                uncomment <ejb-local-ref> entries when deploying to
>> GlassFish and
>>                (optionally) JBoss AS 5
>>        -->
>>        <!--
>>                <ejb-local-ref>
>>
>> <ejb-ref-name>creditfriend/AuthenticatorBean/local</ejb-ref-name>
>>                <ejb-ref-type>Session</ejb-ref-type> <local-home/>
>>                <local>ch.bemar.creditfriend.action.Authenticator</local>
>>                </ejb-local-ref>
>>        -->
>>
>>        <!--
>>                Add entries for each EJB session bean which is also a Seam
>> component
>>                (not required on JBoss AS)
>>        -->
>>
>>        <persistence-unit-ref>
>>
>> <persistence-unit-ref-name>creditfriend/pu</persistence-unit-ref-name>
>>
>> <persistence-unit-name>../creditfriend.jar#creditfriend</persistence-unit-na
>> me>
>>                <!--
>>                        The relative reference doesn't work on GlassFish.
>> Instead, set the
>>                        <persistence-unit-name> to "creditfriend", package
>> persistence.xml in
>>                        the WAR, and add a <jar-file> element in
>> persistence.xml with value
>>                        "../../creditfriend.jar".
>>
>> <persistence-unit-name>creditfriend</persistence-unit-name>
>>                -->
>>        </persistence-unit-ref>
>>
>>
>>
>>        <filter>
>>                <filter-name>MyFacesExtensionsFilter</filter-name>
>>
>> <filter-class>org.apache.myfaces.webapp.filter.ExtensionsFilter</filter-clas
>> s>
>>                <init-param>
>>                        <param-name>uploadMaxFileSize</param-name>
>>                        <param-value>20m</param-value>
>>                </init-param>
>>        </filter>
>>
>>        <!--
>>                extension mapping for adding <script/>, <link/>, and other
>> resource
>>                tags to JSF-pages
>>        -->
>>        <filter-mapping>
>>                <filter-name>MyFacesExtensionsFilter</filter-name>
>>                <!--
>>                        servlet-name must match the name of your
>>                        javax.faces.webapp.FacesServlet entry
>>                -->
>>                <servlet-name>Faces Servlet</servlet-name>
>>        </filter-mapping>
>>
>>        <!--
>>                extension mapping for serving page-independent resources
>> (javascript,
>>                stylesheets, images, etc.)
>>        -->
>>        <filter-mapping>
>>                <filter-name>MyFacesExtensionsFilter</filter-name>
>>                <url-pattern>/faces/myFacesExtensionResource/*</url-pattern>
>>        </filter-mapping>
>> </web-app>
>>
>>
>>
>>     
>
>
>
>   


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