SlideShare a Scribd company logo
Copyright © 2015 SolutionsIQ Inc. All rights reserved.
Branching for CD?
Think again !
Devesh Chanchlani
Self Introduction
• Passionate Programmer
• Technical Agile Coach with SolutionsIQ
• Coach teams to embrace, scale and sustain
XP practices
• Belong to Pune
3
Traditional Branching Strategies
Long Lived Feature Branches
4
Less risk of non-finished
changes
» Merging with other
Feature branches
» Merging with mainline
changes
» Accommodating
Refactorings and design
improvements
5
Changes being made to the
mainline after being reviewed
» Merging issues
» Refactoring becomes
challenging
» Cannot have CI for each
branch
» Sometimes changes are big &
individual commits not stable,
that folks simply squash their
changes into big commits.
Short Lived Feature Branches
D1
D2
D3 D4
Another Curious Case
6
<Footer Content: Presentation Title, Partner Name, Other> 7
8
“Feature branching is a poor man's modular architecture,
instead of building systems with the ability to easy swap in
and out features at runtime / deploytime they couple
themselves to the source control providing this
mechanism through manual merging.” Dan Bodart
Trunk Based Development (TBD)
<Footer Content: Presentation Title, Partner Name, Other> 9
What it means …
 All developers commit to a single branch,
called trunk, making frequent check-ins.
 Branches are created only for Release
purpose.
 Bugs are always fixed on trunk and then
merged with release branch.
 Regular developers don’t commit to a release
branch.
 Release branches are never merged back to
trunk.
 Release branches are short-lived, frequently
being replaced by other release branches.
10
11
Trunk Based Development Strategies
12
Imagine you are releasing into production every two
weeks, but need to build a feature that's going to take
three months to complete. How do you use Continuous
Integration to keep everyone working on the mainline
without revealing a half-implemented feature on your
releases?
Feature Toggles
13
Courtesy: Spotify Labs / Henrik Kniberg
Feature Toggle implies …
14
 A configuration file defines a bunch of toggles for various pending features.
 These toggles are mostly applied at UIs, from where interaction with the
features begins.
 For features with no UI, the toggle will be in the app code.
 In such cases, techniques like polymorphic substitution and dependency injection
should be used to avoid crude conditional tests.
 Feature toggles should be removed once the feature is complete.
 Pipelines for different permutations of toggles for releases should be setup.
 If either of the build fails, it implies a bad commit.
Feature Toggle types
15
1. Release – partial features, temporary
2. Business – certain class of users, permanent
3. Runtime – easier rollbacks, run tests with various configurations of
features
4. Build – new feature codebase is not compiled
Branch by Abstraction
16
Consumer
Component to
be replaced
STEP 1
Consumer
Component to
be replaced
Abstraction
Layer
STEP 2
Consumer
Old
Component
Abstraction
Layer
New
Component
STEP 3
Consumer
Old
Component
Abstraction
Layer
New
Component
STEP 4
17
TBD Success Stories
Facebook's Trunk Based Development
18
Google’s Scaled TBD
19
Google’s Scaled TBD
20
 Deals with enormous codebase which changes at enormous speeds.
 Provides extensive tooling to the developers like
 Pre-commit validations
 formal integration/merge/commit itself
 have a “Distributed Builds” capability, which
 Supports “Caches” for leveraging results from previously built modules
 Uses “Gerrit“ for code reviews on refs/for/master branch.
 Has decided owners for all modules.
 Third party dependencies can have only one existing version in the trunk.
 Releases are made from branches cut from the trunk
Google’s Scaled TBD
21
Master
Canary
Beta
Dev
Stable
What it takes to Deliver Continuously
22
References
 Paul Hammant - http://paulhammant.com
 Martin Fowler - http://martinfowler.com/bliki/FeatureToggle.html
 Carlos Lopes - Multiple projects, different goals, one thing in common: the
codebase!
 Henrik Kniberg – Engineering at Spotify
 Chuck Rossi – The Facebook Release Process
23
Our Customers
24
25
Thank you!
solutionsiq.com

More Related Content

What's hot (20)

PPTX
API Automation Testing Using RestAssured+Cucumber
Knoldus Inc.
 
ODP
API Testing With Katalon Studio
Knoldus Inc.
 
PPTX
Choosing a career goal as an IT graduate
Tahsin Abrar
 
PPT
Chrome release cycle
Jolicloud
 
PPTX
Testing in DevOps world
Moataz Nabil
 
PDF
Refactoring for Software Design Smells - XP Conference - August 20th 2016
Ganesh Samarthyam
 
PPSX
SCM Process and smartBuild
Rajesh Kumar
 
PDF
Lessons Learned from Revamping Our Doc Site
Pronovix
 
PPTX
Automated testing for real
Markko Paas
 
PPTX
Polyglot engineering
Klaus Salchner
 
PPTX
Salesforce CI (Continuous Integration) - SFDX + Bitbucket Pipelines
Abhinav Gupta
 
PPTX
BDD WITH CUCUMBER AND JAVA
Srinivas Katakam
 
PPTX
[Rakuten TechConf2014] [C-6] Japan ICHIBA Daily Work - Tools & Processes
Rakuten Group, Inc.
 
PPTX
Cross Platform Mobile Technologies
Talentica Software
 
PPT
Flex on Grails - Rich Internet Applications With Rapid Application Development
Talentica Software
 
PPTX
Effective .NET Core Unit Testing with SQLite and Dapper
Mike Melusky
 
PPT
BDD along with Continuous Integration
Agile Testing Alliance
 
PPTX
Effective API Lifecycle Management
SmartBear
 
PPTX
ATAGTR2017 Unified APM: The new age performance monitoring for production sys...
Agile Testing Alliance
 
PPTX
Understanding and Executing on API Developer Experience
SmartBear
 
API Automation Testing Using RestAssured+Cucumber
Knoldus Inc.
 
API Testing With Katalon Studio
Knoldus Inc.
 
Choosing a career goal as an IT graduate
Tahsin Abrar
 
Chrome release cycle
Jolicloud
 
Testing in DevOps world
Moataz Nabil
 
Refactoring for Software Design Smells - XP Conference - August 20th 2016
Ganesh Samarthyam
 
SCM Process and smartBuild
Rajesh Kumar
 
Lessons Learned from Revamping Our Doc Site
Pronovix
 
Automated testing for real
Markko Paas
 
Polyglot engineering
Klaus Salchner
 
Salesforce CI (Continuous Integration) - SFDX + Bitbucket Pipelines
Abhinav Gupta
 
BDD WITH CUCUMBER AND JAVA
Srinivas Katakam
 
[Rakuten TechConf2014] [C-6] Japan ICHIBA Daily Work - Tools & Processes
Rakuten Group, Inc.
 
Cross Platform Mobile Technologies
Talentica Software
 
Flex on Grails - Rich Internet Applications With Rapid Application Development
Talentica Software
 
Effective .NET Core Unit Testing with SQLite and Dapper
Mike Melusky
 
BDD along with Continuous Integration
Agile Testing Alliance
 
Effective API Lifecycle Management
SmartBear
 
ATAGTR2017 Unified APM: The new age performance monitoring for production sys...
Agile Testing Alliance
 
Understanding and Executing on API Developer Experience
SmartBear
 

Similar to Xp conf-tbd (20)

PDF
Dependency Injection
Giovanni Scerra ☃
 
PDF
Adm Initial Proposal
cfry
 
PPTX
SDLC and Software Process Models
Nana Sarpong
 
PPT
Agile Software Development in Bachelor of Computer Applications.ppt
JASVEERSINGHVU21CSCI
 
PDF
An Introduction to Feature Flags
CloudZenix LLC
 
PPTX
Itertaive Process Development
university of education,Lahore
 
PPTX
Large scale enterprise software architecture
Mohammad Yeganehfar
 
PPTX
Continuous Integration
XPDays
 
PPTX
Component based development | what, why and how
Rakesh Kumar Jha
 
DOC
term paper for cbd models
Sukhdeep Singh
 
PDF
Git & Code review
Cenk Gültekin
 
PDF
Dev opsnirvana
Prashanth Panduranga
 
PPTX
Software Engineering Unit 1 AKTU Complete
malviyamishra19
 
PPTX
Making software development processes to work for you
Ambientia
 
PDF
Devops Tools Pratical Preparatório LPI
DborahDmaris
 
PPTX
Types of software life cycle model
Santhia RK
 
PPTX
MicroserviceArchitecture in detail over Monolith.
PLovababu
 
PPTX
MuleSoft Meetup Adelaide 7th April 2021
Nicholas Bowman
 
PDF
Dev ops lpi-701
Radhouen Assakra
 
PDF
Continuous delivery @wcap 5-09-2013
David Funaro
 
Dependency Injection
Giovanni Scerra ☃
 
Adm Initial Proposal
cfry
 
SDLC and Software Process Models
Nana Sarpong
 
Agile Software Development in Bachelor of Computer Applications.ppt
JASVEERSINGHVU21CSCI
 
An Introduction to Feature Flags
CloudZenix LLC
 
Itertaive Process Development
university of education,Lahore
 
Large scale enterprise software architecture
Mohammad Yeganehfar
 
Continuous Integration
XPDays
 
Component based development | what, why and how
Rakesh Kumar Jha
 
term paper for cbd models
Sukhdeep Singh
 
Git & Code review
Cenk Gültekin
 
Dev opsnirvana
Prashanth Panduranga
 
Software Engineering Unit 1 AKTU Complete
malviyamishra19
 
Making software development processes to work for you
Ambientia
 
Devops Tools Pratical Preparatório LPI
DborahDmaris
 
Types of software life cycle model
Santhia RK
 
MicroserviceArchitecture in detail over Monolith.
PLovababu
 
MuleSoft Meetup Adelaide 7th April 2021
Nicholas Bowman
 
Dev ops lpi-701
Radhouen Assakra
 
Continuous delivery @wcap 5-09-2013
David Funaro
 
Ad

More from XP Conference India (18)

PPTX
Power of Measurement to Attain True Agility Meetu Arora
XP Conference India
 
PPTX
Devops like lance Armstrong by Yahya Poonawala & Siddharth Kulkarni
XP Conference India
 
PDF
Refactoring for software design smells XP Conference 2016 Ganesh Samarthyam...
XP Conference India
 
PPTX
Agile Testing Cost Reduction using Pairwise Technique
XP Conference India
 
PPTX
Perspectives on Continuous Integration at Scale by Hrishikesh K & Vinaya Mura...
XP Conference India
 
PDF
Building Big Architectures by Ramit Surana
XP Conference India
 
PDF
Introduction to Docker - Learning containerization XP conference 2016
XP Conference India
 
PPTX
XP in the full stack
XP Conference India
 
PDF
Bashing cultural monsters in continuous integration by Vivek Ganesan XP Confe...
XP Conference India
 
PDF
S.O.L.I.D xp
XP Conference India
 
PDF
Developer 2.0
XP Conference India
 
PDF
Play2 Java
XP Conference India
 
PPTX
Utility of Test Coverage Metrics in TDD
XP Conference India
 
PDF
Pair Programming in Theory and Practice By Garrick West
XP Conference India
 
PDF
Common blind spots on the journey to production vijay raghavan aravamudhan
XP Conference India
 
PDF
Who will test_your_tests_yahya poonawala- priti biyani
XP Conference India
 
PDF
Adopting agile in an embedded platform Suryakiran Kasturi & Akhil Kumar
XP Conference India
 
PDF
Nightmare to nightly builds Vijay Bandaru
XP Conference India
 
Power of Measurement to Attain True Agility Meetu Arora
XP Conference India
 
Devops like lance Armstrong by Yahya Poonawala & Siddharth Kulkarni
XP Conference India
 
Refactoring for software design smells XP Conference 2016 Ganesh Samarthyam...
XP Conference India
 
Agile Testing Cost Reduction using Pairwise Technique
XP Conference India
 
Perspectives on Continuous Integration at Scale by Hrishikesh K & Vinaya Mura...
XP Conference India
 
Building Big Architectures by Ramit Surana
XP Conference India
 
Introduction to Docker - Learning containerization XP conference 2016
XP Conference India
 
XP in the full stack
XP Conference India
 
Bashing cultural monsters in continuous integration by Vivek Ganesan XP Confe...
XP Conference India
 
S.O.L.I.D xp
XP Conference India
 
Developer 2.0
XP Conference India
 
Utility of Test Coverage Metrics in TDD
XP Conference India
 
Pair Programming in Theory and Practice By Garrick West
XP Conference India
 
Common blind spots on the journey to production vijay raghavan aravamudhan
XP Conference India
 
Who will test_your_tests_yahya poonawala- priti biyani
XP Conference India
 
Adopting agile in an embedded platform Suryakiran Kasturi & Akhil Kumar
XP Conference India
 
Nightmare to nightly builds Vijay Bandaru
XP Conference India
 
Ad

Recently uploaded (20)

PDF
Newgen 2022-Forrester Newgen TEI_13 05 2022-The-Total-Economic-Impact-Newgen-...
darshakparmar
 
PDF
CIFDAQ Token Spotlight for 9th July 2025
CIFDAQ
 
PDF
Jak MŚP w Europie Środkowo-Wschodniej odnajdują się w świecie AI
dominikamizerska1
 
PPTX
✨Unleashing Collaboration: Salesforce Channels & Community Power in Patna!✨
SanjeetMishra29
 
PDF
Using FME to Develop Self-Service CAD Applications for a Major UK Police Force
Safe Software
 
PDF
Agentic AI lifecycle for Enterprise Hyper-Automation
Debmalya Biswas
 
PDF
Newgen Beyond Frankenstein_Build vs Buy_Digital_version.pdf
darshakparmar
 
PDF
SFWelly Summer 25 Release Highlights July 2025
Anna Loughnan Colquhoun
 
PDF
Bitcoin for Millennials podcast with Bram, Power Laws of Bitcoin
Stephen Perrenod
 
PPTX
WooCommerce Workshop: Bring Your Laptop
Laura Hartwig
 
PDF
Empower Inclusion Through Accessible Java Applications
Ana-Maria Mihalceanu
 
PDF
The Builder’s Playbook - 2025 State of AI Report.pdf
jeroen339954
 
PPTX
MSP360 Backup Scheduling and Retention Best Practices.pptx
MSP360
 
PDF
Exolore The Essential AI Tools in 2025.pdf
Srinivasan M
 
PDF
Building Real-Time Digital Twins with IBM Maximo & ArcGIS Indoors
Safe Software
 
PDF
Blockchain Transactions Explained For Everyone
CIFDAQ
 
PDF
CIFDAQ Market Insights for July 7th 2025
CIFDAQ
 
PDF
Fl Studio 24.2.2 Build 4597 Crack for Windows Free Download 2025
faizk77g
 
PDF
"Beyond English: Navigating the Challenges of Building a Ukrainian-language R...
Fwdays
 
PPTX
UiPath Academic Alliance Educator Panels: Session 2 - Business Analyst Content
DianaGray10
 
Newgen 2022-Forrester Newgen TEI_13 05 2022-The-Total-Economic-Impact-Newgen-...
darshakparmar
 
CIFDAQ Token Spotlight for 9th July 2025
CIFDAQ
 
Jak MŚP w Europie Środkowo-Wschodniej odnajdują się w świecie AI
dominikamizerska1
 
✨Unleashing Collaboration: Salesforce Channels & Community Power in Patna!✨
SanjeetMishra29
 
Using FME to Develop Self-Service CAD Applications for a Major UK Police Force
Safe Software
 
Agentic AI lifecycle for Enterprise Hyper-Automation
Debmalya Biswas
 
Newgen Beyond Frankenstein_Build vs Buy_Digital_version.pdf
darshakparmar
 
SFWelly Summer 25 Release Highlights July 2025
Anna Loughnan Colquhoun
 
Bitcoin for Millennials podcast with Bram, Power Laws of Bitcoin
Stephen Perrenod
 
WooCommerce Workshop: Bring Your Laptop
Laura Hartwig
 
Empower Inclusion Through Accessible Java Applications
Ana-Maria Mihalceanu
 
The Builder’s Playbook - 2025 State of AI Report.pdf
jeroen339954
 
MSP360 Backup Scheduling and Retention Best Practices.pptx
MSP360
 
Exolore The Essential AI Tools in 2025.pdf
Srinivasan M
 
Building Real-Time Digital Twins with IBM Maximo & ArcGIS Indoors
Safe Software
 
Blockchain Transactions Explained For Everyone
CIFDAQ
 
CIFDAQ Market Insights for July 7th 2025
CIFDAQ
 
Fl Studio 24.2.2 Build 4597 Crack for Windows Free Download 2025
faizk77g
 
"Beyond English: Navigating the Challenges of Building a Ukrainian-language R...
Fwdays
 
UiPath Academic Alliance Educator Panels: Session 2 - Business Analyst Content
DianaGray10
 

Xp conf-tbd

  • 1. Copyright © 2015 SolutionsIQ Inc. All rights reserved. Branching for CD? Think again ! Devesh Chanchlani
  • 2. Self Introduction • Passionate Programmer • Technical Agile Coach with SolutionsIQ • Coach teams to embrace, scale and sustain XP practices • Belong to Pune
  • 4. Long Lived Feature Branches 4 Less risk of non-finished changes » Merging with other Feature branches » Merging with mainline changes » Accommodating Refactorings and design improvements
  • 5. 5 Changes being made to the mainline after being reviewed » Merging issues » Refactoring becomes challenging » Cannot have CI for each branch » Sometimes changes are big & individual commits not stable, that folks simply squash their changes into big commits. Short Lived Feature Branches D1 D2 D3 D4
  • 7. <Footer Content: Presentation Title, Partner Name, Other> 7
  • 8. 8 “Feature branching is a poor man's modular architecture, instead of building systems with the ability to easy swap in and out features at runtime / deploytime they couple themselves to the source control providing this mechanism through manual merging.” Dan Bodart
  • 9. Trunk Based Development (TBD) <Footer Content: Presentation Title, Partner Name, Other> 9
  • 10. What it means …  All developers commit to a single branch, called trunk, making frequent check-ins.  Branches are created only for Release purpose.  Bugs are always fixed on trunk and then merged with release branch.  Regular developers don’t commit to a release branch.  Release branches are never merged back to trunk.  Release branches are short-lived, frequently being replaced by other release branches. 10
  • 12. 12 Imagine you are releasing into production every two weeks, but need to build a feature that's going to take three months to complete. How do you use Continuous Integration to keep everyone working on the mainline without revealing a half-implemented feature on your releases?
  • 13. Feature Toggles 13 Courtesy: Spotify Labs / Henrik Kniberg
  • 14. Feature Toggle implies … 14  A configuration file defines a bunch of toggles for various pending features.  These toggles are mostly applied at UIs, from where interaction with the features begins.  For features with no UI, the toggle will be in the app code.  In such cases, techniques like polymorphic substitution and dependency injection should be used to avoid crude conditional tests.  Feature toggles should be removed once the feature is complete.  Pipelines for different permutations of toggles for releases should be setup.  If either of the build fails, it implies a bad commit.
  • 15. Feature Toggle types 15 1. Release – partial features, temporary 2. Business – certain class of users, permanent 3. Runtime – easier rollbacks, run tests with various configurations of features 4. Build – new feature codebase is not compiled
  • 16. Branch by Abstraction 16 Consumer Component to be replaced STEP 1 Consumer Component to be replaced Abstraction Layer STEP 2 Consumer Old Component Abstraction Layer New Component STEP 3 Consumer Old Component Abstraction Layer New Component STEP 4
  • 18. Facebook's Trunk Based Development 18
  • 20. Google’s Scaled TBD 20  Deals with enormous codebase which changes at enormous speeds.  Provides extensive tooling to the developers like  Pre-commit validations  formal integration/merge/commit itself  have a “Distributed Builds” capability, which  Supports “Caches” for leveraging results from previously built modules  Uses “Gerrit“ for code reviews on refs/for/master branch.  Has decided owners for all modules.  Third party dependencies can have only one existing version in the trunk.  Releases are made from branches cut from the trunk
  • 22. What it takes to Deliver Continuously 22
  • 23. References  Paul Hammant - http://paulhammant.com  Martin Fowler - http://martinfowler.com/bliki/FeatureToggle.html  Carlos Lopes - Multiple projects, different goals, one thing in common: the codebase!  Henrik Kniberg – Engineering at Spotify  Chuck Rossi – The Facebook Release Process 23

Editor's Notes

  • #7: Promiscuous Integration