Continuous Delivery
Applied
Mike McGarr
jmcgarr@gmail.com
@jmichaelmcgarr
http://earlyandoften.wordpress.com
http://www.meetup.com/DC-continuous-integration/
About Me
• J. Michael (Mike) McGarr
• 12 years as a software engineer
• Director of DevOps for Learn, Blackboard
• Founder of the DC Continuous Integration,
Delivery, and Deployment Meetup
2
Continuous Delivery
“Continuous delivery is a set
of practices and principles
aimed at, building, testing
and releasing software
faster and more frequently”
cycle time
3
Cycle Time
“How long would it take your organization to
deploy a change [to production] that involves
just one single line of code? Do you do this on a
repeatable, reliable basis?”
- Mary and Tom Poppendieck,
Implementing Lean Software Development
6
The Last Mile
Manual Deployments
Insufficient Configuration Management
Infrequent, Error Prone Deployments
7
Applying Continuous Delivery
Principles: Practices:
• Improve continuously Continuous Deployment (DevOps)
• Releasing software MUST be
repeatable and reliable Build Pipelines
• Automate everything!
• If it hurts, do it more often Deployment Automation
• Keep everything in version control
• Done means “released”
• Build quality in! Configuration Continuous
Testing
• Everybody has responsibility for Management Integration
the release process
Agile
11
Deployment Pipelines
A Deployment Pipeline is an automated
manifestation of your process for getting
software from version control into the
hands of your users.
13
Version Control
• Version Everything
• Tool should stay out of the
way
• Good Branching Strategy
• Don’t check-in binary files
24
Automate the Build
• No IDE Builds!
• KISS
• Fail Fast (but smartly)
• No Wiki’s to Build
• Pick an appropriate
Technology
• Keep it organized
• Dependency Management
25
Key Takeaways
• Continuous Delivery is hard
• Fast Feedback is the key
• Small, frequent releases
• Version everything
• Automate everything
• Think culture
56
Further Reading
• Continuous Delivery: Reliable Software Releases through Build, Test
and Deployment Automation, by Jez Humble and David Farley -
http://www.amazon.com/Continuous-Delivery-Deployment-Automation-
Addison-Wesley/dp/0321601912
• Continuous Integration, By Paul M Duvall -
http://www.amazon.com/Continuous-Integration-Improving-Software-
Reducing/dp/0321336380
• Refactoring Databases, By Scott Ambler and Pramod Sadalage -
http://www.amazon.com/Refactoring-Databases-Evolutionary-
paperback-Addison-Wesley/dp/0321774515
• Refactoring, By Martin Fowler - http://www.amazon.com/Refactoring-
Improving-Design-Existing-Code/dp/0201485672
• Growing Object-Oriented Software, Guided by Tests, by Steven
Freeman and Nat Pryce - http://www.amazon.com/Growing-Object-
Oriented-Software-Guided-Tests/dp/0321503627
58
Further Reading
• Extreme Programming Explained, by Kent Beck -
http://www.amazon.com/Extreme-Programming-Explained-Embrace-
Change/dp/0201616416
• Release It!, by Michael Nygard -
http://pragprog.com/book/mnee/release-it
• xUnit Test Patterns, by Gerard Meszaros -
http://www.amazon.com/xUnit-Test-Patterns-Refactoring-
Code/dp/0131495054
• Working Effectively with Legacy Code, by Michael Feathers -
http://www.amazon.com/Working-Effectively-Legacy-Michael-
Feathers/dp/0131177052
• Agile Testing, by Lisa Crispin and Janet Gregory -
http://www.amazon.com/Agile-Testing-Practical-Guide-
Testers/dp/0321534468
59
Further Reading
• Test Driven Development (TDD) – http://en.wikipedia.org/wiki/Test-
driven_development
• Introducing BDD, by Dan North – http://dannorth.net/introducing-bdd/
• Agile Manifesto – http://agilemanifesto.org/
• Scrum – http://www.scrumalliance.org/learn_about_scrum
• Continuous Integration, by Martin Fowler –
http://martinfowler.com/articles/continuousIntegration.html
• Specification by Example, by Gojko Adzic -
http://specificationbyexample.com/
• Build Pipelines - http://www.magpiebrain.com/2009/12/13/a-brief-and-
incomplete-history-of-build-pipelines/
• Implementing Lean Software Development, by Mary and Tom
Poppendieck - http://www.amazon.com/Implementing-Lean-Software-
Development-Concept/dp/0321437381
60
Further Reading
• Maven Releases on Steriods, by Axel Fontaine –
http://www.axelfontaine.com/2011/01/maven-releases-on-steroids-
adios.html
• What is in a Name? Usually a version number, actually., by James
Betteley - http://jamesbetteley.wordpress.com/2011/07/07/what-is-in-a-
name-usually-a-version-number-actually/
• Build Once, Deploy Many -
http://earlyandoften.wordpress.com/2010/09/09/build-once-deploy-
many/
• Evolutionary Design - http://martinfowler.com/articles/designDead.html
• Continuous Deployment -
http://timothyfitz.wordpress.com/2009/02/08/continuous-deployment/
• Sonar’s Technical Debt Calculation -
http://www.sonarsource.org/evaluate-your-technical-debt-with-sonar/
• Gherkin - https://github.com/cucumber/cucumber/wiki/Gherkin
61
Further Reading
• Branch by Abstraction, by Paul Hammant
http://paulhammant.com/blog/branch_by_abstraction.html
• Making Large Scale Changes Incrementally with Branch by
Abstraction, by Jez Humble -
http://continuousdelivery.com/2011/05/make-large-scale-changes-
incrementally-with-branch-by-abstraction/
• What is DevOps?, by Damon Edwards -
http://dev2ops.org/2010/02/what-is-devops/
• Monitoring Sucks - https://github.com/monitoringsucks
62
Most orgs struggle to balance…Viewed as mutually exclusive
Cycle Time is a measure of Continuous Delivery maturity
Collaboration (DEV + Customer, DEV + Operations)Talking early and often…break down walls. [DevOps]Automation. Automate Everything! Build, Test, Deploy!Frequency. Frequent means small. Easier to troubleshoot, rollback. Reduces Risk.Feedback. Change triggers feedback. Feedback is fast. Team acts on it.