6 Replies Latest reply on Sep 11, 2008 8:40 AM by Mike K

    RichFaces 3.2.0 on WebLogic 10 MP1 ?

    Francois Lessard Newbie

      Hi All,

      Was anyone able to run a RichFaces 3.2.0 with MyFaces 1.2.2 on a WebLogic 10 MP1 server ?

      I'm trying to display a simple page with a single rf 3.2.0 component (i.e calendar) and I'm always getting the following exeption :

      java.lang.IllegalStateException: Servlet response already use stream, Writer not possible
      at org.ajax4jsf.webapp.FilterServletResponseWrapper.getWriter(FilterServletResponseWrapper.java:226)
      at org.apache.myfaces.application.jsp.JspViewHandlerImpl.renderView(JspViewHandlerImpl.java:359)
      at org.ajax4jsf.application.ViewHandlerWrapper.renderView(ViewHandlerWrapper.java:108)
      at org.ajax4jsf.application.AjaxViewHandler.renderView(AjaxViewHandler.java:189)
      at org.apache.myfaces.lifecycle.RenderResponseExecutor.execute(RenderResponseExecutor.java:41)
      ...


      The same project works on tomcat 6.016 and WebLogic 10MP1, tomcat 5.5.25 (with RF 3.1.4).

      I would be curious to see a valid web.xml with rf 3.2.0, myFaces 1.2.x that works inside WebLogic 10 MP1 ... :-/

      Is there any vodoo magic to do for such a config ?

      Regards

        • 1. Re: RichFaces 3.2.0 on WebLogic 10 MP1 ?
          Francois Lessard Newbie

          I just tried with Sun Jsf 1.2 RI and it works ... there must be something with WebLogic 10MP1 and myFaces 1.2.2 ... Doh !

          • 2. Re: RichFaces 3.2.0 on WebLogic 10 MP1 ?
            Nick Belaevski Master

            There's an issue described on Bea site about IllegalStateException & MyFaces but I think that's not the reason of this cause. I'll check and let you know

            • 3. Re: RichFaces 3.2.0 on WebLogic 10 MP1 ?
              dwaraknathreddy rachamalla Newbie

              Hi All,

              I am using Rich Faces 3.2.1 With Myfaces 1.2.3 on weblogic 10 MP1.

              I am trying to display simple page with Rich faces (Ajax4JSF) component.

              I am always getting Following exception.
              java.lang.IllegalStateException: Servlet response already use stream, Writer not possible
              at org.ajax4jsf.framework.ajax.xmlfilter.FilterServletResponseWrapper.getWriter(FilterServletResponseWrapper.java:226)
              at org.apache.myfaces.application.jsp.JspViewHandlerImpl.renderView(JspViewHandlerImpl.java:362)
              at org.ajax4jsf.framework.ViewHandlerWrapper.renderView(ViewHandlerWrapper.java:108)
              at org.ajax4jsf.framework.ajax.AjaxViewHandler.renderView(AjaxViewHandler.java:233)
              at org.apache.myfaces.lifecycle.RenderResponseExecutor.execute(RenderResponseExecutor.java:41)
              at org.apache.myfaces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:140)
              at javax.faces.webapp.FacesServlet.service(FacesServlet.java:155)
              at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run(StubSecurityHelper.java:226)
              at weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecurityHelper.java:124)
              at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:283)
              at weblogic.servlet.internal.TailFilter.doFilter(TailFilter.java:26)
              at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:42)
              at org.ajax4jsf.framework.ajax.xmlfilter.BaseXMLFilter.doXmlFilter(BaseXMLFilter.java:127)
              at org.ajax4jsf.framework.ajax.xmlfilter.BaseFilter.doFilter(BaseFilter.java:277)
              at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:42)
              at org.apache.myfaces.webapp.filter.ExtensionsFilter.doFilter(ExtensionsFilter.java:147)
              at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:42)
              at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:3393)
              at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
              at weblogic.security.service.SecurityManager.runAs(Unknown Source)
              at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppServletContext.java:2140)
              at weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletContext.java:2046)
              at weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.java:1366)
              at weblogic.work.ExecuteThread.execute(ExecuteThread.java:200)
              at weblogic.work.ExecuteThread.run(ExecuteThread.java:172)


              My web.xml is like this:
              <?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">
              <display-name>MyProject</display-name>

              <context-param>
              <param-name>javax.faces.STATE_SAVING_METHOD</param-name>
              <param-value>server</param-value>
              </context-param>

              <display-name>RichFaces Filter</display-name>
              <filter-name>richfaces</filter-name>
              <filter-class>org.ajax4jsf.Filter</filter-class>


              <filter-mapping>
              <filter-name>richfaces</filter-name>
              <servlet-name>Faces Servlet</servlet-name>
              REQUEST
              FORWARD
              INCLUDE
              </filter-mapping>

              <listener-class>org.apache.myfaces.webapp.StartupServletContextListener</listener-class>


              <servlet-name>Faces Servlet</servlet-name>
              <servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
              <load-on-startup>1</load-on-startup>

              <servlet-mapping>
              <servlet-name>Faces Servlet</servlet-name>
              <url-pattern>*.jsf</url-pattern>
              </servlet-mapping>
              <welcome-file-list>
              <welcome-file>index.jsf</welcome-file>
              </welcome-file-list>
              </web-app>


              When i remove Rich faces filter from web.xml, my page is displaying properly with out Ajax capabilities. But i need ajax capabilities.

              How to fix this problem, please let me know.

              Regards,
              Dwaraka.

              • 4. Re: RichFaces 3.2.0 on WebLogic 10 MP1 ?
                Nick Belaevski Master

                Dwaraka,

                I've solved the problem on WL 10.3 by replacing out-of-date JSF with new version: https://jira.jboss.org/jira/browse/RF-4415

                • 5. Re: RichFaces 3.2.0 on WebLogic 10 MP1 ?
                  dwaraknathreddy rachamalla Newbie

                  Hi Belaevski,

                  Thanks for your quick reply.
                  We already tried with Sun RI 1.2_07. My sample application working fine. I have to resolve this problem using Myfaces implementation.

                  Is there a way to solve this problem using Myfaces on weblogic 10 MP1?

                  Regards,
                  Dwaraka.

                  • 6. Re: RichFaces 3.2.0 on WebLogic 10 MP1 ?
                    Mike K Newbie

                    Hi Perhaps the Seam BEA10 instructions can be helpful (as richfaces is included in Seam 2.x.x)
                    http://www.seamframework.org/Documentation/RunningSeamExamplesWithBEAWebLogic

                    CU Mike