Uploaded image for project: 'MyFaces Core'
  1. MyFaces Core
  2. MYFACES-4577

Facelets Compatibility: ui:insert nested in ui:include not added to component tree

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • 4.0.0-RC5
    • None
    • General
    • None
    • primefaces-test project, jakarta branch

    Description

      When having a structure where a ui:insert is used in a file included by ui:include, the components that should be added by the ui:insert are not added to the component tree or at least not before other components are processed.

      So the structure is as follows:
      ui:composition (test.xhtml) uses template (template.xhtml) and defines a header that is included from another file using ui:include (test_header.xhtml)
      template (template.xhtml) includes a ui:composition (header.xhtml) that inserts the header into the template

      The composite component specified in test_header.xhtml is not added to the component tree before the update attribute of a commandButton is processed and throws a ComponentNotFoundException.

      You probably didn't understand a single thing, so the easiest is to take a look at the primefaces-test project I created here: https://github.com/mkomko/primefaces-test/tree/component-not-found

      I can't say for sure if this structure is supported by the spec, but it works in Mojarra.

      It works using 

      mvn clean jetty:run -Pmojarra40

       but not using 

      mvn clean jetty:run -Pmyfaces40

      Thank you very much in advance for taking a look! We're evaluating migrating our large web application from Mojarra to MyFaces, so you might hear from me again .

       

      Attachments

        Activity

          People

            Unassigned Unassigned
            mkomko Manuel K
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated: