Slide 1

Slide 1 text

CONTINUOUS DELIVERY IN MOTION Avinash Chugh & Praveer Gupta 1

Slide 2

Slide 2 text

AGENDA 2 ■The business case ■A typical delivery pipeline ■Putting it into practice

Slide 3

Slide 3 text

THE BUSINESS CASE 3

Slide 4

Slide 4 text

WHAT DOES IT TAKE FOR A BUSINESS TO SUCCEED 4 Faster time to market Being responsive to customer needs

Slide 5

Slide 5 text

TRUE AGILITY MEANS 5 Collaboration Rapid response to change Working software

Slide 6

Slide 6 text

CONTINUOUS DELIVERY 6 Frequent Releases Reliable Releases

Slide 7

Slide 7 text

PERILS OF LONG RELEASE CYCLES 7 1 1 2 1 2 3 4 1 2 3 Release Time Unreleased changes = risk Risk Value

Slide 8

Slide 8 text

BENEFITS OF FREQUENT RELEASES 8 1 2 3 4 1 1 2 1 2 3 Release Release Release Released changes = value

Slide 9

Slide 9 text

9 HOW CAN I FREQUENTLY RELEASE SOFTWARE HOW CAN I BUILD SOFTWARE INCREMENTALLY HOW CAN I CONFIDENTLY RELEASE NEW SOFTWARE

Slide 10

Slide 10 text

10 Release Iteration Story Commit MODERN DEVELOPMENT CYCLE

Slide 11

Slide 11 text

11 Series of commits Release MANY COMMITS FORMING A RELEASE

Slide 12

Slide 12 text

Release candidates Series of commits WHAT IF EACH COMMIT WERE A RELEASE Releases on demand

Slide 13

Slide 13 text

DELIVERY PIPELINE 13

Slide 14

Slide 14 text

A DELIVERY PIPELINE 14 App Service Library

Slide 15

Slide 15 text

2. CI server checks out & compiles code 4. Code analysis 5. Create & publish artifact 15 3. Unit tests 1. Developer commits code to SCM Commit Stage COMMIT STAGE

Slide 16

Slide 16 text

16 2. Retrieve artifact 4. Run smoke tests 5. Run acceptance tests 3. Deploy artifact 1. Prepare environment Acceptance Stage ACCEPTANCE STAGE

Slide 17

Slide 17 text

17 2. Retrieve artifacts 4. Run smoke tests 3. Deploy artifacts 1. Prepare environment Deploy Stage DEPLOY STAGE One-click deployments

Slide 18

Slide 18 text

1 2 3 4 5 6 A LOT HAPPENS BEFORE A RELEASE 18 Regression testing User Acceptance Integration Infrastructure Setup Performance testing Security Audit

Slide 19

Slide 19 text

Increasing confidence Faster feedback SHORTER RELEASE CYCLE 19 Commit Live

Slide 20

Slide 20 text

TESTING PYRAMID 20 End to end – business facing Localized – technology facing ■Slower feedback ■Higher cost of change

Slide 21

Slide 21 text

DEVELOPMENT IN SILOS 21 Merge Merge Trunk Anti-pattern: Feature branching

Slide 22

Slide 22 text

LOW REUSE AND MERGE ISSUES 22 Merge Merge Trunk 2 2 3 4 2 3 1 1 1 1 4 5 2 3 1 2 1 3 2 1 1 4 3 2 1 4 3 2 1 4 5 2 3

Slide 23

Slide 23 text

COLLABORATIVE DEVELOPMENT 23 Trunk 1 2 3 4 5 1 1 3 4 2 4 5 2 1 3 2 4 3 Key principle: Continuous Integration

Slide 24

Slide 24 text

CONTINUOUS INTEGRATION PRACTICES 24 ■ One component, one repository ■ Everyone commits to trunk every day ■ No branches

Slide 25

Slide 25 text

25 CD Tools IAAS PAAS Mobile Systems Delivering software CONTINUOUS DELIVERY IN DIVERSE CONTEXTS

Slide 26

Slide 26 text

CD IN PRACTICE 26

Slide 27

Slide 27 text

MANAGING LARGE CODE BASES 27 ■ Dependency management ■ Service Oriented Architectures ■ Microservices

Slide 28

Slide 28 text

RELEASING INCOMPLETE WORK 28 [featureToggles] wobblyFoobars: true flightyForkHandles: false Config File ... various UI elements some.jsp forkHandle = (featureConfig.isOn(‘flightlyForkHandles)) ? new FlightyForkHander(aCandle) : new ForkHandler(aCandle) other.java Pattern: Feature toggles

Slide 29

Slide 29 text

GUIDELINES FOR FEATURE TOGGLES 29 ■ Use them only when needed ■ Prefer feature hiding ■ Remove toggles once feature is live

Slide 30

Slide 30 text

MAKING BIG CHANGES 30 Application New Library Library Pattern: Branch by abstraction

Slide 31

Slide 31 text

31 Interface implements Application New Library Library MAKING BIG CHANGES

Slide 32

Slide 32 text

32 Interface implements Application New Library Library MAKING BIG CHANGES

Slide 33

Slide 33 text

33 Interface implements Application New Library Library MAKING BIG CHANGES

Slide 34

Slide 34 text

34 Interface implements Application New Library MAKING BIG CHANGES

Slide 35

Slide 35 text

35 Application New Library MAKING BIG CHANGES

Slide 36

Slide 36 text

WRAPPING UP 36

Slide 37

Slide 37 text

WHAT WE COVERED 37 ■Fast feedback, and short release cycles ■Keeping WIPs to a minimum ■If it’s hard, do it more often ■Trunk-based development ■The need for automation ■Feature toggles ■Branch by abstraction

Slide 38

Slide 38 text

SO MUCH MORE TO EXPLORE 38 ■Deployment strategies ■Automated deployments ■Configuration management ■Infrastructure provisioning ■Cloud deployments ■Virtualization ■Tooling support

Slide 39

Slide 39 text

39 ADDITIONAL READING

Slide 40

Slide 40 text

@thoughtworks THANK YOU