You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@myfaces.apache.org by Apache Wiki <wi...@apache.org> on 2007/10/09 18:54:55 UTC

[Myfaces Wiki] Update of "TrinidadCreating12Branches" by AdamWiner

Dear Wiki user,

You have subscribed to a wiki page or wiki category on "Myfaces Wiki" for change notification.

The following page has been changed by AdamWiner:
http://wiki.apache.org/myfaces/TrinidadCreating12Branches

New page:
= Creating JSF 1.2 branches =

The current Trinidad trunk is based on JSF 1.1.  We create branches for JSF 1.2-based Trinidad.  Trinidad 1.2.2 is 1.0.2 with JSF 1.2 support, Trinidad 1.2.3 is 1.0.3 with JSF 1.2 support, etc.  This page describes how JSF 1.2 branches are created.

'''NOTE''': revision numbers and branch names are EXAMPLES.  If y'all don't edit them, y'all ain't gonna get acceptable results.  Y'hear?
'''NOTE 2''': things are a bit wacky below with some extra "/trinidad" directories because I've created these new 1.2.x branches *without* the extra level of "/trinidad", though it's still in the trunk directories.  Hopefully, we'll get rid of the "/trinidad" in the trunk.

== STEP 1: CREATE THE BRANCH ==

1A. Create new branch from trunk,  *using revision used to corresponding 1.0.x branch* 

svn cp -r579900 https://svn.apache.org/repos/asf/myfaces/trinidad/trunk/trinidad https://svn.apache.org/repos/asf/myfaces/trinidad/branches/1.2.3-branch

OR, probably better

1B. Create new branch from the start of the 1.0.x branch, with a revision *before* [maven-release-plugin]

svn cp -r579893 https://svn.apache.org/repos/asf/myfaces/trinidad/branches/matzew-core-103-release-reloaded/trinidad https://svn.apache.org/repos/asf/myfaces/trinidad/branches/1.2.3-branch -m"Creating new 1.2 branch"


== 2. CHECK OUT THE BRANCH ==

Check out the newly created branch:

svn co https://svn.apache.org/repos/asf/myfaces/trinidad/branches/1.2.3-branch trinidad-1.2.3

== 3. MERGE IN THE OLD 1.2 CODE ==

>>From the new Trinidad directory, merge in the code from the *prior* 1.2.2 branch.   

cd trinidad-1.2.3
svn log https://svn.apache.org/repos/asf/myfaces/trinidad/branches/1.2.2-branch --stop-on-copy

(Note the revision number used to create that 1.2.2 branch, and use it in the next step!)

svn merge -r563667:HEAD https://svn.apache.org/repos/asf/myfaces/trinidad/branches/1.2.2-branch/trinidad

== 4. FIX CONFLICTS ==

You're gonna get a bunch of conflicts.  The easy ones are in the pom.xml files, where you'll have a lots of version number conflicts to update (e.g., 1.0.3-SNAPSHOT vs. 1.2.2-SNAPSHOT should become 1.2.3-SNAPSHOT).

The hard conflicts are in code.  Often, these will be simple little tweaks, but occasionally there are massive differences.  Usually, these imply one of two things:

- The files have significantly diverged in the 1.1 and 1.2 codebases, so a fix cannot be easily applied
- The same fix was applied on both the 1.1 and 1.2 branches (and somewhat differently on each)

In either case, what you should do is:

- Use the code from the prior 1.2 branch wholesale.
- Check the log on the trunk to see exactly what changes were made in between the previous release and this one, and re-apply all of those fixes by hand.

== 5. VERIFY THE CODE BUILDS ==

mvn install, etc.

== 6. CHECK IN THE BRANCH ==

svn commit -m"Merged 1.2 code"

== 7. TEST ==

Yeah, we test after checking in.  Trust me, this is the right way.  It's a branch, not trunk, and getting the merge checked in is a strong plus.  The branch isn't at all ready until you've tested.  (Checking in before the code even builds, though, is lame, since any failures mean you've probably biffed the merging.)

I've typically tested Trinidad 1.2 by deploying the demo to the Glassfish server.  Any JSF 1.2 compliant server is OK.

== 8. LOOK FOR NEW "1.1" APIS ==

An annoying manual step:  you need to look for any new APIs or significant new implementations, and see if any introduce new uses of deprecated JSF APIs like ValueBinding or MethodBinding.  Fix these.

== 9. RE-TEST, etc. ==