4 Replies Latest reply on Nov 19, 2009 4:17 AM by Paulo Pinto

    RichFaces example application does not run in LifeRay 5.2.3+

    Paulo Pinto Novice

      Hi everyone,

      not sure if the forum is the best place to ask this, but here it goes.

      I have tried to run the RichFaces example application as a portlet, using the WAR file provided by Exadel here:

      http://www.exadel.com/web/portal/jsfliferay

      I am using the LifeRay on top of Tomcat combination.

      Did anyone else tried such a Portal stack?

      On my case I end up having a bunch of exceptions. :(

      Thanks in advance,
      Paulo

        • 1. Re: RichFaces example application does not run in LifeRay 5.
          Alexander Smirnov Master

          Distribution from Exadel site a little bit outdated. We recently released PotrtletBridge 2.0 that properly uses JSR 286 API and should work better with Liferay.
          All examples have "liferay" profile, so portlets can be built my mvn -P liferay package command.

          • 2. Re: RichFaces example application does not run in LifeRay 5.
            Paulo Pinto Novice

            They still don't seem to work.

            This is the stack trace I get with PortletBridge 2.0.0 Alpha, Tomcat 6.0 and LifeRay 5.2.3


            I know that the 2.0.0 beta has already been release but I can't see it on the Maven repositories.

            16:36:25,381 ERROR [jsp:165] java.lang.ClassNotFoundException: org.ajax4jsf.context.AjaxContextImpl
             at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1387)
             at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1233)
             at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319)
             at java.lang.Class.forName(Class.java:242)
             at org.ajax4jsf.context.AjaxContext.getCurrentInstance(AjaxContext.java:199)
             at org.jboss.portletbridge.richfaces.RichFacesStrategy.setupRenderParams(RichFacesStrategy.java:177)
             at org.jboss.portletbridge.AjaxPortletBridge.doFacesRequest(AjaxPortletBridge.java:491)
             at javax.portlet.faces.GenericFacesPortlet.doFacesDispatch(GenericFacesPortlet.java:583)
             at javax.portlet.faces.GenericFacesPortlet.doView(GenericFacesPortlet.java:474)
             at javax.portlet.GenericPortlet.doDispatch(GenericPortlet.java:328)
             at javax.portlet.faces.GenericFacesPortlet.doDispatch(GenericFacesPortlet.java:445)
             at javax.portlet.GenericPortlet.render(GenericPortlet.java:233)
             at com.sun.portal.portletcontainer.appengine.filter.FilterChainImpl.doFilter(FilterChainImpl.java:126)
             at com.liferay.portal.kernel.portlet.PortletFilterUtil.doFilter(PortletFilterUtil.java:69)
             at com.liferay.portlet.InvokerPortletImpl.invoke(InvokerPortletImpl.java:632)
             at com.liferay.portlet.InvokerPortletImpl.invokeRender(InvokerPortletImpl.java:700)
             at com.liferay.portlet.InvokerPortletImpl.render(InvokerPortletImpl.java:419)
             at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
             at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
             at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:374)
            
            16:36:25,740 INFO [PluginPackageUtil:1347] Checking for available updates
            16:36:25,740 INFO [PluginPackageUtil:1391] Finished checking for available updates in 0 ms
            16:36:26,725 WARN [SkinFactoryImpl:200] Init parameter for a skin name changed to org.richfaces.SKIN
            16:36:34,006 ERROR [InsertTag:922] ServletException in '/html/common/themes/portlet.jsp': File "/welcome.jsf" not found
            javax.servlet.ServletException: File "/welcome.jsf" not found
             at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:319)
             at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:267)
             at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
             at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
             at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
             at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:630)
             at org.apache.catalina.core.ApplicationDispatcher.doInclude(ApplicationDispatcher.java:535)
             at org.apache.catalina.core.ApplicationDispatcher.include(ApplicationDispatcher.java:472)
             at org.apache.jasper.runtime.JspRuntimeLibrary.include(JspRuntimeLibrary.java:968)
             at org.apache.jasper.runtime.PageContextImpl.include(PageContextImpl.java:611)
             at org.apache.struts.tiles.TilesUtilImpl.doInclude(TilesUtilImpl.java:99)
             at org.apache.struts.tiles.TilesUtil.doInclude(TilesUtil.java:135)
             at org.apache.struts.taglib.tiles.InsertTag.doInclude(InsertTag.java:760)
             at org.apache.struts.taglib.tiles.InsertTag$InsertHandler.doEndTag(InsertTag.java:892)
             at org.apache.struts.taglib.tiles.InsertTag.doEndTag(InsertTag.java:462)
             at org.apache.jsp.html.portal.render_005fportlet_jsp._jspService(Unknown Source)
             at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
             at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
             at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:374)
             at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:342)
             at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:267)
             at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
             at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
             at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
             at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:630)
             at org.apache.catalina.core.ApplicationDispatcher.doInclude(ApplicationDispatcher.java:535)
             at org.apache.catalina.core.ApplicationDispatcher.include(ApplicationDispatcher.java:472)
             at com.liferay.portal.util.PortalImpl.renderPortlet(PortalImpl.java:2923)
             at com.liferay.portal.util.PortalImpl.renderPortlet(PortalImpl.java:2844)
             at com.liferay.portal.util.PortalUtil.renderPortlet(PortalUtil.java:885)
             at com.liferay.portal.action.RenderPortletAction.execute(RenderPortletAction.java:96)
             at com.liferay.portal.action.UpdateLayoutAction.addPortlet(UpdateLayoutAction.java:260)
             at com.liferay.portal.action.UpdateLayoutAction.execute(UpdateLayoutAction.java:211)
             at org.apache.struts.action.RequestProcessor.processActionPerform(RequestProcessor.java:431)
             at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:236)
             at com.liferay.portal.struts.PortalRequestProcessor.process(PortalRequestProcessor.java:157)
             at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1196)
             at org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:432)
             at javax.servlet.http.HttpServlet.service(HttpServlet.java:637)
             at com.liferay.portal.servlet.MainServlet.callParentService(MainServlet.java:608)
             at com.liferay.portal.servlet.MainServlet.service(MainServlet.java:846)
             at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
             at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
             at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
             at com.liferay.portal.kernel.servlet.BaseFilter.processFilter(BaseFilter.java:154)
             at com.liferay.portal.servlet.filters.strip.StripFilter.processFilter(StripFilter.java:142)
             at com.liferay.portal.kernel.servlet.BaseFilter.doFilter(BaseFilter.java:91)
             at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
             at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
             at com.liferay.portal.kernel.servlet.BaseFilter.processFilter(BaseFilter.java:154)
             at com.liferay.portal.kernel.servlet.BaseFilter.doFilter(BaseFilter.java:94)
             at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
             at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
             at com.liferay.portal.kernel.servlet.BaseFilter.processFilter(BaseFilter.java:154)
             at com.liferay.portal.servlet.filters.gzip.GZipFilter.processFilter(GZipFilter.java:140)
             at com.liferay.portal.kernel.servlet.BaseFilter.doFilter(BaseFilter.java:91)
             at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
             at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
             at com.liferay.portal.kernel.servlet.BaseFilter.processFilter(BaseFilter.java:154)
             at com.liferay.portal.servlet.filters.secure.SecureFilter.processFilter(SecureFilter.java:282)
             at com.liferay.portal.kernel.servlet.BaseFilter.doFilter(BaseFilter.java:91)
             at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
             at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
             at com.liferay.portal.kernel.servlet.BaseFilter.processFilter(BaseFilter.java:154)
             at com.liferay.portal.sharepoint.SharepointFilter.processFilter(SharepointFilter.java:193)
             at com.liferay.portal.kernel.servlet.BaseFilter.doFilter(BaseFilter.java:91)
             at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
             at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
             at com.liferay.portal.kernel.servlet.BaseFilter.processFilter(BaseFilter.java:154)
             at com.liferay.portal.servlet.filters.virtualhost.VirtualHostFilter.doFilter(VirtualHostFilter.java:191)
             at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
             at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
             at com.liferay.portal.kernel.servlet.BaseFilter.processFilter(BaseFilter.java:154)
             at com.liferay.portal.servlet.filters.threadlocalcache.ThreadLocalCacheFilter.processFilter(ThreadLocalCacheFilter.java:55)
             at com.liferay.portal.kernel.servlet.BaseFilter.doFilter(BaseFilter.java:91)
             at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
             at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
             at com.liferay.portal.kernel.servlet.BaseFilter.processFilter(BaseFilter.java:154)
             at com.liferay.portal.kernel.servlet.BaseFilter.doFilter(BaseFilter.java:94)
             at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
             at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
             at org.tuckey.web.filters.urlrewrite.UrlRewriteFilter.doFilter(UrlRewriteFilter.java:738)
             at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
             at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
             at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
             at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
             at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:433)
             at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
             at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
             at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
             at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:286)
             at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:845)
             at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583)
             at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
             at java.lang.Thread.run(Thread.java:595)
            
            


            • 3. Re: RichFaces example application does not run in LifeRay 5.
              Alexander Smirnov Master

              That seems like classloader isolation problem. According to stack trace, AjaxContext factory tries to install implementtation class, which is in the same web application, but that failed. That means what ContextClassLoader from portlet thread has no access to web application classes, that is Portlet contract violation.
              I've tested these examples with Liferay portal /Jboss AS bundle only that has no classloader problem.
              P.S. All Portletbridge releases are deployed to the Jboss maven repository: http://repository.jboss.com/maven2/

              • 4. Re: RichFaces example application does not run in LifeRay 5.
                Paulo Pinto Novice

                I am running it on top of Tomcat, thanks for your hint, I'll try to see if that is the problem.