introduction to continuous delivery · 2017-12-06 · continuous delivery frequent releases dev ops...

Post on 22-May-2020

5 Views

Category:

Documents

0 Downloads

Preview:

Click to see full reader

TRANSCRIPT

Continuous Delivery

Graham Brooksgbrooks@thoughtworks.com

Twitter: @grahamcbrooksBlog: http://www.grahambrooks.com/blog

Introduction to

Thursday, March 28, 13

Agile

Iteration 0 1 2 3 4

Analysis + Design

Development

Testing + Showcase

Integration + QA Release and operation

Customer

Centralized QA IT Operations

"Agile" team

The "last mile"

Thursday, March 28, 13

Agile

Iteration 0 1 2 3 4

Analysis + Design

Development

Testing + Showcase

Integration + QA Release and operation

Customer

Centralized QA IT Operations

"Agile" team

The "last mile"

Thursday, March 28, 13

disrupting traditional businesses

http://code.flickr.com/

Thursday, March 28, 13

Building the right thing

every business idea is a hypothesis until you get user feedback

Thursday, March 28, 13

How often features are used

0 12.5 25 37.5 50

Never

Rarely

Sometimes

Often

Always

Source: Standish Group

45%NEVER USED

Thursday, March 28, 13

releasing frequently

feedback from usersCustomer

developent

Agile productdevelopment

Eric Ries, “The Lean Startup” http://bit.ly/8ZoX5F

Thursday, March 28, 13

releasing frequently

feedback from usersreduce risk of release

John Allspaw: “Ops Metametrics” http://slidesha.re/dsSZIr

Thursday, March 28, 13

releasing frequently

feedback from usersreduce risk of releasereal project progress

Thursday, March 28, 13

Agile Manifesto

Our highest priority is to satisfy the customer through early and continuous delivery of valuable software

Thursday, March 28, 13

Production-ready Software

Fast, automated feedback on the production readiness of your applications every time there is a change - to code, infrastructure, or configuration

Thursday, March 28, 13

Continuous Delivery

Customer

Delivery teamConstant flow of new features into production

Thursday, March 28, 13

Software always production ready

Continuous Delivery

Customer

Delivery teamConstant flow of new features into production

Thursday, March 28, 13

Software always production ready

Releases tied to business needs, not operational constraints

Continuous Delivery

Customer

Delivery teamConstant flow of new features into production

Thursday, March 28, 13

CD OverviewContinuous Delivery

Dev OpsFrequent Releases

Automated Testing

Test Strategy

TDD/BDD

Product Support

Pipelines

Continuous Integration

Automaation

Lean Operations

Infrastructure as Code

Configuration Management

Monitoring & Metrics

Kanban for Ops

Lean ITIL

Private Cloud

Thursday, March 28, 13

value stream mapping

Product opportunity assessment

Product discovery Development Final testing

and approval ReleaseProduct

planning and estimation

Elapsed time

Value-added time3 days 1 week 10 days 7 weeks 1 week 2

hours

1 week 10 days 3 days 5 days 2 days

Thursday, March 28, 13

Thursday, March 28, 13

deployment pipeline

Thursday, March 28, 13

an automated implementation of your system’s build, deploy, test, release process

deployment pipeline

Thursday, March 28, 13

visibility

an automated implementation of your system’s build, deploy, test, release process

deployment pipeline

Thursday, March 28, 13

visibility

an automated implementation of your system’s build, deploy, test, release process

feedback

deployment pipeline

Thursday, March 28, 13

visibility

an automated implementation of your system’s build, deploy, test, release process

control

feedback

deployment pipeline

Thursday, March 28, 13

deployment pipelineDelivery team Version control Build & unit

testsAutomated

acceptance testsUser acceptance

testsRelease

Check in

Feedback

Trigger

Check in

Feedback

Trigger

Trigger

Check inTrigger

Trigger

ApprovalApproval

Feedback

Feedback

FeedbackFeedback

Thursday, March 28, 13

deployment pipelineDelivery team Version control Build & unit

testsAutomated

acceptance testsUser acceptance

testsRelease

Check in

Feedback

Trigger

Check in

Feedback

Trigger

Trigger

Check inTrigger

Trigger

ApprovalApproval

Feedback

Feedback

FeedbackFeedback

Thursday, March 28, 13

deployment pipelineDelivery team Version control Build & unit

testsAutomated

acceptance testsUser acceptance

testsRelease

Check in

Feedback

Trigger

Check in

Feedback

Trigger

Trigger

Check inTrigger

Trigger

ApprovalApproval

Feedback

Feedback

FeedbackFeedback

Thursday, March 28, 13

deployment pipelineDelivery team Version control Build & unit

testsAutomated

acceptance testsUser acceptance

testsRelease

Check in

Feedback

Trigger

Check in

Feedback

Trigger

Trigger

Check inTrigger

Trigger

ApprovalApproval

Feedback

Feedback

FeedbackFeedback

Thursday, March 28, 13

Commit Stage

Compile

Unit Test

Unit Test

Build Installers

Acceptance Test Stage

Acceptance Test

User Acceptance Stage

Exploritory

Usability

Performance Stage

Performance

Stability Testing

Production

Production Readiness

Production Like

Production Readiness

Production Like

Production Readiness

Production Like

Production Readiness

Production Like

Feedback

Deployment Pipeline

Thursday, March 28, 13

Commit Stage

Compile

Unit Test

Unit Test

Build Installers

Acceptance Test Stage

Acceptance Test

User Acceptance Stage

Exploritory

Usability

Performance Stage

Performance

Stability Testing

Production

Production Readiness

Production Like

Production Readiness

Production Like

Production Readiness

Production Like

Production Readiness

Production Like

Feedback

Deployment Pipeline

Thursday, March 28, 13

Commit Stage

Compile

Unit Test

Unit Test

Build Installers

Acceptance Test Stage

Acceptance Test

User Acceptance Stage

Exploritory

Usability

Performance Stage

Performance

Stability Testing

Production

Production Readiness

Production Like

Production Readiness

Production Like

Production Readiness

Production Like

Production Readiness

Production Like

Feedback

Deployment Pipeline

Thursday, March 28, 13

Commit Stage

Compile

Unit Test

Unit Test

Build Installers

Acceptance Test Stage

Acceptance Test

User Acceptance Stage

Exploritory

Usability

Performance Stage

Performance

Stability Testing

Production

Production Readiness

Production Like

Production Readiness

Production Like

Production Readiness

Production Like

Production Readiness

Production Like

Feedback

Deployment Pipeline

Thursday, March 28, 13

Commit Stage

Compile

Unit Test

Unit Test

Build Installers

Acceptance Test Stage

Acceptance Test

User Acceptance Stage

Exploritory

Usability

Performance Stage

Performance

Stability Testing

Production

Production Readiness

Production Like

Production Readiness

Production Like

Production Readiness

Production Like

Production Readiness

Production Like

Feedback

Deployment Pipeline

Thursday, March 28, 13

Commit Stage

Compile

Unit Test

Unit Test

Build Installers

Acceptance Test Stage

Acceptance Test

User Acceptance Stage

Exploritory

Usability

Performance Stage

Performance

Stability Testing

Production

Production Readiness

Production Like

Production Readiness

Production Like

Production Readiness

Production Like

Production Readiness

Production Like

Feedback

Deployment Pipeline

Thursday, March 28, 13

Deployment Pipeline

Thursday, March 28, 13

Principles

• create a repeatable, reliable process for releasing software

• automate almost everything

• keep everything in version control

• if it hurts, do it more often, and bring the pain forward

• build quality in

• done means released

• everybody is responsible for delivery

• continuous improvement

Thursday, March 28, 13

Ask this question:-

• “How long would it take your organization to deploy a change that involved just one single line of code? Do you do this on a repeatable, reliable basis?”

• What gets in the way of getting software out of the door?

Mary and Tom Poppendieck, Implementing Lean Software Development, p59.

Thursday, March 28, 13

Practices

Thursday, March 28, 13

only build your binaries once

Practices

Thursday, March 28, 13

only build your binaries once

deploy the same way to every environment

Practices

Thursday, March 28, 13

smoke test your deployments

only build your binaries once

deploy the same way to every environment

Practices

Thursday, March 28, 13

smoke test your deployments

only build your binaries once

deploy the same way to every environment

keep your environments similar

Practices

Thursday, March 28, 13

smoke test your deployments

only build your binaries once

deploy the same way to every environment

if anything fails, stop the line

keep your environments similar

Practices

Thursday, March 28, 13

Continuous IntegrationP1 P2

G2 G3G1 G4

P3 P4 P5

G5 G6

B1 B2

G1

G1

P1

P1B1

P2

B1

P1-2

G2

G2

P3

G2

P3

B2

P4

B2

G3

P3G3

G3

P4

P4 P5

P4-5

G4

G4 G5 G6

P2

Professor Plum

Reverend Green

Mainline

Diagram invented by Martin Fowler

Thursday, March 28, 13

everybody checks in to mainline

Continuous IntegrationP1 P2

G2 G3G1 G4

P3 P4 P5

G5 G6

B1 B2

G1

G1

P1

P1B1

P2

B1

P1-2

G2

G2

P3

G2

P3

B2

P4

B2

G3

P3G3

G3

P4

P4 P5

P4-5

G4

G4 G5 G6

P2

Professor Plum

Reverend Green

Mainline

Diagram invented by Martin Fowler

Thursday, March 28, 13

everybody checks in to mainline

use branch by abstraction for architectural change

Continuous IntegrationP1 P2

G2 G3G1 G4

P3 P4 P5

G5 G6

B1 B2

G1

G1

P1

P1B1

P2

B1

P1-2

G2

G2

P3

G2

P3

B2

P4

B2

G3

P3G3

G3

P4

P4 P5

P4-5

G4

G4 G5 G6

P2

Professor Plum

Reverend Green

Mainline

Diagram invented by Martin Fowler

Thursday, March 28, 13

everybody checks in to mainline

use branch by abstraction for architectural change

use feature bits to switch off incomplete features

Continuous IntegrationP1 P2

G2 G3G1 G4

P3 P4 P5

G5 G6

B1 B2

G1

G1

P1

P1B1

P2

B1

P1-2

G2

G2

P3

G2

P3

B2

P4

B2

G3

P3G3

G3

P4

P4 P5

P4-5

G4

G4 G5 G6

P2

Professor Plum

Reverend Green

Mainline

Diagram invented by Martin Fowler

Thursday, March 28, 13

different kinds of testing

Functional acceptance tests

ShowcasesUsability testing

Exploratory testing

Unit testsIntegration tests

System tests

Non-functional acceptance tests

(performance, scaling, ...)

Business facing

Technology facing

Critiq

ue p

roje

ct

Support

pro

gra

mm

ing

AUTOMATED

AUTOMATED

MANUAL

MANUAL / AUTOMATED

Diagram invented by Brian Marick

Thursday, March 28, 13

Blue Green Testing

Web Server

Blue Slice

Green Slice

RouterUsers

Application Server

Blue Slice

Green Slice

Database Server

Blue Database

Green Database

1.0

1.0

Thursday, March 28, 13

Blue Green Testing

Web Server

Blue Slice

Green Slice

RouterUsers

Application Server

Blue Slice

Green Slice

Database Server

Blue Database

Green Database

1.0

1.1

Thursday, March 28, 13

Blue Green Testing

Web Server

Blue Slice

Green Slice

RouterUsers

Application Server

Blue Slice

Green Slice

Database Server

Blue Database

Green Database

1.0

1.1

Thursday, March 28, 13

Blue Green Testing

Web Server

Blue Slice

Green Slice

RouterUsers

Application Server

Blue Slice

Green Slice

Database Server

Blue Database

Green Database

1.0

1.1

Thursday, March 28, 13

Canary Releases

Thursday, March 28, 13

Data Migration

Thursday, March 28, 13

Objections

Thursday, March 28, 13

Visibility and control over locking down

Objections

Thursday, March 28, 13

Visibility and control over locking down

Compliance - automation over documentation

Objections

Thursday, March 28, 13

Auditing - see who does what

Visibility and control over locking down

Compliance - automation over documentation

Objections

Thursday, March 28, 13

Auditing - see who does what

Visibility and control over locking down

Compliance - automation over documentation

Make it easy to remediate outages

Objections

Thursday, March 28, 13

Auditing - see who does what

Visibility and control over locking down

Compliance - automation over documentation

Make it easy to remediate outages

Objections

Thursday, March 28, 13

People are the key

Thursday, March 28, 13

Get everyone together at the beginning

People are the key

Thursday, March 28, 13

Get everyone together at the beginning

Keep meeting

People are the key

Thursday, March 28, 13

Make it easy for everyone to see what’s happening

Get everyone together at the beginning

Keep meeting

People are the key

Thursday, March 28, 13

Make it easy for everyone to see what’s happening

Get everyone together at the beginning

Keep meeting

Continuous improvement (kaizen)

People are the key

Thursday, March 28, 13

Make it easy for everyone to see what’s happening

Get everyone together at the beginning

Keep meeting

Continuous improvement (kaizen)

People are the key

Thursday, March 28, 13

http://continuousdelivery.com/http://studios.thoughtworks.com/gohttp://thoughtworks.com/http://www.thoughtworks.com/continuous-deliveryhttp://bit.ly/pAkM6B Jeffery Hammond Forrester Consulting

Thank YouGraham Brooks

gbrooks@thoughtworks.comTwitter: @grahamcbrooks

Blog: http://www.grahambrooks.com/blog

Thursday, March 28, 13

top related