DEV306: Branching and Merging for Parallel Development

DEV306
Agenda
Production
Test
Development
R1
Branch
On Test
R2
Branch
On Test
LEGEND
Branching / Merging point
R3
Development
Test
Production
Handling bugs
Test
Development
Production
R1
Branch
On Test
Forward
Integrate as
necessary
Forward
Integrate as
necessary
R2
Branch
On Test
Forward
Integrate as
necessary
R3
LEGEND
Branching / Merging
Point
Branch
On Test
Development
Test
Production
R4
R1.1
R1
FI for Release
FI for Release
Main
FI for Release
R2
FI for Release
R2.1
LEGEND
Branching / Merging
point
Release Branch
Development
Firm
Branch
Prod
Branch
QA
LEGEND
Dev
Soft
Branching / Merging point
Branch
Branch
QA
LEGEND
Dev
Branching / Merging point
Branch
R3
Branch
R2
Branch
R1
Branch
Prod
(Safekeeping)
Branch
Prod
Hotfix
Branch
Branch
QA
LEGEND
Dev
Branching / Merging point
Branch
Rx
Branch
Prod
Code under test
L1
L1
L2
RI
FI
Branch
QA
Hot Fix
Dev
LEGEND
R1
R2
Branching / Merging
point
X
Branching / Merging
Point + Label
Bug found
Multiple steps
done as a single
unit of work
R1
Branch
Prod
Code under
test
R1
Code under
test
L2
L1
L3
Rollback
to L2
L2
L4
Branch
QA
Dev
D1
LEGEND
R1
Branching / Merging
point
X
Branching / Merging
Point + Label
Bug found
D2
R2
Multiple steps
done as a single
unit of work
Code under
test
R3
L5
Fix the bug
R1
Code under
test
Branch
QA
Dev
LEGEND
R1
R2
Branching / Merging
point
X
Branching / Merging
Point + Label
Bug found
Multiple steps
done as a single
unit of work
R3
Branch
Code under
test
RI
R2
Branch
Prod
(Safekeeping)
PROD
QA
DEV
F1
F2
LEGEND
F3
Branching /
Merging point
Multiple steps
done as a single
unit of work
Single
Short
Quality
Long
Release
Yes
Release
(Mainline)
No
Release
Release
time?
How many
releases?
Multiple
Concurrent?
What
strategy?
Business is
uncertain
Short
Quality
Long
Feature
Iteration
length?
Pros
Cons
Simplest model to use
Not as flexible as other patterns
Good choice for single version web
applications
More active releases = more difficulty
doing Forward Integration
Same pattern for hot fix or
maintenance release
Multiple test environments needed
Minimal amount of branching
Doesn’t support multiple concurrent
releases well
May have to re-create the builds for
new releases
Pros
No dependencies on any version
except the prior .x version
Cons
Branching can get very complicated
Requires numerous merges and
active management
Requires numerous test environments
Initial release from main, subsequent
releases from release branch
Forward integrating bug fixes is
difficult
Pros
Cons
Maximum flexibility
Can be extremely complex
Easy ability to deal with multiple branches
Requires a dedicated build person
Supports multiple paths to production (multiple
test environments, fixes from different branches)
Without documented processes, can spiral out of
control and you can “lose” source code because
you can’t find it!
Pros
Cons
Separates out features
Can get as complicated as Branch by
Quality
Allows for flexibility in release
Feature teams need to remember to sync
often with dev branch
Allows for easier debugging (a problem with
one feature doesn’t effect another feature)
Can get confusing for teams working on
multiple features
Builds on the Branch by Quality pattern
Requires at least one test environment per
feature
Helps deal with longer running features
May need multiple integration branches
DEV202: Team Foundation Server for Everyone
DEV310: Team Build 2010: From Build Definition to Custom Workflow Activities in 75 Minutes
DEV311: Deep Dive into Microsoft Visual Studio Team Foundation Server 2010 Reporting
DEV327: The Accidental Team Foundation Server Admin
DEV271INT: Would You, Could You with TFS?
DEV366HOL: Branching and Merging Visualization with Microsoft Visual Studio Team Foundation
Server 2010
DEV367HOL: Planning Your Projects with Microsoft Visual Studio Team Foundation Server 2010
http://www.microsoft.com/visualstudio
http://www.microsoft.com/visualstudio/en-us/lightswitch
http://www.microsoft.com/expression/
http://blogs.msdn.com/b/somasegar/
http://blogs.msdn.com/b/bharry/
http://www.microsoft.com/sqlserver/en/us/default.aspx
http://www.facebook.com/visualstudio
http://northamerica.msteched.com
www.microsoft.com/teched
www.microsoft.com/learning
http://microsoft.com/technet
http://microsoft.com/msdn