Uploaded image for project: 'RichFaces'
  1. RichFaces
  2. RF-14172

validator: @event cannot be a ValueExpression

    Details

    • Type: Bug
    • Status: Closed (View Workflow)
    • Priority: Major
    • Resolution: Partially Completed
    • Affects Version/s: 4.5.3, 4.5.10
    • Fix Version/s: 4.5.11
    • Component/s: None
    • Labels:
    • Environment:

      RF 4.5.11-SNAPSHOT
      Tomcat 8

      Description

      In VDL doc is written:

      Type: javax.el.ValueExpression (must evaluate to java.lang.String)

      But when you try to change it to e.g.

       #{myBean.value} 

      it won't work, you'll get such exception:

      exception
      
      javax.servlet.ServletException: /components/richValidator/csv.xhtml @row,col <rich:validator> The 'event' attribute for behavior tag must be a literal
      	javax.faces.webapp.FacesServlet.service(FacesServlet.java:667)
      	org.richfaces.tests.metamer.TestIdentityFilter.doFilter(TestIdentityFilter.java:93)
      	org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)
      	org.apache.catalina.filters.SetCharacterEncodingFilter.doFilter(SetCharacterEncodingFilter.java:108)
      
      root cause
      
      javax.faces.view.facelets.FaceletException: /components/richValidator/csv.xhtml @row,col <rich:validator> The 'event' attribute for behavior tag must be a literal
      	com.sun.faces.facelets.tag.AbstractTagLibrary$UserComponentHandlerFactory.createHandler(AbstractTagLibrary.java:344)
      	com.sun.faces.facelets.tag.AbstractTagLibrary.createTagHandler(AbstractTagLibrary.java:723)
      	com.sun.faces.facelets.tag.CompositeTagLibrary.createTagHandler(CompositeTagLibrary.java:194)
      	com.sun.faces.facelets.compiler.TagUnit.createFaceletHandler(TagUnit.java:121)
      	com.sun.faces.facelets.compiler.TextUnit.createFaceletHandler(TextUnit.java:117)
      	com.sun.faces.facelets.compiler.CompilationUnit.getNextFaceletHandler(CompilationUnit.java:115)
      	com.sun.faces.facelets.compiler.TagUnit.getNextHandler(TagUnit.java:125)
      	javax.faces.view.facelets.TagHandler.<init>(TagHandler.java:116)
      	com.sun.faces.facelets.tag.TagHandlerImpl.<init>(TagHandlerImpl.java:58)
      	com.sun.faces.facelets.tag.ui.DefineHandler.<init>(DefineHandler.java:81)
      	sun.reflect.GeneratedConstructorAccessor79.newInstance(Unknown Source)
      	sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
      	java.lang.reflect.Constructor.newInstance(Constructor.java:422)
      	com.sun.faces.facelets.tag.AbstractTagLibrary$HandlerFactory.createHandler(AbstractTagLibrary.java:192)
      	com.sun.faces.facelets.tag.AbstractTagLibrary.createTagHandler(AbstractTagLibrary.java:723)
      	com.sun.faces.facelets.tag.CompositeTagLibrary.createTagHandler(CompositeTagLibrary.java:194)
      	com.sun.faces.facelets.compiler.TagUnit.createFaceletHandler(TagUnit.java:121)
      	com.sun.faces.facelets.compiler.TextUnit.createFaceletHandler(TextUnit.java:117)
      	com.sun.faces.facelets.compiler.CompilationUnit.getNextFaceletHandler(CompilationUnit.java:115)
      	com.sun.faces.facelets.compiler.TagUnit.getNextHandler(TagUnit.java:125)
      	javax.faces.view.facelets.TagHandler.<init>(TagHandler.java:116)
      	com.sun.faces.facelets.tag.TagHandlerImpl.<init>(TagHandlerImpl.java:58)
      	com.sun.faces.facelets.tag.ui.CompositionHandler.<init>(CompositionHandler.java:101)
      	sun.reflect.GeneratedConstructorAccessor92.newInstance(Unknown Source)
      	sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
      	java.lang.reflect.Constructor.newInstance(Constructor.java:422)
      	com.sun.faces.facelets.tag.AbstractTagLibrary$HandlerFactory.createHandler(AbstractTagLibrary.java:192)
      	com.sun.faces.facelets.tag.AbstractTagLibrary.createTagHandler(AbstractTagLibrary.java:723)
      	com.sun.faces.facelets.tag.CompositeTagLibrary.createTagHandler(CompositeTagLibrary.java:194)
      	com.sun.faces.facelets.compiler.TagUnit.createFaceletHandler(TagUnit.java:121)
      	com.sun.faces.facelets.compiler.CompilationUnit.getNextFaceletHandler(CompilationUnit.java:115)
      	com.sun.faces.facelets.compiler.NamespaceUnit.createFaceletHandler(NamespaceUnit.java:82)
      	com.sun.faces.facelets.compiler.CompilationManager.createFaceletHandler(CompilationManager.java:381)
      	com.sun.faces.facelets.compiler.SAXCompiler.doCompile(SAXCompiler.java:468)
      	com.sun.faces.facelets.compiler.SAXCompiler.doCompile(SAXCompiler.java:430)
      	com.sun.faces.facelets.compiler.Compiler.compile(Compiler.java:124)
      	com.sun.faces.facelets.impl.DefaultFaceletFactory.createFacelet(DefaultFaceletFactory.java:481)
      	com.sun.faces.facelets.impl.DefaultFaceletFactory.access$100(DefaultFaceletFactory.java:106)
      	com.sun.faces.facelets.impl.DefaultFaceletFactory$1.newInstance(DefaultFaceletFactory.java:199)
      	com.sun.faces.facelets.impl.DefaultFaceletFactory$1.newInstance(DefaultFaceletFactory.java:197)
      	com.sun.faces.facelets.impl.DefaultFaceletCache$1.newInstance(DefaultFaceletCache.java:86)
      	com.sun.faces.facelets.impl.DefaultFaceletCache$1.newInstance(DefaultFaceletCache.java:81)
      	com.sun.faces.util.ExpiringConcurrentCache$1.call(ExpiringConcurrentCache.java:99)
      	java.util.concurrent.FutureTask.run(FutureTask.java:266)
      	com.sun.faces.util.ExpiringConcurrentCache.get(ExpiringConcurrentCache.java:114)
      	com.sun.faces.facelets.impl.DefaultFaceletCache.getFacelet(DefaultFaceletCache.java:124)
      	com.sun.faces.facelets.impl.DefaultFaceletCache.getFacelet(DefaultFaceletCache.java:63)
      	com.sun.faces.facelets.impl.DefaultFaceletFactory.getFacelet(DefaultFaceletFactory.java:295)
      	com.sun.faces.facelets.impl.DefaultFaceletFactory.getFacelet(DefaultFaceletFactory.java:239)
      	com.sun.faces.application.view.FaceletViewHandlingStrategy.buildView(FaceletViewHandlingStrategy.java:988)
      	com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePhase.java:99)
      	com.sun.faces.lifecycle.Phase.doPhase(Phase.java:101)
      	com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:219)
      	javax.faces.webapp.FacesServlet.service(FacesServlet.java:655)
      	org.richfaces.tests.metamer.TestIdentityFilter.doFilter(TestIdentityFilter.java:93)
      	org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)
      	org.apache.catalina.filters.SetCharacterEncodingFilter.doFilter(SetCharacterEncodingFilter.java:108)
      
      

        Gliffy Diagrams

          Attachments

            Activity

              People

              • Assignee:
                michpetrov Michal Petrov
                Reporter:
                jstefek Jiří Štefek
              • Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: