Shave 4MB off your WAR deployments by using PrimeFace

UI Components for JSF
Post Reply
PeterFalken
Posts: 1
Joined: 17 Nov 2014, 16:03

17 Nov 2014, 16:06

Just wanted to share this with the community - and save you a few hours of dependency hell.
You can shave 3.9 MB off of your WAR files when using PrimeFaces 5.1 as a module on WildFly 8.x
Files are hosted here: https://github.com/PeterFalken/WildFly8-Modules

You'll need to use a boss-deployment-structure.xml file in the META-INF directory on the top level of your WAR file
with the following content:

Code: Select all

<jboss-deployment-structure>  
     <deployment>  
          <dependencies>  
               <module name="org.primefaces" meta-inf="export" />  
          </dependencies>  
     </deployment>  
</jboss-deployment-structure>


and place the JAR files (prime faces-5.1.jar & all-themes-1.0.10.jar) under: JBOSS_HOME/modules/system/layers/base/org/primefaces/main
and a module.xml file with this content:

Code: Select all

<?xml version="1.0" encoding="UTF-8"?>  
<module xmlns="urn:jboss:module:1.3" name="org.primefaces">  
     <resources>  
          <resource-root path="primefaces-5.1.jar" />  
          <resource-root path="all-themes-1.0.10.jar" />  
     </resources>  
     <dependencies>  
          <module name="javax.faces.api" />  
          <module name="javax.api"/>  
     </dependencies>  
</module>



I'm looking for some help to do the same for RichFaces 4.5.Final and also RichFaces 5.Beta3

Post Reply

Return to “PrimeFaces”

  • Information
  • Who is online

    Users browsing this forum: Google [Bot] and 44 guests