SlideShare una empresa de Scribd logo
1 de 36
Continuous
Integration
Brown Bag by Clarence Bakirtzidis
18th June 2013
Wednesday, 19 June 13
Overview
What is CI?
Benefits of CI
How to start doing CI
Live Demo
Tips for Success
Wednesday, 19 June 13
What is CI?
Continuous Integration = CI
"The aim of Continuous Integration is that the
software is in a working state all the time" [1]
What type of “software” are we talking about?
CI helps avoid “integration hell”
“Bring the pain forward”
[1] Continuous Delivery (book), Jez Humble & David Farley
Wednesday, 19 June 13
What is CI? [cont.]
With CI: Your software is proven to work with
every change (assuming sufficiently
comprehensive automated test suite)
Without CI: Your software is broken until
someone proves it works, usually during a
testing or (typically late) integration stage
Wednesday, 19 June 13
Benefits of CI
Reduced integration time and cost
Reduced delivery risks
Improved and shorter feedback cycles
Improved team communication
Improved software quality
Wednesday, 19 June 13
Benefits of CI [cont.]
Having a comprehensive automated test suite
supports TDD (fast feedback) and refactoring
Early warning system for issues
Visibility of the health and production
readiness of the software outside of the team
Wednesday, 19 June 13
Feedback / Radiators
Image Sources:
#1: http://www.flickr.com/photos/hanuska/5931613961/in/photostream/
#2: http://fabiopereira.me/blog/wp-content/uploads/2009/12/cibuildlightvscidashboardradiator.png
Wednesday, 19 June 13
How to start doing CI
Pre-requisites: Version Control, Automated
Build, Agreement of the team, CI Server
(optional but highly recommended)
Start simple - automate build, add some
automated tests, incremental improvements
Make sure everyone understands the CI
process, scripts and how to run them
Wednesday, 19 June 13
How to start doing CI
Put everything required to build and test your
software in source control
Start building a CI server to run your build,
tests, package, etc, on every commit
Advanced CI: Build and Test Everything: Code
+ Configuration + Infrastructure changes
Typical day-to-day Developer CI scenario...
Wednesday, 19 June 13
Develop
Local
Workstation
Wednesday, 19 June 13
Build
Develop
Local
Workstation
Wednesday, 19 June 13
Mainline Server
Build
Develop
Local
Workstation
Wednesday, 19 June 13
Mainline Server
Build
pull
Develop
Local
Workstation
Wednesday, 19 June 13
Mainline Server
Build
Build
pull
Develop
Local
Workstation
Wednesday, 19 June 13
Mainline Server
Build
Build
pull
Develop
Local
Workstation
push
Wednesday, 19 June 13
Mainline Server
Build
Build
pull
Develop
Local
Workstation
Build
push
Wednesday, 19 June 13
Mainline Server
Build
Build
pull
Develop
Local
Workstation
Build
push
✔
Done!
Wednesday, 19 June 13
Mainline Server
Build
Build
pull
Develop
Local
Workstation
Build
push
✔
Done!
Wednesday, 19 June 13
CI Stages
Images from “Continuous Delivery” (book) by Jez Humble &
David Farley
Wednesday, 19 June 13
CI Stages
Commit stage
Compile
Unit test
Assemble
Code analysis
source code
commit tests
build scripts
deployable binaries
test reports
metadata
Version
control
Artifact
repository
Acceptance test stage
Configure environment
Deploy and smoke test
Acceptance test
Tear down
acceptance tests
deployment scripts
configuration data test reports
metadata
Version
control
Artifact
repository
binaries
Artifact
repository
Images from “Continuous Delivery” (book) by Jez Humble &
David Farley
Wednesday, 19 June 13
Manual Stages
Image from “Continuous Delivery” (book) by Jez Humble &
David Farley
Wednesday, 19 June 13
Manual Stages
Later stages
Configure environment
Deploy and smoke test
Tear down on request
deployment scripts
configuration data
test reports
metadata
Version
control
Artifact
repository
binaries
Artifact
repository
Image from “Continuous Delivery” (book) by Jez Humble &
David Farley
Wednesday, 19 June 13
But what about...
Scheduled builds vs. build on every commit?
Branching vs Mainline: Good or Evil?
Changes that are not ready for use?
Off-the-shelf packages?
Distributed teams?
Large projects?
Wednesday, 19 June 13
P1 P2
G2 G3G1 G4
P3 P4 P5
G5 G6
B1 B2
G1
G1
P1
P1
B1
P2
B1
P1-2
G2
G2
P3
G2
P3
B2
P4
B2
G3
P3 G3
G3
P4
P4 P5
P4-5
G4
G4 G5 G6
P2
Professor Plum
Reverend Green
Mainline
Continuous Integration
Wednesday, 19 June 13
P1 P2
G2 G3G1 G4
P3 P4 P5
G5 G6
B1 B2
G1
G1
P1
P1
B1
P2
B1
P1-2
G2
G2
P3
G2
P3
B2
P4
B2
G3
P3 G3
G3
P4
P4 P5
P4-5
G4
G4 G5 G6
P2
Professor Plum
Reverend Green
Mainline
P1 P2
G2G1
B1
B1
B1
P1-2
G1-2
G3 G4
P4
B2
P5
G5 G6
B2
P3-4
G3
B2
P3
Professor Plum
Reverend Green
Mainline
G1-6
P1-5
P1-5
G1-6
Continuous Integration
Feature Branch
Wednesday, 19 June 13
Continuous Integration
Feature Branch
Wednesday, 19 June 13
Feature
Branch
Wednesday, 19 June 13
Feature
Branch
Release
Branch
Wednesday, 19 June 13
Feature
Branch
Release
Branch
Experimental
Branch
Wednesday, 19 June 13
Live Demo
LOADING, PLEASE WAIT...
Wednesday, 19 June 13
Tips for Success
Checkin regularly - Everyone commits to the
mainline every day
Create a comprehensive automated test suite
Keep the commit stage fast
Make the build visible (dashboards, build
lights)
Automate the build (run it on a CI server)
Wednesday, 19 June 13
Tips for Success
[cont.]
Agree on build hygiene and responsibilities
Don't checkin on a broken build
Take responsibility for all breakages that result
from your changes
Every commit to mainline should be
automatically tested
Don't comment out failing tests
Wednesday, 19 June 13
References
Continuous Integration
Martin Fowler
http://www.martinfowler.com/articles/continuousIntegration.html
Continuous Delivery
Chapter 3 - Continuous Integration, Jez Humble and David Farley, C.
2011 Pearson Education, Inc.
Continuous Integration
Wikipedia
http://en.wikipedia.org/wiki/Continuous_integration
Wednesday, 19 June 13
Next Steps
Books
Continuous Delivery, Jez Humble & David Farley
Continuous Integration, Paul M. Duvall
Internet Resources
"Continuous Integration is an Attitude, Not a Tool" (http://
www.jamesshore.com/Blog/Continuous-Integration-is-an-
Attitude.html)
Wednesday, 19 June 13
Questions?
Clarence Bakirtzidis
Twitter: @clarenceb_oz
Email: clarenceb@gmail.com
Wednesday, 19 June 13
Credits
Slides 10, 14, 15, 16 - Tom Sulston
(@tomsulston), ThoughtWorks, from his
presentation
Slides 11, 12 - Images are from the
“Continuous Delivery” book by Jez Humble &
David Farely
Other photo credits are indicated on the slides
where they are used
Wednesday, 19 June 13

Más contenido relacionado

Similar a Continuous Integration Brown Bag

Buildbot introduction
Buildbot introductionBuildbot introduction
Buildbot introduction
williewu
 

Similar a Continuous Integration Brown Bag (20)

Introduction to CI/CD
Introduction to CI/CDIntroduction to CI/CD
Introduction to CI/CD
 
Continuous integration and delivery and deployment
Continuous integration and delivery and deploymentContinuous integration and delivery and deployment
Continuous integration and delivery and deployment
 
Continuous integration
Continuous integrationContinuous integration
Continuous integration
 
Deploying Mule Applications with Jenkins, Azure and BitBucket (1).pptx
Deploying Mule Applications with Jenkins, Azure and BitBucket (1).pptxDeploying Mule Applications with Jenkins, Azure and BitBucket (1).pptx
Deploying Mule Applications with Jenkins, Azure and BitBucket (1).pptx
 
Buildbot: The Continuous Integration Python framework
Buildbot: The Continuous Integration Python frameworkBuildbot: The Continuous Integration Python framework
Buildbot: The Continuous Integration Python framework
 
Industrialization of Android Development (Concept)
Industrialization of Android Development (Concept)Industrialization of Android Development (Concept)
Industrialization of Android Development (Concept)
 
Flusso Continuous Integration & Continuous Delivery
Flusso Continuous Integration & Continuous DeliveryFlusso Continuous Integration & Continuous Delivery
Flusso Continuous Integration & Continuous Delivery
 
ContinuousIntegration
ContinuousIntegrationContinuousIntegration
ContinuousIntegration
 
Buildbot introduction
Buildbot introductionBuildbot introduction
Buildbot introduction
 
Buildbot
BuildbotBuildbot
Buildbot
 
Continuous integration
Continuous integrationContinuous integration
Continuous integration
 
Continuous integration CloudParty 21 may 2014 - Milan
Continuous integration CloudParty 21 may 2014 - MilanContinuous integration CloudParty 21 may 2014 - Milan
Continuous integration CloudParty 21 may 2014 - Milan
 
Lets talk about CI CD Pipeline in Agile
Lets talk about CI CD Pipeline in Agile Lets talk about CI CD Pipeline in Agile
Lets talk about CI CD Pipeline in Agile
 
Continuous Everything
Continuous EverythingContinuous Everything
Continuous Everything
 
Introduction to Continuous Integration
Introduction to Continuous IntegrationIntroduction to Continuous Integration
Introduction to Continuous Integration
 
Flight East 2018 Presentation–Continuous Integration––An Overview
Flight East 2018 Presentation–Continuous Integration––An OverviewFlight East 2018 Presentation–Continuous Integration––An Overview
Flight East 2018 Presentation–Continuous Integration––An Overview
 
Continuous Integration
Continuous IntegrationContinuous Integration
Continuous Integration
 
Buddy CI/CI
Buddy CI/CIBuddy CI/CI
Buddy CI/CI
 
KraQA#39 - Jak testowac tool do testow
KraQA#39 - Jak testowac tool do testowKraQA#39 - Jak testowac tool do testow
KraQA#39 - Jak testowac tool do testow
 
Turnkey Continuous Delivery
Turnkey Continuous DeliveryTurnkey Continuous Delivery
Turnkey Continuous Delivery
 

Último

EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
Earley Information Science
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Service
giselly40
 

Último (20)

Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
Tech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdfTech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdf
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Service
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 

Continuous Integration Brown Bag