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

TCK: Spec1553IT: Fix jakarta.faces.composite namespace handling

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 4.0.0-RC1
    • 4.0.0-RC2
    • None
    • None

    Description

      TCK Spec1553IT Test Fails here: https://github.com/jakartaee/faces/blob/4.0.1/tck/faces40/namespaces/src/test/java/ee/jakarta/tck/faces/test/servlet50/namespaces/Spec1553IT.java#L101

      xhtml Code:

      https://github.com/jakartaee/faces/blob/4.0.1/tck/faces40/namespaces/src/main/webapp/spec1553IT.xhtml

      xmlns:cc_jakarta="jakarta.faces.composite/components"
      ...
      <div id="cc_jakarta"><cc_jakarta:component value="value" /></div>

      The issue is within CompositeResourceLibrary. Each namespace, expect the current jakarta one, has a ending slash:

      public final static String NAMESPACE_PREFIX = "jakarta.faces.composite";
      public final static String JCP_NAMESPACE_PREFIX = "http://xmlns.jcp.org/jsf/composite/";
      public final static String SUN_NAMESPACE_PREFIX = "http://java.sun.com/jsf/composite/";

      This difference affects how the substring call occurs: https://github.com/apache/myfaces/blob/89c747e85615e3f33265e664c8361789f38ea7db/impl/src/main/java/org/apache/myfaces/view/facelets/tag/composite/CompositeResourceLibrary.java#L215

      With the old namespaces, "components" would be returned. But now since jakarta.faces.composite is removed, the libraryName is "/components". This leading slash creates problems when creating/looking up resource.

      Attachments

        Issue Links

          Activity

            People

              volosied Volodymyr Siedlecki
              volosied Volodymyr Siedlecki
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: