Details
-
Type:
Improvement
-
Status: Closed
-
Priority:
Major
-
Resolution: Fixed
-
Affects Version/s: 3.3
-
Component/s: Framework
-
Labels:None
-
Environment:Any
-
Assignee Priority:P2
-
Affects:Documentation (User Guide, Ref. Guide, etc.), Sample App./Tutorial, Compatibility/Configuration
-
Workaround Exists:Yes
-
Workaround Description:Newer versions of the libraries can always be manually switched in to the current directory
Description
Need to modify the current build structure to support building with JSF 2.1 or 2.2. This should include Mojarra but may expand to include MyFaces as well.
Activity
| Field | Original Value | New Value |
|---|---|---|
| Workaround Description | Newer versions of the libraries can always be manually switched in to the current directory | |
| Assignee | Deryk Sinotte [ deryk.sinotte ] | |
| Fix Version/s | 3.4 [ 10770 ] | |
| Affects | Documentation (User Guide, Ref. Guide, etc.),Compatibility/Configuration [ 10003, 10002 ] | |
| Workaround Exists | Yes [ 10007 ] | |
| Assignee Priority | P2 [ 10011 ] |
| Repository | Revision | Date | User | Message |
| ICEsoft Public SVN Repository | #37395 | Tue Aug 13 17:16:27 MDT 2013 | deryk.sinotte | |
| Files Changed | ||||
DEL
/icefaces3/trunk/icefaces/lib/myfaces/myfaces-api-2.1.10.jar
DEL
/icefaces3/trunk/icefaces/lib/myfaces/commons-codec-1.4.jar
DEL
/icefaces3/trunk/icefaces/lib/mojarra/javax.faces.jar
DEL
/icefaces3/trunk/icefaces/lib/myfaces/commons-beanutils-1.8.3.jar
MODIFY
/icefaces3/trunk/icefaces/lib/versions-licenses.html
DEL
/icefaces3/trunk/icefaces/lib/myfaces/commons-logging-1.1.1.jar
DEL
/icefaces3/trunk/icefaces/lib/myfaces/commons-digester-2.1.jar
DEL
/icefaces3/trunk/icefaces/lib/myfaces/myfaces-impl-2.1.10.jar
DEL
/icefaces3/trunk/icefaces/lib/myfaces/commons-collections-3.2.jar
|
| Repository | Revision | Date | User | Message |
| ICEsoft Public SVN Repository | #37396 | Tue Aug 13 17:17:39 MDT 2013 | deryk.sinotte | |
| Files Changed | ||||
MODIFY
/icefaces3/trunk/icefaces/core/build.xml
MODIFY
/icefaces3/trunk/icefaces/samples/build/common.xml
MODIFY
/icefaces3/trunk/icefaces/compat/core/build.xml
MODIFY
/icefaces3/trunk/icefaces/compat/component-metadata/build.xml
MODIFY
/icefaces3/trunk/icefaces/ace/generator/build.xml
MODIFY
/icefaces3/trunk/icefaces/samples/core/basic/pom.xml
MODIFY
/icefaces3/trunk/icefaces/compat/components/build.xml
MODIFY
/icefaces3/trunk/icefaces/pom.xml
MODIFY
/icefaces3/trunk/icefaces/ace/component/build.xml
|
| Repository | Revision | Date | User | Message |
| ICEsoft Public SVN Repository | #37397 | Tue Aug 13 17:56:05 MDT 2013 | deryk.sinotte | |
| Files Changed | ||||
MODIFY
/icefaces3/trunk/icefaces/lib/versions-licenses.html
|
| Repository | Revision | Date | User | Message |
| ICEsoft Public SVN Repository | #37398 | Tue Aug 13 18:12:51 MDT 2013 | mark.collette | |
| Files Changed | ||||
MODIFY
/icefaces3/trunk/icefaces/tutorials/common.xml
|
| Status | Open [ 1 ] | Resolved [ 5 ] |
| Affects | Documentation (User Guide, Ref. Guide, etc.),Compatibility/Configuration [ 10003, 10002 ] | Documentation (User Guide, Ref. Guide, etc.),Sample App./Tutorial,Compatibility/Configuration [ 10003, 10001, 10002 ] |
| Resolution | Fixed [ 1 ] |
| Repository | Revision | Date | User | Message |
| ICEsoft Public SVN Repository | #37405 | Wed Aug 14 09:54:05 MDT 2013 | deryk.sinotte | |
| Files Changed | ||||
MODIFY
/icefaces3/trunk/icefaces/tutorials/common.xml
|
| Fix Version/s | 4.0 [ 11382 ] |
| Status | Resolved [ 5 ] | Closed [ 6 ] |

I modified a number of build files as well as adjust the structure of the lib/ directory. The aim is to support building against both JSF 2.1 and 2.2 using either Mojarra or MyFaces. The directory structure has changed from:
to:
NOTE The MyFaces 2.2 libraries are very early release versions and may not be ready for general use or testing yet.
You control the implementation and the version using properties. The default is still to build with Mojarra 2.1. The web-profile target should always exclude JSF but the servlet-profile will include JSF depending on which properties are set. The MyFaces property remains the same. A new jsf22 property has been added. Here are the various combinations:
NOTE To support all this, I had to adjust the various build files so that the logic also considered the version directory. I think I managed to changed all the build files in the trunk but if build files in other areas (e.g. QA) that are relying on the old structure, will need to be updated. To help with that, here's a diff of the changes made to samples/build/common.xml. It highlights how the new version directories and MyFaces common directory are handled.
Index: samples/build/common.xml =================================================================== --- samples/build/common.xml (revision 37380) +++ samples/build/common.xml (revision ) @@ -29,6 +29,7 @@ <property name="lib.dir" location="${icefaces.base.dir}/lib"/> <property name="mojarra.lib.dir" location="${lib.dir}/mojarra"/> <property name="myfaces.lib.dir" location="${lib.dir}/myfaces"/> + <property name="myfaces.common.dir" value="${myfaces.lib.dir}/common" /> <property name="lib.ace.dir" location="${lib.dir}/ace"/> <property name="lib.ace.dir.includes" value=""/> <property name="lib.compat.dir" location="${lib.dir}/compat"/> @@ -60,10 +61,18 @@ <property name="icefaces-compat.lib.name" value="icefaces-compat" /> <!-- Check which JSF implementation to use and set the appropriate sub-directory --> - <condition property="jsf.lib.dir" value="${myfaces.lib.dir}" else="${mojarra.lib.dir}"> + <condition property="jsf.impl.dir" value="${myfaces.lib.dir}" else="${mojarra.lib.dir}"> <isset property="myfaces"/> </condition> + <!-- Check which JSF version to use and set the appropriate sub-directory --> + <condition property="jsf.ver.dir" value="2.2" else="2.1"> + <isset property="jsf22"/> + </condition> + + <property name="jsf.lib.dir" value="${jsf.impl.dir}/${jsf.ver.dir}" /> + <echo message="JSF lib dir: ${jsf.lib.dir}"/> + <patternset id="lib.compile"> <include name="*.jar"/> </patternset> @@ -93,6 +102,10 @@ <exclude name="*.jar" unless="jsf"/> </patternset> + <patternset id="lib.myfaces.common"> + <exclude name="*.jar" unless="myfaces"/> + </patternset> + <patternset id="lib.distribute.ace" includes="itext-2.1.7.jar poi-3.7.jar ${lib.distribute.ace.includes}"> <exclude name="*.jar" unless="ace"/> </patternset> @@ -153,6 +166,9 @@ <fileset dir="${jsf.lib.dir}"> <patternset refid="lib.compile"/> </fileset> + <fileset dir="${myfaces.common.dir}"> + <patternset refid="lib.myfaces.common"/> + </fileset> <fileset dir="${lib.dir}" > <patternset refid="lib.compile"/> </fileset> @@ -174,6 +190,14 @@ </target> <target name="war.basic" depends="compile"> + + <condition property="myfaces.common.include" value="true"> + <and> + <isset property="myfaces"/> + <isset property="jsf"/> + </and> + </condition> + <war basedir="${web.dir}" destfile="${dist.dir}/${ant.project.name}.war" webxml="${web.dir}/WEB-INF/web.xml"> @@ -195,6 +219,10 @@ </lib> <lib dir="${jsf.lib.dir}" erroronmissingdir="false"> <patternset refid="lib.distribute.jsf"/> + </lib> + + <lib dir="${myfaces.common.dir}" erroronmissingdir="false"> + <exclude name="*.jar" unless="myfaces.common.include"/> </lib> <!-- Add the icefaces-ee-ext.jar only if it exists. There are