-
Enhancement
-
Resolution: Done
-
Trivial
-
None
-
None
-
None
When running faces setup, the following entry is generated on web.xml (if asked so):
<servlet-mapping> <servlet-name>Faces Servlet</servlet-name> <url-pattern>*.xhtml</url-pattern> </servlet-mapping> <servlet-mapping> <servlet-name>Faces Servlet</servlet-name> <url-pattern>/faces/*</url-pattern> </servlet-mapping>
Since Servlet 2.5, several url-patterns may be grouped into a single servlet-mapping, so that the web.xml becomes smaller:
<servlet-mapping> <servlet-name>Faces Servlet</servlet-name> <url-pattern>*.xhtml</url-pattern> <url-pattern>/faces/*</url-pattern> </servlet-mapping>
The method org.jboss.forge.spec.javaee.jsf.ServletMappingHelper.createMappingIfNotExists(Node, Node, String) should be reviewed to accomplish that.