You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Now when I debug I see that template.xhtml is resolved into: file:/C:/../testContractMappings/webapp/contracts/default/template.xhtml which is correct.
but because isContractsResource is true, which is also correct for that path, I will get "IOException: Contract resources cannot be accessed this way" from DefaultFacelet.
Caused by: jakarta.faces.view.facelets.TagAttributeException: /test.xhtml @2,96 <ui:composition template="template.xhtml"> Invalid path : template.xhtml
at [email protected]//com.sun.faces.facelets.tag.ui.CompositionHandler.apply(CompositionHandler.java:134)
at [email protected]//com.sun.faces.facelets.compiler.NamespaceHandler.apply(NamespaceHandler.java:52)
at [email protected]//com.sun.faces.facelets.compiler.EncodingHandler.apply(EncodingHandler.java:46)
at [email protected]//com.sun.faces.facelets.impl.DefaultFacelet.apply(DefaultFacelet.java:132)
at [email protected]//com.sun.faces.application.view.FaceletViewHandlingStrategy.buildView(FaceletViewHandlingStrategy.java:331)
at [email protected]//com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePhase.java:70)
at [email protected]//com.sun.faces.lifecycle.Phase.doPhase(Phase.java:72)
at [email protected]//com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:150)
at [email protected]//jakarta.faces.webapp.FacesServlet.executeLifecyle(FacesServlet.java:692)
... 45 more
Caused by: java.io.IOException: Contract resources cannot be accessed this way
at [email protected]//com.sun.faces.facelets.impl.DefaultFacelet.include(DefaultFacelet.java:298)
at [email protected]//com.sun.faces.facelets.impl.DefaultFaceletContext.includeFacelet(DefaultFaceletContext.java:154)
at [email protected]//com.sun.faces.facelets.tag.ui.CompositionHandler.apply(CompositionHandler.java:129)
... 53 more
Now after the change, can't ui:composition be used with contract-mapping-s any more or maybe I must change something in the mapping to use it in a different way or must do something to get it working with contracts again? We have not set jakarta.faces.WEBAPP_CONTRACTS_DIRECTORY.
Desktop (please complete the following information):
OS: Windows/unix/mac
Version 4.0.5
Additional context
I found this from Wildfly 31 and latest glassfish 7 that already use mojarra 4.0.5
Probably caused by #5330
The text was updated successfully, but these errors were encountered:
Describe the bug
ui:composition with a template from contracts bath does not work with mojarra 4.0.5
Probably caused by #5330
To Reproduce
We have a place similar to this tutorial:
https://javaee.github.io/tutorial/jsf-facelets008.html#:~:text=Resource%20library%20contracts%20allow%20you,section%20of%20your%20web%20application.
<ui:composition xmlns:ui="http://xmlns.jcp.org/jsf/facelets" template="/template.xhtml" />
with a faces-config.xml
Now when I debug I see that template.xhtml is resolved into: file:/C:/../testContractMappings/webapp/contracts/default/template.xhtml which is correct.
but because isContractsResource is true, which is also correct for that path, I will get "IOException: Contract resources cannot be accessed this way" from DefaultFacelet.
Now after the change, can't ui:composition be used with contract-mapping-s any more or maybe I must change something in the mapping to use it in a different way or must do something to get it working with contracts again? We have not set jakarta.faces.WEBAPP_CONTRACTS_DIRECTORY.
Desktop (please complete the following information):
Additional context
I found this from Wildfly 31 and latest glassfish 7 that already use mojarra 4.0.5
Probably caused by #5330
The text was updated successfully, but these errors were encountered: