3 Replies Latest reply on Aug 13, 2009 10:11 AM by ambrish_kumar

    SEAM 2.2.0 on Jboss 4.2 Server - AJAX request timeout

    ambrish_kumar

      Hi Everyone,


      We have just upgrade our project from SEAM 2.0 to SEAM 2.2.0.


      We are using Jboss Server 4.2.


      Everything is fine but when we send an AJAX request (RichFaces) then it timeout and nothing happens.


      I am rendering a Modal Panel on button click. After clicking on button, AJAX request goes but no Modal Panel is displaying and the request timeout.


      What's the reason?


      Should I upgrade the Jboss Server as I read a post here :


      Jboss 4.2 and SEAM 2.2.0


      Which JAR files are placed in Jboss Server 4.2?


      Thanks


      Ambrish

        • 1. Re: SEAM 2.2.0 on Jboss 4.2 Server - AJAX request timeout
          ambrish_kumar

          Hi Everyone,


          Here is my components.xml file :




          <?xml version="1.0" encoding="UTF-8"?>
          <components xmlns="http://jboss.com/products/seam/components"
               xmlns:core="http://jboss.com/products/seam/core"
               xmlns:pdf="http://jboss.com/products/seam/pdf"
               xmlns:framework="http://jboss.com/products/seam/framework"
               xmlns:persistence="http://jboss.com/products/seam/persistence"
               xmlns:drools="http://jboss.com/products/seam/drools"
               xmlns:bpm="http://jboss.com/products/seam/bpm"
               xmlns:security="http://jboss.com/products/seam/security"
               xmlns:theme="http://jboss.com/products/seam/theme"
               xmlns:international="http://jboss.com/products/seam/international"
               xmlns:mail="http://jboss.com/products/seam/mail"
               xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
               xsi:schemaLocation="http://jboss.com/products/seam/core http://jboss.com/products/seam/core-2.2.xsd 
                           http://jboss.com/products/seam/persistence http://jboss.com/products/seam/persistence-2.2.xsd 
                           http://jboss.com/products/seam/drools http://jboss.com/products/seam/drools-2.2.xsd
                           http://jboss.com/products/seam/bpm http://jboss.com/products/seam/bpm-2.2.xsd
                           http://jboss.com/products/seam/security http://jboss.com/products/seam/security-2.2.xsd
                           http://jboss.com/products/seam/pdf http://jboss.com/products/seam/pdf-2.2.xsd
                           http://jboss.com/products/seam/mail http://jboss.com/products/seam/mail-2.2.xsd
                           http://jboss.com/products/seam/framework http://jboss.com/products/seam/framework-2.2.xsd
                           http://jboss.com/products/seam/components http://jboss.com/products/seam/components-2.2.xsd">
          
          
                          
               <core:init debug="true" jndi-pattern="@jndiPattern@" transaction-management-enabled="true"/> 
          
               <core:manager concurrent-request-timeout="10000"
                    conversation-timeout="200000" conversation-id-parameter="cid" /> 
          
               <persistence:managed-persistence-context name="entityManager"
                    auto-create="true" 
                    persistence-unit-jndi-name="java:/TelnetEntityManagerFactory">
               </persistence:managed-persistence-context>          
          
               <security:identity
                    authenticate-method="#{authenticator.authenticate}" remember-me="true" />
          
           
               <mail:mail-session host="localhost" port="2525" username="test"
                    password="test" />
               
               <!--      
               <international:locale-selector cookie-enabled="true"/>
               <theme:theme-selector cookie-enabled="true">     
                -->
          
               <!-- For use with jBPM pageflow or process management -->
               <!--  
                    <bpm:jbpm>
                    <bpm:process-definitions></bpm:process-definitions>
                    <bpm:pageflow-definitions></bpm:pageflow-definitions>
                    </bpm:jbpm>
               -->
          
               <!-- File Upload -->
          
               <component class="org.jboss.seam.web.MultipartFilter">
                    <property name="createTempFiles">true</property>
                    <property name="maxRequestSize">4194304</property>
               </component>
               
               <component name="org.jboss.seam.document.documentStore"> 
                  <property name="useExtensions">true</property>
                  <property name="errorPage">/pdfMissing.seam</property>
              </component>     
          
          </components>



          and here is web.xml file,




          <?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">
               
               <session-config>
                      <session-timeout>10</session-timeout>
               </session-config>
          
               <!-- Ajax4jsf -->
          
               <context-param>
                    <param-name>org.richfaces.SKIN</param-name>
                    <param-value>classic</param-value>
               </context-param>
               
               <!-- By Ambrish -->
               
               <context-param>
                           <param-name>org.ajax4jsf.VIEW_HANDLERS</param-name>
                           <param-value>com.sun.facelets.FaceletViewHandler</param-value>
               </context-param>
               
               <filter>
                           <display-name>RichFaces Filter</display-name>
                           <filter-name>richfaces</filter-name>
                           <filter-class>org.ajax4jsf.Filter</filter-class>
               </filter>
               
               <filter-mapping>
                           <filter-name>richfaces</filter-name>
                           <servlet-name>Faces Servlet</servlet-name>
                           <dispatcher>REQUEST</dispatcher>
                           <dispatcher>FORWARD</dispatcher>
                           <dispatcher>INCLUDE</dispatcher>
               </filter-mapping>
          
               <!-- 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>
                  <filter-name>Seam Servlet Filter</filter-name>
                  <filter-class>org.jboss.seam.servlet.SeamServletFilter</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>true</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>
          
               <!-- Seam PDf -->
               <servlet>
                    <servlet-name>Document Store Servlet</servlet-name>
                    <servlet-class>
                         org.jboss.seam.document.DocumentStoreServlet
                    </servlet-class>
               </servlet>
          
               <servlet-mapping>
                    <servlet-name>Document Store Servlet</servlet-name>
                    <url-pattern>*.pdf</url-pattern>
               </servlet-mapping>
               
               <!-- Seam Remoting -->
               <servlet>
                    <servlet-name>Seam Remoting</servlet-name>
                    <servlet-class>
                         org.jboss.seam.remoting.SeamRemotingServlet
                    </servlet-class>
               </servlet>
          
               <servlet-mapping>
                    <servlet-name>Seam Remoting</servlet-name>
                    <url-pattern>/seam/remoting/*</url-pattern>
               </servlet-mapping>
          
          </web-app>




          Is anything wrong in my components.xml and web.xml file ?


          Thanks


          Ambrish


          • 2. Re: SEAM 2.2.0 on Jboss 4.2 Server - AJAX request timeout
            clerum

            Not sure on your issue, but you don't want to upgrade to Server 5.x at this point. Currently (through no fault of seam) it's totally broken for seam with no workarounds.


            Seam deployments and hot deployments in AS 5.1.0

            • 3. Re: SEAM 2.2.0 on Jboss 4.2 Server - AJAX request timeout
              ambrish_kumar

              Hi Everyone,


              Has anyone run SEAM 2.2 applications on Jboss Server 4.2.2 ?.


              Thanks


              Ambrish