Details

    • Type: Bug Bug
    • Status: Open
    • Priority: Major Major
    • Resolution: Unresolved
    • Affects Version/s: 2.0.1-core
    • Fix Version/s: 2.1.1-core
    • Component/s: None
    • Labels:
      None
    • Environment:
      Ubuntu, Java 1.6, Jetty or Tomcat 7

      Description

      Same project, with Trinidad 2.0.0 works fine, with Trinidad 2.0.1, "java.lang.UnsupportedOperationException" in pages containing composite components.
      Stack trace:

      java.lang.UnsupportedOperationException
      at javax.faces.view.ViewDeclarationLanguage.retargetMethodExpressions(ViewDeclarationLanguage.java:75)
      at org.apache.myfaces.view.facelets.tag.composite.CompositeComponentResourceTagHandler.applyNextHandler(CompositeComponentResourceTagHandler.java:181)
      at org.apache.myfaces.view.facelets.tag.jsf.ComponentTagHandlerDelegate.apply(ComponentTagHandlerDelegate.java:291)
      at javax.faces.view.facelets.DelegatingMetaTagHandler.apply(DelegatingMetaTagHandler.java:53)
      at javax.faces.view.facelets.DelegatingMetaTagHandler.applyNextHandler(DelegatingMetaTagHandler.java:58)
      at org.apache.myfaces.view.facelets.tag.jsf.ComponentTagHandlerDelegate.apply(ComponentTagHandlerDelegate.java:291)
      at javax.faces.view.facelets.DelegatingMetaTagHandler.apply(DelegatingMetaTagHandler.java:53)
      at javax.faces.view.facelets.CompositeFaceletHandler.apply(CompositeFaceletHandler.java:49)
      at javax.faces.view.facelets.DelegatingMetaTagHandler.applyNextHandler(DelegatingMetaTagHandler.java:58)
      at org.apache.myfaces.view.facelets.tag.jsf.ComponentTagHandlerDelegate.apply(ComponentTagHandlerDelegate.java:291)
      at javax.faces.view.facelets.DelegatingMetaTagHandler.apply(DelegatingMetaTagHandler.java:53)
      at javax.faces.view.facelets.DelegatingMetaTagHandler.applyNextHandler(DelegatingMetaTagHandler.java:58)
      at org.apache.myfaces.view.facelets.tag.jsf.ComponentTagHandlerDelegate.apply(ComponentTagHandlerDelegate.java:291)
      at javax.faces.view.facelets.DelegatingMetaTagHandler.apply(DelegatingMetaTagHandler.java:53)
      at javax.faces.view.facelets.CompositeFaceletHandler.apply(CompositeFaceletHandler.java:49)
      at javax.faces.view.facelets.DelegatingMetaTagHandler.applyNextHandler(DelegatingMetaTagHandler.java:58)
      at org.apache.myfaces.view.facelets.tag.jsf.ComponentTagHandlerDelegate.apply(ComponentTagHandlerDelegate.java:291)
      at javax.faces.view.facelets.DelegatingMetaTagHandler.apply(DelegatingMetaTagHandler.java:53)
      at org.apache.myfaces.view.facelets.compiler.NamespaceHandler.apply(NamespaceHandler.java:57)
      at org.apache.myfaces.view.facelets.compiler.EncodingHandler.apply(EncodingHandler.java:45)
      at org.apache.myfaces.view.facelets.impl.DefaultFacelet.apply(DefaultFacelet.java:151)
      at org.apache.myfaces.view.facelets.FaceletViewDeclarationLanguage.buildView(FaceletViewDeclarationLanguage.java:435)
      at org.apache.myfaces.trinidadinternal.application.ViewDeclarationLanguageFactoryImpl$ChangeApplyingVDLWrapper.buildView(ViewDeclarationLanguageFactoryImpl.java:342)
      at org.apache.myfaces.lifecycle.RenderResponseExecutor.execute(RenderResponseExecutor.java:77)
      at org.apache.myfaces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:241)
      at javax.faces.webapp.FacesServlet.service(FacesServlet.java:199)

      1. autocomplete.zip
        23 kB
        Walter Mourão
      2. autocomplete1.zip
        28 kB
        Walter Mourão

        Activity

        Hide
        Walter Mourão added a comment -

        To test, unzip and "mvn jetty:run", go to "http://localhost:8080/autocompleteTest/faces/start.xhtml". Change the trinidad version in pom.xml to see it working with 2.0.0.

        Show
        Walter Mourão added a comment - To test, unzip and "mvn jetty:run", go to "http://localhost:8080/autocompleteTest/faces/start.xhtml". Change the trinidad version in pom.xml to see it working with 2.0.0.
        Hide
        Scott O'Bryan added a comment -

        Awesome. Thanks for the excellent test case. Walter, I'm going to try and take a look at this but one thing that might help me get further, have you tried this same test case with Mojarra? I'm wondering if this isn't an issue with MyFaces.

        Show
        Scott O'Bryan added a comment - Awesome. Thanks for the excellent test case. Walter, I'm going to try and take a look at this but one thing that might help me get further, have you tried this same test case with Mojarra? I'm wondering if this isn't an issue with MyFaces.
        Hide
        Walter Mourão added a comment -

        Keep it on hold. I will check it out and let you know.

        Show
        Walter Mourão added a comment - Keep it on hold. I will check it out and let you know.
        Hide
        Scott O'Bryan added a comment -

        I tried running this with Mojarra and the error is different:

        javax.faces.view.facelets.TagException: /start.xhtml @24,71 <ajsfc:autocomplete> The following attribute(s) are required, but no values have been supplied for them: value.
        at com.sun.faces.facelets.tag.composite.InterfaceHandler.validateComponent(InterfaceHandler.java:233)
        at com.sun.faces.facelets.tag.composite.InterfaceHandler.apply(InterfaceHandler.java:125)
        at javax.faces.view.facelets.CompositeFaceletHandler.apply(CompositeFaceletHandler.java:98)
        at com.sun.faces.facelets.compiler.NamespaceHandler.apply(NamespaceHandler.java:93)
        at com.sun.faces.facelets.compiler.EncodingHandler.apply(EncodingHandler.java:82)
        at com.sun.faces.facelets.impl.DefaultFacelet.apply(DefaultFacelet.java:152)
        at com.sun.faces.facelets.tag.jsf.CompositeComponentTagHandler.applyCompositeComponent(CompositeComponentTagHandler.java:351)
        at com.sun.faces.facelets.tag.jsf.CompositeComponentTagHandler.applyNextHandler(CompositeComponentTagHandler.java:188)
        at com.sun.faces.facelets.tag.jsf.ComponentTagHandlerDelegateImpl.apply(ComponentTagHandlerDelegateImpl.java:184)
        at javax.faces.view.facelets.DelegatingMetaTagHandler.apply(DelegatingMetaTagHandler.java:120)
        at javax.faces.view.facelets.DelegatingMetaTagHandler.applyNextHandler(DelegatingMetaTagHandler.java:137)
        at com.sun.faces.facelets.tag.jsf.ComponentTagHandlerDelegateImpl.apply(ComponentTagHandlerDelegateImpl.java:184)
        at javax.faces.view.facelets.DelegatingMetaTagHandler.apply(DelegatingMetaTagHandler.java:120)
        at javax.faces.view.facelets.CompositeFaceletHandler.apply(CompositeFaceletHandler.java:98)
        at javax.faces.view.facelets.DelegatingMetaTagHandler.applyNextHandler(DelegatingMetaTagHandler.java:137)
        at com.sun.faces.facelets.tag.jsf.ComponentTagHandlerDelegateImpl.apply(ComponentTagHandlerDelegateImpl.java:184)
        at javax.faces.view.facelets.DelegatingMetaTagHandler.apply(DelegatingMetaTagHandler.java:120)
        at javax.faces.view.facelets.DelegatingMetaTagHandler.applyNextHandler(DelegatingMetaTagHandler.java:137)
        at com.sun.faces.facelets.tag.jsf.ComponentTagHandlerDelegateImpl.apply(ComponentTagHandlerDelegateImpl.java:184)
        at javax.faces.view.facelets.DelegatingMetaTagHandler.apply(DelegatingMetaTagHandler.java:120)
        at javax.faces.view.facelets.CompositeFaceletHandler.apply(CompositeFaceletHandler.java:98)
        at javax.faces.view.facelets.DelegatingMetaTagHandler.applyNextHandler(DelegatingMetaTagHandler.java:137)
        at com.sun.faces.facelets.tag.jsf.ComponentTagHandlerDelegateImpl.apply(ComponentTagHandlerDelegateImpl.java:184)
        at javax.faces.view.facelets.DelegatingMetaTagHandler.apply(DelegatingMetaTagHandler.java:120)
        at com.sun.faces.facelets.compiler.NamespaceHandler.apply(NamespaceHandler.java:93)
        at com.sun.faces.facelets.compiler.EncodingHandler.apply(EncodingHandler.java:82)
        at com.sun.faces.facelets.impl.DefaultFacelet.apply(DefaultFacelet.java:152)
        at com.sun.faces.application.view.FaceletViewHandlingStrategy.buildView(FaceletViewHandlingStrategy.java:744)
        at org.apache.myfaces.trinidadinternal.application.ViewDeclarationLanguageFactoryImpl$ChangeApplyingVDLWrapper.buildView(ViewDeclarationLanguageFactoryImpl.java:342)
        at com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePhase.java:100)
        at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:101)
        at com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:139)
        at javax.faces.webapp.FacesServlet.service(FacesServlet.java:313)
        at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:502)
        at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1157)
        at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl._doFilterImpl(TrinidadFilterImpl.java:293)
        at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl.doFilter(TrinidadFilterImpl.java:199)
        at org.apache.myfaces.trinidad.webapp.TrinidadFilter.doFilter(TrinidadFilter.java:92)
        at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1148)
        at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:387)
        at org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:216)
        at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:181)
        at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:765)
        at org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java:417)
        at org.mortbay.jetty.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:230)
        at org.mortbay.jetty.handler.HandlerCollection.handle(HandlerCollection.java:114)
        at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:152)
        at org.mortbay.jetty.Server.handle(Server.java:324)
        at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:535)
        at org.mortbay.jetty.HttpConnection$RequestHandler.headerComplete(HttpConnection.java:865)
        at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:539)
        at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:212)
        at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:404)
        at org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:409)
        at org.mortbay.thread.QueuedThreadPool$PoolThread.run(QueuedThreadPool.java:520)

        I'm not sure what the ajsfc:autocomplete does, but apparently some of its attributes are not assigned. While I understand this worked with the last release, there has been significant functionality added in 2.0.1 and I'm wondering if you were exploiting a hole before that is no longer present. I'll try to take more of a look but I might need you to research more how trinidad is not interacting with your application correctly and possibly suggest a fix. Additionally, if you want to write a unit test which tests this specific scenario, we can include it in the trinidad builds to make sure it doesn't break in the future.

        Show
        Scott O'Bryan added a comment - I tried running this with Mojarra and the error is different: javax.faces.view.facelets.TagException: /start.xhtml @24,71 <ajsfc:autocomplete> The following attribute(s) are required, but no values have been supplied for them: value. at com.sun.faces.facelets.tag.composite.InterfaceHandler.validateComponent(InterfaceHandler.java:233) at com.sun.faces.facelets.tag.composite.InterfaceHandler.apply(InterfaceHandler.java:125) at javax.faces.view.facelets.CompositeFaceletHandler.apply(CompositeFaceletHandler.java:98) at com.sun.faces.facelets.compiler.NamespaceHandler.apply(NamespaceHandler.java:93) at com.sun.faces.facelets.compiler.EncodingHandler.apply(EncodingHandler.java:82) at com.sun.faces.facelets.impl.DefaultFacelet.apply(DefaultFacelet.java:152) at com.sun.faces.facelets.tag.jsf.CompositeComponentTagHandler.applyCompositeComponent(CompositeComponentTagHandler.java:351) at com.sun.faces.facelets.tag.jsf.CompositeComponentTagHandler.applyNextHandler(CompositeComponentTagHandler.java:188) at com.sun.faces.facelets.tag.jsf.ComponentTagHandlerDelegateImpl.apply(ComponentTagHandlerDelegateImpl.java:184) at javax.faces.view.facelets.DelegatingMetaTagHandler.apply(DelegatingMetaTagHandler.java:120) at javax.faces.view.facelets.DelegatingMetaTagHandler.applyNextHandler(DelegatingMetaTagHandler.java:137) at com.sun.faces.facelets.tag.jsf.ComponentTagHandlerDelegateImpl.apply(ComponentTagHandlerDelegateImpl.java:184) at javax.faces.view.facelets.DelegatingMetaTagHandler.apply(DelegatingMetaTagHandler.java:120) at javax.faces.view.facelets.CompositeFaceletHandler.apply(CompositeFaceletHandler.java:98) at javax.faces.view.facelets.DelegatingMetaTagHandler.applyNextHandler(DelegatingMetaTagHandler.java:137) at com.sun.faces.facelets.tag.jsf.ComponentTagHandlerDelegateImpl.apply(ComponentTagHandlerDelegateImpl.java:184) at javax.faces.view.facelets.DelegatingMetaTagHandler.apply(DelegatingMetaTagHandler.java:120) at javax.faces.view.facelets.DelegatingMetaTagHandler.applyNextHandler(DelegatingMetaTagHandler.java:137) at com.sun.faces.facelets.tag.jsf.ComponentTagHandlerDelegateImpl.apply(ComponentTagHandlerDelegateImpl.java:184) at javax.faces.view.facelets.DelegatingMetaTagHandler.apply(DelegatingMetaTagHandler.java:120) at javax.faces.view.facelets.CompositeFaceletHandler.apply(CompositeFaceletHandler.java:98) at javax.faces.view.facelets.DelegatingMetaTagHandler.applyNextHandler(DelegatingMetaTagHandler.java:137) at com.sun.faces.facelets.tag.jsf.ComponentTagHandlerDelegateImpl.apply(ComponentTagHandlerDelegateImpl.java:184) at javax.faces.view.facelets.DelegatingMetaTagHandler.apply(DelegatingMetaTagHandler.java:120) at com.sun.faces.facelets.compiler.NamespaceHandler.apply(NamespaceHandler.java:93) at com.sun.faces.facelets.compiler.EncodingHandler.apply(EncodingHandler.java:82) at com.sun.faces.facelets.impl.DefaultFacelet.apply(DefaultFacelet.java:152) at com.sun.faces.application.view.FaceletViewHandlingStrategy.buildView(FaceletViewHandlingStrategy.java:744) at org.apache.myfaces.trinidadinternal.application.ViewDeclarationLanguageFactoryImpl$ChangeApplyingVDLWrapper.buildView(ViewDeclarationLanguageFactoryImpl.java:342) at com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePhase.java:100) at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:101) at com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:139) at javax.faces.webapp.FacesServlet.service(FacesServlet.java:313) at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:502) at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1157) at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl._doFilterImpl(TrinidadFilterImpl.java:293) at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl.doFilter(TrinidadFilterImpl.java:199) at org.apache.myfaces.trinidad.webapp.TrinidadFilter.doFilter(TrinidadFilter.java:92) at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1148) at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:387) at org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:216) at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:181) at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:765) at org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java:417) at org.mortbay.jetty.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:230) at org.mortbay.jetty.handler.HandlerCollection.handle(HandlerCollection.java:114) at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:152) at org.mortbay.jetty.Server.handle(Server.java:324) at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:535) at org.mortbay.jetty.HttpConnection$RequestHandler.headerComplete(HttpConnection.java:865) at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:539) at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:212) at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:404) at org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:409) at org.mortbay.thread.QueuedThreadPool$PoolThread.run(QueuedThreadPool.java:520) I'm not sure what the ajsfc:autocomplete does, but apparently some of its attributes are not assigned. While I understand this worked with the last release, there has been significant functionality added in 2.0.1 and I'm wondering if you were exploiting a hole before that is no longer present. I'll try to take more of a look but I might need you to research more how trinidad is not interacting with your application correctly and possibly suggest a fix. Additionally, if you want to write a unit test which tests this specific scenario, we can include it in the trinidad builds to make sure it doesn't break in the future.
        Hide
        Walter Mourão added a comment -

        ajsfc:autocomplete is a "suggest box". It calls a method to filter the results that should be shown in the list. Using Mojarra 2.1.7 I've got a different error during the ajax processing (the page shows ok and the error occurs during the filtering process). I will research deeper and let you know my findings.

        Show
        Walter Mourão added a comment - ajsfc:autocomplete is a "suggest box". It calls a method to filter the results that should be shown in the list. Using Mojarra 2.1.7 I've got a different error during the ajax processing (the page shows ok and the error occurs during the filtering process). I will research deeper and let you know my findings.
        Hide
        Paweł Mączka added a comment - - edited

        For me the issue comes for pages that use composite components. I use facelets and templates works fine. Only pages with my own composite component fail with the error.

        Show
        Paweł Mączka added a comment - - edited For me the issue comes for pages that use composite components. I use facelets and templates works fine. Only pages with my own composite component fail with the error.
        Hide
        Scott O'Bryan added a comment - - edited

        Awesome addition Pawel. Maybe that's the piece we were missing. I notice that the Trinidad ChangeApplyingVDLWrapper is in the mix and I'm wondering if that doesn't imply some contract. I'm wondering if adding a value attribute might not fix the issue. If it does then the issue is undoubtedly connected to TRINIDAD-2121 or TRINIDAD-2073. Maybe Prakash can comment.

        I either case, I agree that this is an issue. One should not have to "hack" a declarative component with a custom attribute. Hrm..

        Show
        Scott O'Bryan added a comment - - edited Awesome addition Pawel. Maybe that's the piece we were missing. I notice that the Trinidad ChangeApplyingVDLWrapper is in the mix and I'm wondering if that doesn't imply some contract. I'm wondering if adding a value attribute might not fix the issue. If it does then the issue is undoubtedly connected to TRINIDAD-2121 or TRINIDAD-2073 . Maybe Prakash can comment. I either case, I agree that this is an issue. One should not have to "hack" a declarative component with a custom attribute. Hrm..
        Hide
        Prakash Udupa added a comment -

        It does not look like ChangeManager / TRINIDAD-2121 / TRINIDAD-2073 can be connected here, and there is no contract implied due to using this wrapper. From looking at the code and the stack trace in both cases above, all that the ChangeApplyingVDLWrapper is doing is to delegate buildView() to the underlying VDL

        f.w.i.w., the composite component definition in autocomplete.xhtml has the value attribute marked as required...

        <cc:interface>
        <cc:attribute name="value" required="true"/>

        Which I think is triggering the check in Mojarra case to see if 'value' is supplied, and is failing with the above exception because it is not supplied.

        Show
        Prakash Udupa added a comment - It does not look like ChangeManager / TRINIDAD-2121 / TRINIDAD-2073 can be connected here, and there is no contract implied due to using this wrapper. From looking at the code and the stack trace in both cases above, all that the ChangeApplyingVDLWrapper is doing is to delegate buildView() to the underlying VDL f.w.i.w., the composite component definition in autocomplete.xhtml has the value attribute marked as required... <cc:interface> <cc:attribute name="value" required="true"/> Which I think is triggering the check in Mojarra case to see if 'value' is supplied, and is failing with the above exception because it is not supplied.
        Hide
        Scott O'Bryan added a comment -

        Adjusted priority according to the priority definitions..

        So perhaps this is a symptom of an invalid Composite Component and the exception is getting triggered earlier then normal? That's interesting. If this is the case, the composite component should fail, just perhaps not as early as it does in Trinidad since we are kicking off the VDL early.

        Can you guys verify Prakash's suggestion and see if making "value" an non-required field will work for you? If it does, please close the bug. If it does not, we'll need to look at another solution which does not adversely effect the use of Composite Components. I agree that this is a pretty major issue.

        Let us know so we can proceed...

        Show
        Scott O'Bryan added a comment - Adjusted priority according to the priority definitions.. So perhaps this is a symptom of an invalid Composite Component and the exception is getting triggered earlier then normal? That's interesting. If this is the case, the composite component should fail, just perhaps not as early as it does in Trinidad since we are kicking off the VDL early. Can you guys verify Prakash's suggestion and see if making "value" an non-required field will work for you? If it does, please close the bug. If it does not, we'll need to look at another solution which does not adversely effect the use of Composite Components. I agree that this is a pretty major issue. Let us know so we can proceed...
        Hide
        Prakash Udupa added a comment -

        To add to Scott's comments, you might want to review if you need the 'value' to be required, and if yes, then why is it that it is resolving to null in development mode.

        Looking at the code for 2.1 could give you some idea on what could be going wrong with your composite component or the client code:

        http://grepcode.com/file/repo1.maven.org/maven2/com.sun.faces/jsf-impl/2.1.4/com/sun/faces/facelets/tag/composite/InterfaceHandler.java#116

        See how this validation was not done in 2.0...
        http://grepcode.com/file/repo1.maven.org/maven2/com.sun.faces/jsf-impl/2.0.0/com/sun/faces/facelets/tag/composite/InterfaceHandler.java#98

        the validation is called only when in 'Development' mode, so I think you should not get this error if you are in 'production' mode.

        if (FaceletViewHandlingStrategy.isBuildingMetadata(context))

        { imbueComponentWithMetadata(ctx, parent); this.nextHandler.apply(ctx, parent); }

        else {
        if (ProjectStage.Development == context.getApplication().getProjectStage())

        { validateComponent(context, parent); }
        Show
        Prakash Udupa added a comment - To add to Scott's comments, you might want to review if you need the 'value' to be required, and if yes, then why is it that it is resolving to null in development mode. Looking at the code for 2.1 could give you some idea on what could be going wrong with your composite component or the client code: http://grepcode.com/file/repo1.maven.org/maven2/com.sun.faces/jsf-impl/2.1.4/com/sun/faces/facelets/tag/composite/InterfaceHandler.java#116 See how this validation was not done in 2.0... http://grepcode.com/file/repo1.maven.org/maven2/com.sun.faces/jsf-impl/2.0.0/com/sun/faces/facelets/tag/composite/InterfaceHandler.java#98 the validation is called only when in 'Development' mode, so I think you should not get this error if you are in 'production' mode. if (FaceletViewHandlingStrategy.isBuildingMetadata(context)) { imbueComponentWithMetadata(ctx, parent); this.nextHandler.apply(ctx, parent); } else { if (ProjectStage.Development == context.getApplication().getProjectStage()) { validateComponent(context, parent); }
        Hide
        Walter Mourão added a comment -

        Just tested with 'value' as not required and with 'Production' mode and I've got the same result...
        Using Mojarra I had a different issue during the ajax request: "/start.xhtml @24,71 completeMethod="#

        {test.fillAutocomplete}

        ": Property 'fillAutocomplete' not found on type com.wim.autocomplete.Test". The Mojarra error looks like an EL issue and I will investigate later, but with Mojarra I didn't get the 'UnsupportedOperationException' opening the page.

        Show
        Walter Mourão added a comment - Just tested with 'value' as not required and with 'Production' mode and I've got the same result... Using Mojarra I had a different issue during the ajax request: "/start.xhtml @24,71 completeMethod="# {test.fillAutocomplete} ": Property 'fillAutocomplete' not found on type com.wim.autocomplete.Test". The Mojarra error looks like an EL issue and I will investigate later, but with Mojarra I didn't get the 'UnsupportedOperationException' opening the page.
        Hide
        Scott O'Bryan added a comment -

        I see. So this appears to maybe be an issue with the latest MyFaces then. Would you agree?

        Try fixing the EL evaluation and run this again. I agree that the UnsupportedOperationException is not expected, but it may mean the difference between a major issue an a minor one. If this usecase only fails in MyFaces then I can transfer this bug over to core so that it can be addressed in the next release.

        Show
        Scott O'Bryan added a comment - I see. So this appears to maybe be an issue with the latest MyFaces then. Would you agree? Try fixing the EL evaluation and run this again. I agree that the UnsupportedOperationException is not expected, but it may mean the difference between a major issue an a minor one. If this usecase only fails in MyFaces then I can transfer this bug over to core so that it can be addressed in the next release.
        Hide
        Walter Mourão added a comment -

        I agree it looks like a MyFaces issue but... Trinidad 2.0.0 + MyFaces 2.1.6 works. I will try to do some more testing today with different combinations and will post here so we can be sure about the source of the problem.

        Show
        Walter Mourão added a comment - I agree it looks like a MyFaces issue but... Trinidad 2.0.0 + MyFaces 2.1.6 works. I will try to do some more testing today with different combinations and will post here so we can be sure about the source of the problem.
        Hide
        Walter Mourão added a comment -

        New version of the test case, use:
        "mvn jetty:run" to test Trinidad 2.0.0+MyFaces 2.1.6
        "mvn jetty:run -Dtrinidad=201" to test Trinidad 2.0.1+MyFaces 2.1.6
        "mvn jetty:run -Djsf=mojarra" to test with Mojarra 2.1.7

        Show
        Walter Mourão added a comment - New version of the test case, use: "mvn jetty:run" to test Trinidad 2.0.0+MyFaces 2.1.6 "mvn jetty:run -Dtrinidad=201" to test Trinidad 2.0.1+MyFaces 2.1.6 "mvn jetty:run -Djsf=mojarra" to test with Mojarra 2.1.7
        Hide
        Walter Mourão added a comment - - edited

        Not good results so far:
        myfaces+trinidad 2.0.0=ok

        mojarra+trinidad 200=The Trinidad state change listener stops working during the ajax

        myfaces+trinidad 201=java.lang.UnsupportedOperationException

        mojarra+trinidad 201+jetty=shows the component, but after the ajax it returns: /start.xhtml @24,71 completeMethod="#

        {test.fillAutocomplete}

        ": Property 'fillAutocomplete' not found on type com.wim.autocomplete.Test]

        Weird...
        I'm using Myfaces 2.1.6 and Mojarra 2.1.7 to test.

        Show
        Walter Mourão added a comment - - edited Not good results so far: myfaces+trinidad 2.0.0=ok mojarra+trinidad 200=The Trinidad state change listener stops working during the ajax myfaces+trinidad 201=java.lang.UnsupportedOperationException mojarra+trinidad 201+jetty=shows the component, but after the ajax it returns: /start.xhtml @24,71 completeMethod="# {test.fillAutocomplete} ": Property 'fillAutocomplete' not found on type com.wim.autocomplete.Test] Weird... I'm using Myfaces 2.1.6 and Mojarra 2.1.7 to test.
        Hide
        Scott O'Bryan added a comment -

        Changing the fix version number. This change, among others, are JSF 2.1 issues which will be addressed in the Trinidad 2.1 release which will be enhanced to support JSF 2.1.

        Show
        Scott O'Bryan added a comment - Changing the fix version number. This change, among others, are JSF 2.1 issues which will be addressed in the Trinidad 2.1 release which will be enhanced to support JSF 2.1.

          People

          • Assignee:
            Scott O'Bryan
            Reporter:
            Walter Mourão
          • Votes:
            1 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated:

              Development