continuous deployment

22
Continuous Deployment Timothy Fitz CTO of Canvas

Upload: timothy-fitz

Post on 28-May-2015

3.652 views

Category:

Technology


1 download

TRANSCRIPT

Page 1: Continuous Deployment

Continuous Deployment

Timothy FitzCTO of Canvas

Page 2: Continuous Deployment

“Continuous integration involves integrating early and often, so as to

avoid the pitfalls of "integration hell". The practice aims to reduce timely rework and thus

reduce cost and development time.”

Page 3: Continuous Deployment

“Continuous deployment involves deploying early and often, so as to avoid

the pitfalls of "deployment hell". The practice aims to reduce timely rework and thus

reduce cost and development time.”

Page 4: Continuous Deployment

The Vision

• On every key press– Compile– Run automated tests– Deploy

• “Live Coding”

Page 5: Continuous Deployment

Eliminate Waste

• Deploying code validates assumptions• Bad assumptions cause waste– Code built on top is waste– Design built on top is waste– Thought built on top is waste

Page 6: Continuous Deployment

The Reality

• Change has risk• Infrastructure isn’t free

Page 7: Continuous Deployment
Page 8: Continuous Deployment

At Canvas

• Small CD shop• 5 committers• Deploy process is “git push”

Page 9: Continuous Deployment

At Scale: IMVU

• Profitable• MMO + Virtual Economy Etsy• 50+ Technical Staff

Page 10: Continuous Deployment

At Scale: Etsy

Page 11: Continuous Deployment

The Deploy Equation

• Direct Value (DV)• Information Value (IV)• Deployment Risk• When IV + DV > Risk: Deploy!

Page 12: Continuous Deployment

Increase Information Value

• Small commits mean more information earlier• Implement features implementation-risk-first• Conscious information gathering

Page 13: Continuous Deployment

Increase Direct Value

• Feature shippable from day 0• Never blocked on deploy cycle• Higher velocity• Lean Thinking

Page 14: Continuous Deployment

Risk=

Exposure * Probability * Severity

Page 15: Continuous Deployment

Decrease Exposure

• Dark launch non-frontend changes• Controlled exposure via feature rollout code– Expose to staff/QA only– Expose to opt-in beta testers– Gradually increase exposure from 1-100%

• Feature-level rollback

Page 16: Continuous Deployment

Decrease Probability

• Automated tests– Regression / Functional / Integration tests– Unit tests– Browser tests / Click tests– 3rd party integration tests

• Manual QA prior to exposing features• Build code in a deploy mindset

Page 17: Continuous Deployment

Decrease Severity

• Decrease length of degradation– Production Alerts– Cluster Immune System– Instant production roll back

• Decrease effects of degradation– Stability through isolation– Product level fault tolerance– Lock down core infrastructure

Page 18: Continuous Deployment

FAQ

• What about shema changes?• Great, how do I get started?

Page 19: Continuous Deployment

Schema Changes: They hate your code

• Code and schema move in locked steps• Favor schemaless design– Minimize classical schema changes– Offend DBAs with your lack of normalization– Lightweight/Schemaless databases (“nosql”)

Page 20: Continuous Deployment

Schema Changes: They hate your uptime

• Did I mention schemaless databases yet?• Apply updates to standbys• Blue/Green cluster setup

Page 21: Continuous Deployment

Great, how do I get started?

• Nike method: Just do it

Page 22: Continuous Deployment

tl;dr

• We’ve come a long way• We have a long way to go• IV + DV > Exposure * Probability * Severity.• Rethink schema changes• Continous Deployment: Just do it• Questions?