2 Replies Latest reply on Aug 29, 2011 8:43 AM by Andreas Hartmann-Schneevoigt

    Richfaces on GAE

    Davy De Waele Newbie

      Hi,

       

      I've used the Maven Archetype to create a Richfaces project that can be deployed on GAE.

       

      http://community.jboss.org/wiki/HowToUseRichFaces40WithGoogleAppEngine

       

      I had no issue during the process, and the project was created fine.

       

      Although the basic Richfaces/AJAX components are working fine, I'm having issues with the skinning. When add a simple datatable to the table, following resources cannot be retrieved :

       

      http://localhost:8888/rfRes/skinning.ecss.jsf?db=eAFLq7x7HgAFkAKM

      http://localhost:8888/rfRes/datatable.ecss.jsf?db=eAFLq7x7HgAFkAKM&ln=org.richfaces

      http://localhost:8888/rfRes/datascroller.ecss.jsf?db=eAFLq7x7HgAFkAKM&ln=org.richfaces

       

      Depending on how the project is run (locally or on GAE), I'm getting 2 different exceptions :

       

      When I run the project locally I'm getting the following error :

       

      javax.el.PropertyNotFoundException: Could not find property org.richfaces.images:dsBtnGrad.png in class org.richfaces.resource.ResourceHandlerImpl

                at javax.el.BeanELResolver.toBeanProperty(BeanELResolver.java:430)

                at javax.el.BeanELResolver.getValue(BeanELResolver.java:290)

                at javax.el.CompositeELResolver.getValue(CompositeELResolver.java:231)

                at org.apache.myfaces.el.unified.resolver.FacesCompositeELResolver.getValue(FacesCompositeELResolver.java:142)

                at com.sun.el.parser.AstValue.getValue(AstValue.java:116)

                at com.sun.el.parser.AstValue.getValue(AstValue.java:163)

                at com.sun.el.parser.AstDeferredExpression.getValue(AstDeferredExpression.java:59)

                at com.sun.el.parser.AstCompositeExpression.getValue(AstCompositeExpression.java:64)

                at com.sun.el.ValueExpressionImpl.getValue(ValueExpressionImpl.java:219)

                at org.apache.myfaces.application.ApplicationImpl.evaluateExpressionGet(ApplicationImpl.java:484)

                at org.richfaces.resource.css.CSSVisitorImpl.visitStyleDeclaration(CSSVisitorImpl.java:223)

                at org.richfaces.resource.css.AbstractCSSVisitor.visitStyleRule(AbstractCSSVisitor.java:99)

                at org.richfaces.resource.css.AbstractCSSVisitor.visitRule(AbstractCSSVisitor.java:62)

                at org.richfaces.resource.css.AbstractCSSVisitor.visitStyleSheet(AbstractCSSVisitor.java:49)

                at org.richfaces.resource.CompiledCSSResource.getInputStream(CompiledCSSResource.java:126)

                at org.richfaces.resource.CachedResourceImpl.initialize(CachedResourceImpl.java:178)

                at org.richfaces.resource.ResourceHandlerImpl.handleResourceRequest(ResourceHandlerImpl.java:171)

                at javax.faces.webapp.FacesServlet.service(FacesServlet.java:183)

       

       

      When I run the project inside GAE I'm getting another error :

       

      org.richfaces.resource.ResourceFactoryImpl logResourceProblem: Error creating resource org.richfaces.renderkit.html.images.ButtonBackgroundImage

      java.lang.NoClassDefFoundError: Could not initialize class org.richfaces.resource.ImageType

      at org.richfaces.resource.AbstractJava2DUserResource.<init>(AbstractJava2DUserResource.java:39)

      at org.richfaces.renderkit.html.BaseGradient.<init>(BaseGradient.java:68)

      at org.richfaces.renderkit.html.BaseGradient.<init>(BaseGradient.java:79)

      at org.richfaces.renderkit.html.BaseGradient.<init>(BaseGradient.java:95)

      at org.richfaces.renderkit.html.images.BaseControlBackgroundImage.<init>(BaseControlBackgroundImage.java:38)

      at org.richfaces.renderkit.html.images.ButtonBackgroundImage.<init>(ButtonBackgroundImage.java:35)

      at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)

      at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57)

      at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)

      at java.lang.reflect.Constructor.newInstance(Constructor.java:532)

      at java.lang.Class.newInstance0(Class.java:372)

      at java.lang.Class.newInstance(Class.java:325)

      at org.richfaces.resource.ResourceFactoryImpl.createDynamicUserResourceInstance(ResourceFactoryImpl.java:258)

      at org.richfaces.resource.ResourceFactoryImpl.createHandlerDependentResource(ResourceFactoryImpl.java:319)

      at org.richfaces.resource.ResourceFactoryImpl.createDynamicResource(ResourceFactoryImpl.java:460)

      at org.richfaces.resource.ResourceFactoryImpl.createResource(ResourceFactoryImpl.java:430)

      at org.richfaces.resource.ResourceHandlerImpl.createResource(ResourceHandlerImpl.java:268)

      at org.richfaces.resource.ResourceHandlerImpl.createResource(ResourceHandlerImpl.java:278)

      at org.apache.myfaces.el.unified.resolver.ResourceResolver.getValue(ResourceResolver.java:92)

      at javax.el.CompositeELResolver.getValue(CompositeELResolver.java:231)

      at org.apache.myfaces.el.unified.resolver.FacesCompositeELResolver.getValue(FacesCompositeELResolver.java:142)

      at com.sun.el.parser.AstValue.getValue(AstValue.java:116)

      at com.sun.el.parser.AstValue.getValue(AstValue.java:163)

      at com.sun.el.parser.AstDeferredExpression.getValue(AstDeferredExpression.java:59)

      at com.sun.el.parser.AstCompositeExpression.getValue(AstCompositeExpression.java:64)

      at com.sun.el.ValueExpressionImpl.getValue(ValueExpressionImpl.java:219)

      at org.apache.myfaces.application.ApplicationImpl.evaluateExpressionGet(ApplicationImpl.java:484)

      at org.richfaces.resource.css.CSSVisitorImpl.visitStyleDeclaration(CSSVisitorImpl.java:223)

      at org.richfaces.resource.css.AbstractCSSVisitor.visitStyleRule(AbstractCSSVisitor.java:99)

      at org.richfaces.resource.css.AbstractCSSVisitor.visitRule(AbstractCSSVisitor.java:62)

      at org.richfaces.resource.css.AbstractCSSVisitor.visitStyleSheet(AbstractCSSVisitor.java:49)

      at org.richfaces.resource.CompiledCSSResource.getInputStream(CompiledCSSResource.java:126)

      at org.richfaces.resource.CachedResourceImpl.initialize(CachedResourceImpl.java:178)

      at org.richfaces.resource.ResourceHandlerImpl.handleResourceRequest(ResourceHandlerImpl.java:171)

      at javax.faces.webapp.FacesServlet.service(FacesServlet.java:183)

       

       

      Any ideas on how to fix this ?

        • 1. Re: Richfaces on GAE
          Andreas Hartmann-Schneevoigt Newbie

          Hi i have the same issue running the tree comnponent.

           

          SCHWERWIEGEND: Servlet.service() for servlet [Faces Servlet] in context with path [/topas-server-web] threw exception

          javax.el.PropertyNotFoundException: Property 'org.richfaces.images:node_icon.gif' not found on type org.richfaces.resource.ResourceHandlerImpl

              at javax.el.BeanELResolver$BeanProperties.get(BeanELResolver.java:223)

              at javax.el.BeanELResolver$BeanProperties.access$400(BeanELResolver.java:200)

              at javax.el.BeanELResolver.property(BeanELResolver.java:311)

              at javax.el.BeanELResolver.getValue(BeanELResolver.java:85)

              at javax.el.CompositeELResolver.getValue(CompositeELResolver.java:67)

              at org.apache.myfaces.el.unified.resolver.FacesCompositeELResolver.getValue(FacesCompositeELResolver.java:142)

              at org.apache.el.parser.AstValue.getValue(AstValue.java:169)

              at org.apache.el.parser.AstDeferredExpression.getValue(AstDeferredExpression.java:44)

              at org.apache.el.parser.AstCompositeExpression.getValue(AstCompositeExpression.java:50)

              at org.apache.el.ValueExpressionImpl.getValue(ValueExpressionImpl.java:189)

              at org.apache.myfaces.application.ApplicationImpl.evaluateExpressionGet(ApplicationImpl.java:496)

              at org.richfaces.resource.css.CSSVisitorImpl.visitStyleDeclaration(CSSVisitorImpl.java:212)

              at org.richfaces.resource.css.AbstractCSSVisitor.visitStyleRule(AbstractCSSVisitor.java:98)

              at org.richfaces.resource.css.AbstractCSSVisitor.visitRule(AbstractCSSVisitor.java:61)

              at org.richfaces.resource.css.AbstractCSSVisitor.visitStyleSheet(AbstractCSSVisitor.java:48)

              at org.richfaces.resource.CompiledCSSResource.getInputStream(CompiledCSSResource.java:123)

              at org.richfaces.resource.CachedResourceImpl.initialize(CachedResourceImpl.java:176)

              at org.richfaces.resource.ResourceHandlerImpl.handleResourceRequest(ResourceHandlerImpl.java:167)

              at javax.faces.webapp.FacesServlet.service(FacesServlet.java:183)

           

          The Tree component does not display the "Plus" icon an the nodes.

           

          Any idea?

           

          Forgot to mention that is use Richfaces 4.1.0 M1

          • 2. Re: Richfaces on GAE
            Andreas Hartmann-Schneevoigt Newbie

            Ok after digging around ... i upgraded myfaces to the latest 2.1.2 Release and the Problem is gone.

            Seems that this was a Problem in EL Resolver which used the Bean Resolver insted a Resource Resolver.

             

            Ciao