SlideShare ist ein Scribd-Unternehmen logo
1 von 50
Downloaden Sie, um offline zu lesen
Continuous Deployment Applied
Ran Levy, Backend Director
Elad Shmitanka, Operations engineer
Agenda
● Overview about MyHeritage
● Background – the days before CD
● Why switching to CD?
● CD
● Wins
Family history for Families
Building next generation tools for family history enthusiasts
and their families
Discover Preserve Share
Challenge: Scale
79 million registered users
1.9 billion tree profiles
6.2 billion historical records
200 million photos
42 languages
1 million daily emails
Agenda
● Overview about MyHeritage
● Background – the days before CD
● Why switching to CD?
● CD
● Wins
Background – the days before CD
● Working in branches (many).
● Weekly service pack (dedicated branch).
● Emergencies and HOT Service Pack.
Background – the days before CD
● Advantages:
○ Intensively tested and monitored.
● Disadvantages:
○ Delivering value to user only on weekly basis.
○ Unstable deliveries to QA without clear owner to problems.
○ Developers needs to get back to previous work.
○ Huge time waster across the entire R&D.
○ Difficult rollbacks in case a problem reached production.
Agenda
● Overview about MyHeritage
● Background – the days before CD
● Why switching to CD?
● CD
● Wins
What is Continuous Deployment ?
Continuous Deployment is a set of practices aimed at,
building, testing, and releasing software frequently.
These principles help reduce the cost, time and risk of
delivering changes to customers by allowing for more
incremental changes to applications in production.
Why switching to CD?
● Fast feedback loop.
● Risk reduction.
● Better coding.
● Increase velocity.
● Easy and fast recovery.
● Bridges the gap between QA (team) and Dev.
Agenda
● Overview about MyHeritage
● Background – the days before CD
● Why switching to CD?
● CD
○ Transition phase
○ The early days
○ The future is here
● Wins
The transition phase
Before switching to CD
● Learn from others (like we did).
● Several engineering practices and tools MUST be in
place.
The transition phase
The transition phase
The transition phase
The transition phase
The transition phase
● Gradually skipping Service Pack
○ No actual gain for SPCs (manual dists).
○ We gave up SPCs and the sky didn’t fall.
○ Still coding in branches.
● Small gradual steps:
○ Applying CD in completely new code by a single dev.
○ Applying CD in a single agile team.
○ Applying CD in two agile teams.
The transition phase
● What have we learned?
○ Fewer bugs.
○ More stability in production.
○ Better velocity.
CD – the early days
● More frequent commits.
● Branches have gradually disappeared.
● Manual procedure for updating production
○ Prone to human errors
○ Required dist synchronization
○ Time waster
○ …
● Let’s improve and automate the process
CD – the future is here
What did we have?
● Servers list - Static list
● Scripts - Mixture of PHP and bash
● Error handling - Manual
● SVN problems - Calculating deltas, long processes, conflicts
● Dist method - Rsync , only delta of files
● Queue
● Scripts - Jenkins with a few scripts
Ok, So what did we change?
● Servers list - Mcollective using Puppet filters
● Error handling - Jenkins Flow plugin, catch
● SVN problems - Working on trunk, revert & update
● Dist method - RPM, Mcollective
● Queue - Builtin in Jenkins
What did we add?
● Tests
● Apache configuration changes
● Notifications - In Hipchat, with mentioning
● Daily digest of changes
● Automatic cleanup of the build machine
So, how does it looks like? (Hipchat)
And in jenkins?
Flow schema
Flow schema
Flow schema
Prepare
workspace
Flow schema
Prepare
workspace
Run
Tests
Prepare
assets
Flow schema
Run
Tests
Prepare
assets
Suit 1
Suit 2
Suit n
Build
RPM
IntegrationCanary
Flow schema
Run
Tests
Suit 1
Suit 2
Suit n
Integration
Dist
Flow schema
Suit 1
Suit 2
Suit n
Integration
Dist
Cleanup
Handle
flow
results
Flow schema
Prepare
workspace
Parse commit
message
Run Tests
Build
RPM
Canary Integration
Handle
flow results
Dist Cleanup
Suit 1
Suit 2
Suit n
Prepare
assets
Drilldown
● Jenkins & Groovy hacks
● RPM
● MCollective
● Hipchat integration
● Emergency job
Jenkins & Groovy hacks
● Accessing all the classes of jenkins
● How do we make sure the SVN revision will be static across all the jobs?
Jenkins & Groovy hacks
● Accessing all the classes of jenkins
● How do we make sure the SVN revision will be static across all the jobs?
● How do we know which files changed?
Flow #9 Flow #8 Flow #7 Flow #6
Prepare
workspace
Prepare
workspace
Prepare
workspace
Prepare
workspace
Flow #5
Prepare
workspace
RPM
RPM (RedHat Package Manager) - Package management
system for RedHat (Originally). Contains arbitrary set of files,
configurations files and pre & post scripts.
RPM (continue)
● Why RPM? (In short? a lot)
○ Mature
○ Config files are managed/tracked
○ Version tracking
○ Dependency management
○ Native OS tools to manage lifecycle (install/query/update/uninstall/downgrade)
○ Rich ecosystem and toolchain
○ Always contains the entire codebase (easier to recover from missed updates)
○ Doesn’t touch unmanaged files (i.e PID files)
● Problems we have encountered..
○ Large packages (Reduced from a ~700M to currently ~450M)
○ I/O & Network usage on the repo machine (simple HTTP server)
○ Yum locking mechanism in Puppet
MCollective
MCollective - a framework
for building server
orchestration or parallel
job-execution systems.
Most users
programmatically execute
administrative tasks on
clusters of servers.
MCollective (Continue)
● Packages plugin - https://github.com/myheritage/mcollective-plugin-
packages
● Distributor plugin - In-house
○ Used for emergency dists (explained later)
○ clear cache/reload apache
● Dynamic host list
○ Easier to manage - Given free by Mcollective
○ Host in maintenance - Simply stop Mcollective service
● Scaleable
HipChat
Group and private chat, file sharing, and integrations.
● Has API
● Web, Mobile & desktop clients
● Mentioning
● History
● Rooms
HipChat (Continue)
● Using HipChat plugin V0.1.8
● Plugin allows only limited functionality (0.1.9 offers more), No
customized messages, no mentioning
● Groovy for the rescue!
● HuBot for the rescue!
Emergency job
We have problems in the site, what do we do?
1. Put a stop flag - Disabling new dists
2. Committing a fix and disting emergency
Emergency job
Get changed
files
Compress Upload to httpd
“Go, download and
extract”
Additional problems we’ve encountered
● Parallelism of UnitTests
● Minify failures
● Stop flag job
● Clear cache
○ PHP is script based language
○ Cache is used to improve performance
○ requires cache invalidation
CD 2.0 / Lessons learned
● Improving visibility of the root cause
● Break the Groovy to files and methods
● Yum locking (Should be resolved at Puppet 4.x)
● RPM has it’s disadvantages
○ MCollective RSync plugin (https://github.
com/myheritage/mcollective-rsync-agent)
Agenda
● Overview about MyHeritage
● Background – the days before CD
● Why switching to CD?
● CD
● Wins
Wins
● Around 20-30 dists per day to deliver close feedback and
higher business value.
● Reduced maintenance time for dist procedure.
● Higher quality:
○ Less bugs.
○ Better coding.
○ Increased testing coverage.
Wins
● Reduced code base and assets separation from code base.
● Higher velocity.
● Easy and fast recovery.
● Satisfaction or R&D, DevOps and the organization.
We are hiring!

Weitere ähnliche Inhalte

Was ist angesagt?

Build automation best practices
Build automation best practicesBuild automation best practices
Build automation best practices
Code Mastery
 
Webinar Slides: MySQL HA/DR/Geo-Scale - High Noon #2: Galera Cluster
Webinar Slides: MySQL HA/DR/Geo-Scale - High Noon #2: Galera ClusterWebinar Slides: MySQL HA/DR/Geo-Scale - High Noon #2: Galera Cluster
Webinar Slides: MySQL HA/DR/Geo-Scale - High Noon #2: Galera Cluster
Continuent
 
Continuous delivery with Jenkins Enterprise and Deployit
Continuous delivery with Jenkins Enterprise and DeployitContinuous delivery with Jenkins Enterprise and Deployit
Continuous delivery with Jenkins Enterprise and Deployit
XebiaLabs
 

Was ist angesagt? (20)

Gradle 2.breaking stereotypes.
Gradle 2.breaking stereotypes.Gradle 2.breaking stereotypes.
Gradle 2.breaking stereotypes.
 
LCE13: Linaro Infrastructure Update
LCE13: Linaro Infrastructure UpdateLCE13: Linaro Infrastructure Update
LCE13: Linaro Infrastructure Update
 
Artifacts management with DevOps
Artifacts management with DevOpsArtifacts management with DevOps
Artifacts management with DevOps
 
Scalable Persistent Storage for Erlang: Theory and Practice
Scalable Persistent Storage for Erlang: Theory and PracticeScalable Persistent Storage for Erlang: Theory and Practice
Scalable Persistent Storage for Erlang: Theory and Practice
 
Bryan Heden - Agile Networks - Using Nagios XI as the platform for Monitoring...
Bryan Heden - Agile Networks - Using Nagios XI as the platform for Monitoring...Bryan Heden - Agile Networks - Using Nagios XI as the platform for Monitoring...
Bryan Heden - Agile Networks - Using Nagios XI as the platform for Monitoring...
 
Build automation best practices
Build automation best practicesBuild automation best practices
Build automation best practices
 
Webinar: Accelerate Your Inner Dev Loop for Kubernetes Services
Webinar: Accelerate Your Inner Dev Loop for Kubernetes Services Webinar: Accelerate Your Inner Dev Loop for Kubernetes Services
Webinar: Accelerate Your Inner Dev Loop for Kubernetes Services
 
Atagg2015 Continuous delivery by building environment using docker
Atagg2015 Continuous delivery by building environment using dockerAtagg2015 Continuous delivery by building environment using docker
Atagg2015 Continuous delivery by building environment using docker
 
Idi2018 - Serverless does not mean Opsless
Idi2018 - Serverless does not mean OpslessIdi2018 - Serverless does not mean Opsless
Idi2018 - Serverless does not mean Opsless
 
DevOpsCon 2015 - DevOps in Mobile Games
DevOpsCon 2015 - DevOps in Mobile GamesDevOpsCon 2015 - DevOps in Mobile Games
DevOpsCon 2015 - DevOps in Mobile Games
 
Infinispan from POC to Production
Infinispan from POC to ProductionInfinispan from POC to Production
Infinispan from POC to Production
 
Nagios Conference 2012 - Mike Weber - Failover
Nagios Conference 2012 - Mike Weber - FailoverNagios Conference 2012 - Mike Weber - Failover
Nagios Conference 2012 - Mike Weber - Failover
 
Scaling tappsi
Scaling tappsiScaling tappsi
Scaling tappsi
 
Webinar Slides: MySQL HA/DR/Geo-Scale - High Noon #2: Galera Cluster
Webinar Slides: MySQL HA/DR/Geo-Scale - High Noon #2: Galera ClusterWebinar Slides: MySQL HA/DR/Geo-Scale - High Noon #2: Galera Cluster
Webinar Slides: MySQL HA/DR/Geo-Scale - High Noon #2: Galera Cluster
 
DevOps tools for winning agility
DevOps tools for winning agilityDevOps tools for winning agility
DevOps tools for winning agility
 
Perforce webinar clear-case_jb[2]
Perforce webinar clear-case_jb[2]Perforce webinar clear-case_jb[2]
Perforce webinar clear-case_jb[2]
 
Continuous delivery with Jenkins Enterprise and Deployit
Continuous delivery with Jenkins Enterprise and DeployitContinuous delivery with Jenkins Enterprise and Deployit
Continuous delivery with Jenkins Enterprise and Deployit
 
URP? Excuse You! The Three Kafka Metrics You Need to Know
URP? Excuse You! The Three Kafka Metrics You Need to KnowURP? Excuse You! The Three Kafka Metrics You Need to Know
URP? Excuse You! The Three Kafka Metrics You Need to Know
 
Nagios Conference 2014 - Andy Brist - Nagios XI Failover and HA Solutions
Nagios Conference 2014 - Andy Brist - Nagios XI Failover and HA SolutionsNagios Conference 2014 - Andy Brist - Nagios XI Failover and HA Solutions
Nagios Conference 2014 - Andy Brist - Nagios XI Failover and HA Solutions
 
Migration Concentrate
Migration ConcentrateMigration Concentrate
Migration Concentrate
 

Andere mochten auch

Andere mochten auch (16)

MyHeritage backend 2015 summary
MyHeritage backend 2015 summaryMyHeritage backend 2015 summary
MyHeritage backend 2015 summary
 
Masterless puppet
Masterless puppetMasterless puppet
Masterless puppet
 
Write php deploy everywhere
Write php deploy everywhereWrite php deploy everywhere
Write php deploy everywhere
 
Build your own clouds with Chef and MCollective
Build your own clouds with Chef and MCollectiveBuild your own clouds with Chef and MCollective
Build your own clouds with Chef and MCollective
 
Puppet at Scale – Case Study of PayPal's Learnings - PuppetConf 2013
Puppet at Scale – Case Study of PayPal's Learnings - PuppetConf 2013Puppet at Scale – Case Study of PayPal's Learnings - PuppetConf 2013
Puppet at Scale – Case Study of PayPal's Learnings - PuppetConf 2013
 
Puppet Camp Tokyo 2014: Why we stopped using Puppet Agent Daemon
Puppet Camp Tokyo 2014: Why we stopped using Puppet Agent Daemon Puppet Camp Tokyo 2014: Why we stopped using Puppet Agent Daemon
Puppet Camp Tokyo 2014: Why we stopped using Puppet Agent Daemon
 
Demystifying puppet
Demystifying puppetDemystifying puppet
Demystifying puppet
 
Puppet Camp DC 2014: Managing Puppet with MCollective
Puppet Camp DC 2014: Managing Puppet with MCollectivePuppet Camp DC 2014: Managing Puppet with MCollective
Puppet Camp DC 2014: Managing Puppet with MCollective
 
Wix Automation - Core
Wix Automation - CoreWix Automation - Core
Wix Automation - Core
 
Wix Automation Infrastructure
Wix Automation Infrastructure Wix Automation Infrastructure
Wix Automation Infrastructure
 
Wix automation
Wix automationWix automation
Wix automation
 
Introduction to orchestration using Mcollective
Introduction to orchestration using McollectiveIntroduction to orchestration using Mcollective
Introduction to orchestration using Mcollective
 
PuppetConf track overview: Modern Infrastructure
PuppetConf track overview: Modern InfrastructurePuppetConf track overview: Modern Infrastructure
PuppetConf track overview: Modern Infrastructure
 
11 Ways to Hack Puppet for Fun and Productivity - Luke Kanies - Velocity 2012
11 Ways to Hack Puppet for Fun and Productivity - Luke Kanies - Velocity 201211 Ways to Hack Puppet for Fun and Productivity - Luke Kanies - Velocity 2012
11 Ways to Hack Puppet for Fun and Productivity - Luke Kanies - Velocity 2012
 
Test Automation Best Practices (with SOA test approach)
Test Automation Best Practices (with SOA test approach)Test Automation Best Practices (with SOA test approach)
Test Automation Best Practices (with SOA test approach)
 
Test Automation Framework Designs
Test Automation Framework DesignsTest Automation Framework Designs
Test Automation Framework Designs
 

Ähnlich wie Continuous Deployment Applied at MyHeritage

Continuous Delivery: 5 years later (Incontro DevOps 2018)
Continuous Delivery: 5 years later (Incontro DevOps 2018)Continuous Delivery: 5 years later (Incontro DevOps 2018)
Continuous Delivery: 5 years later (Incontro DevOps 2018)
Giovanni Toraldo
 
RandomTest - Random Software Integration Tests That Just Work for C/C++, Java...
RandomTest - Random Software Integration Tests That Just Work for C/C++, Java...RandomTest - Random Software Integration Tests That Just Work for C/C++, Java...
RandomTest - Random Software Integration Tests That Just Work for C/C++, Java...
dcieslak
 

Ähnlich wie Continuous Deployment Applied at MyHeritage (20)

Continuous Deployment
Continuous DeploymentContinuous Deployment
Continuous Deployment
 
Improve the deployment process step by step
Improve the deployment process step by stepImprove the deployment process step by step
Improve the deployment process step by step
 
Multiplier Effect: Case Studies in Distributions for Publishers
Multiplier Effect: Case Studies in Distributions for PublishersMultiplier Effect: Case Studies in Distributions for Publishers
Multiplier Effect: Case Studies in Distributions for Publishers
 
Software delivery @randstad
Software delivery @randstadSoftware delivery @randstad
Software delivery @randstad
 
Continuous Delivery: 5 years later (Incontro DevOps 2018)
Continuous Delivery: 5 years later (Incontro DevOps 2018)Continuous Delivery: 5 years later (Incontro DevOps 2018)
Continuous Delivery: 5 years later (Incontro DevOps 2018)
 
Apache Cassandra at Target - Cassandra Summit 2014
Apache Cassandra at Target - Cassandra Summit 2014Apache Cassandra at Target - Cassandra Summit 2014
Apache Cassandra at Target - Cassandra Summit 2014
 
Devoxx : being productive with JHipster
Devoxx : being productive with JHipsterDevoxx : being productive with JHipster
Devoxx : being productive with JHipster
 
RandomTest - Random Software Integration Tests That Just Work for C/C++, Java...
RandomTest - Random Software Integration Tests That Just Work for C/C++, Java...RandomTest - Random Software Integration Tests That Just Work for C/C++, Java...
RandomTest - Random Software Integration Tests That Just Work for C/C++, Java...
 
Continuous delivery of Windows micro services in the cloud
Continuous delivery of Windows micro services in the cloud Continuous delivery of Windows micro services in the cloud
Continuous delivery of Windows micro services in the cloud
 
Experiences from DevOps production: Deployment, performance, failure.
Experiences from DevOps production: Deployment, performance, failure.Experiences from DevOps production: Deployment, performance, failure.
Experiences from DevOps production: Deployment, performance, failure.
 
Devops with Python by Yaniv Cohen DevopShift
Devops with Python by Yaniv Cohen DevopShiftDevops with Python by Yaniv Cohen DevopShift
Devops with Python by Yaniv Cohen DevopShift
 
Passing the Joel Test in the PHP World (phpbnl10)
Passing the Joel Test in the PHP World (phpbnl10)Passing the Joel Test in the PHP World (phpbnl10)
Passing the Joel Test in the PHP World (phpbnl10)
 
Snowflake Automated Deployments / CI/CD Pipelines
Snowflake Automated Deployments / CI/CD PipelinesSnowflake Automated Deployments / CI/CD Pipelines
Snowflake Automated Deployments / CI/CD Pipelines
 
LCE13: Test and Validation Mini-Summit: Review Current Linaro Engineering Pro...
LCE13: Test and Validation Mini-Summit: Review Current Linaro Engineering Pro...LCE13: Test and Validation Mini-Summit: Review Current Linaro Engineering Pro...
LCE13: Test and Validation Mini-Summit: Review Current Linaro Engineering Pro...
 
LCE13: Test and Validation Summit: The future of testing at Linaro
LCE13: Test and Validation Summit: The future of testing at LinaroLCE13: Test and Validation Summit: The future of testing at Linaro
LCE13: Test and Validation Summit: The future of testing at Linaro
 
PGConf.ASIA 2019 Bali - Patroni on GitLab.com - Jose Cores Finnoto
PGConf.ASIA 2019 Bali - Patroni on GitLab.com - Jose Cores FinnotoPGConf.ASIA 2019 Bali - Patroni on GitLab.com - Jose Cores Finnoto
PGConf.ASIA 2019 Bali - Patroni on GitLab.com - Jose Cores Finnoto
 
Task migration using CRIU
Task migration using CRIUTask migration using CRIU
Task migration using CRIU
 
The Road to Kubernetes
The Road to KubernetesThe Road to Kubernetes
The Road to Kubernetes
 
GeoServer Developers Workshop
GeoServer Developers WorkshopGeoServer Developers Workshop
GeoServer Developers Workshop
 
My talk at LVEE 2016
My talk at LVEE 2016My talk at LVEE 2016
My talk at LVEE 2016
 

Kürzlich hochgeladen

Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Christo Ananth
 
UNIT-V FMM.HYDRAULIC TURBINE - Construction and working
UNIT-V FMM.HYDRAULIC TURBINE - Construction and workingUNIT-V FMM.HYDRAULIC TURBINE - Construction and working
UNIT-V FMM.HYDRAULIC TURBINE - Construction and working
rknatarajan
 
AKTU Computer Networks notes --- Unit 3.pdf
AKTU Computer Networks notes ---  Unit 3.pdfAKTU Computer Networks notes ---  Unit 3.pdf
AKTU Computer Networks notes --- Unit 3.pdf
ankushspencer015
 

Kürzlich hochgeladen (20)

Water Industry Process Automation & Control Monthly - April 2024
Water Industry Process Automation & Control Monthly - April 2024Water Industry Process Automation & Control Monthly - April 2024
Water Industry Process Automation & Control Monthly - April 2024
 
University management System project report..pdf
University management System project report..pdfUniversity management System project report..pdf
University management System project report..pdf
 
(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...
(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...
(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...
 
Porous Ceramics seminar and technical writing
Porous Ceramics seminar and technical writingPorous Ceramics seminar and technical writing
Porous Ceramics seminar and technical writing
 
The Most Attractive Pune Call Girls Manchar 8250192130 Will You Miss This Cha...
The Most Attractive Pune Call Girls Manchar 8250192130 Will You Miss This Cha...The Most Attractive Pune Call Girls Manchar 8250192130 Will You Miss This Cha...
The Most Attractive Pune Call Girls Manchar 8250192130 Will You Miss This Cha...
 
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
Call for Papers - African Journal of Biological Sciences, E-ISSN: 2663-2187, ...
 
Booking open Available Pune Call Girls Pargaon 6297143586 Call Hot Indian Gi...
Booking open Available Pune Call Girls Pargaon  6297143586 Call Hot Indian Gi...Booking open Available Pune Call Girls Pargaon  6297143586 Call Hot Indian Gi...
Booking open Available Pune Call Girls Pargaon 6297143586 Call Hot Indian Gi...
 
UNIT-V FMM.HYDRAULIC TURBINE - Construction and working
UNIT-V FMM.HYDRAULIC TURBINE - Construction and workingUNIT-V FMM.HYDRAULIC TURBINE - Construction and working
UNIT-V FMM.HYDRAULIC TURBINE - Construction and working
 
Call Girls Service Nagpur Tanvi Call 7001035870 Meet With Nagpur Escorts
Call Girls Service Nagpur Tanvi Call 7001035870 Meet With Nagpur EscortsCall Girls Service Nagpur Tanvi Call 7001035870 Meet With Nagpur Escorts
Call Girls Service Nagpur Tanvi Call 7001035870 Meet With Nagpur Escorts
 
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur Escorts
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur EscortsCall Girls in Nagpur Suman Call 7001035870 Meet With Nagpur Escorts
Call Girls in Nagpur Suman Call 7001035870 Meet With Nagpur Escorts
 
ONLINE FOOD ORDER SYSTEM PROJECT REPORT.pdf
ONLINE FOOD ORDER SYSTEM PROJECT REPORT.pdfONLINE FOOD ORDER SYSTEM PROJECT REPORT.pdf
ONLINE FOOD ORDER SYSTEM PROJECT REPORT.pdf
 
AKTU Computer Networks notes --- Unit 3.pdf
AKTU Computer Networks notes ---  Unit 3.pdfAKTU Computer Networks notes ---  Unit 3.pdf
AKTU Computer Networks notes --- Unit 3.pdf
 
KubeKraft presentation @CloudNativeHooghly
KubeKraft presentation @CloudNativeHooghlyKubeKraft presentation @CloudNativeHooghly
KubeKraft presentation @CloudNativeHooghly
 
College Call Girls Nashik Nehal 7001305949 Independent Escort Service Nashik
College Call Girls Nashik Nehal 7001305949 Independent Escort Service NashikCollege Call Girls Nashik Nehal 7001305949 Independent Escort Service Nashik
College Call Girls Nashik Nehal 7001305949 Independent Escort Service Nashik
 
Coefficient of Thermal Expansion and their Importance.pptx
Coefficient of Thermal Expansion and their Importance.pptxCoefficient of Thermal Expansion and their Importance.pptx
Coefficient of Thermal Expansion and their Importance.pptx
 
BSides Seattle 2024 - Stopping Ethan Hunt From Taking Your Data.pptx
BSides Seattle 2024 - Stopping Ethan Hunt From Taking Your Data.pptxBSides Seattle 2024 - Stopping Ethan Hunt From Taking Your Data.pptx
BSides Seattle 2024 - Stopping Ethan Hunt From Taking Your Data.pptx
 
Introduction to Multiple Access Protocol.pptx
Introduction to Multiple Access Protocol.pptxIntroduction to Multiple Access Protocol.pptx
Introduction to Multiple Access Protocol.pptx
 
(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(PRIYA) Rajgurunagar Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
 
UNIT - IV - Air Compressors and its Performance
UNIT - IV - Air Compressors and its PerformanceUNIT - IV - Air Compressors and its Performance
UNIT - IV - Air Compressors and its Performance
 
MANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLS
MANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLSMANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLS
MANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLS
 

Continuous Deployment Applied at MyHeritage

  • 1. Continuous Deployment Applied Ran Levy, Backend Director Elad Shmitanka, Operations engineer
  • 2. Agenda ● Overview about MyHeritage ● Background – the days before CD ● Why switching to CD? ● CD ● Wins
  • 3. Family history for Families Building next generation tools for family history enthusiasts and their families Discover Preserve Share
  • 4. Challenge: Scale 79 million registered users 1.9 billion tree profiles 6.2 billion historical records 200 million photos 42 languages 1 million daily emails
  • 5. Agenda ● Overview about MyHeritage ● Background – the days before CD ● Why switching to CD? ● CD ● Wins
  • 6. Background – the days before CD ● Working in branches (many). ● Weekly service pack (dedicated branch). ● Emergencies and HOT Service Pack.
  • 7. Background – the days before CD ● Advantages: ○ Intensively tested and monitored. ● Disadvantages: ○ Delivering value to user only on weekly basis. ○ Unstable deliveries to QA without clear owner to problems. ○ Developers needs to get back to previous work. ○ Huge time waster across the entire R&D. ○ Difficult rollbacks in case a problem reached production.
  • 8. Agenda ● Overview about MyHeritage ● Background – the days before CD ● Why switching to CD? ● CD ● Wins
  • 9. What is Continuous Deployment ? Continuous Deployment is a set of practices aimed at, building, testing, and releasing software frequently. These principles help reduce the cost, time and risk of delivering changes to customers by allowing for more incremental changes to applications in production.
  • 10. Why switching to CD? ● Fast feedback loop. ● Risk reduction. ● Better coding. ● Increase velocity. ● Easy and fast recovery. ● Bridges the gap between QA (team) and Dev.
  • 11. Agenda ● Overview about MyHeritage ● Background – the days before CD ● Why switching to CD? ● CD ○ Transition phase ○ The early days ○ The future is here ● Wins
  • 12. The transition phase Before switching to CD ● Learn from others (like we did). ● Several engineering practices and tools MUST be in place.
  • 17. The transition phase ● Gradually skipping Service Pack ○ No actual gain for SPCs (manual dists). ○ We gave up SPCs and the sky didn’t fall. ○ Still coding in branches. ● Small gradual steps: ○ Applying CD in completely new code by a single dev. ○ Applying CD in a single agile team. ○ Applying CD in two agile teams.
  • 18. The transition phase ● What have we learned? ○ Fewer bugs. ○ More stability in production. ○ Better velocity.
  • 19. CD – the early days ● More frequent commits. ● Branches have gradually disappeared. ● Manual procedure for updating production ○ Prone to human errors ○ Required dist synchronization ○ Time waster ○ … ● Let’s improve and automate the process
  • 20. CD – the future is here
  • 21. What did we have? ● Servers list - Static list ● Scripts - Mixture of PHP and bash ● Error handling - Manual ● SVN problems - Calculating deltas, long processes, conflicts ● Dist method - Rsync , only delta of files ● Queue
  • 22. ● Scripts - Jenkins with a few scripts Ok, So what did we change? ● Servers list - Mcollective using Puppet filters ● Error handling - Jenkins Flow plugin, catch ● SVN problems - Working on trunk, revert & update ● Dist method - RPM, Mcollective ● Queue - Builtin in Jenkins
  • 23. What did we add? ● Tests ● Apache configuration changes ● Notifications - In Hipchat, with mentioning ● Daily digest of changes ● Automatic cleanup of the build machine
  • 24. So, how does it looks like? (Hipchat)
  • 30. Flow schema Run Tests Prepare assets Suit 1 Suit 2 Suit n Build RPM IntegrationCanary
  • 31. Flow schema Run Tests Suit 1 Suit 2 Suit n Integration Dist
  • 32. Flow schema Suit 1 Suit 2 Suit n Integration Dist Cleanup Handle flow results
  • 33. Flow schema Prepare workspace Parse commit message Run Tests Build RPM Canary Integration Handle flow results Dist Cleanup Suit 1 Suit 2 Suit n Prepare assets
  • 34. Drilldown ● Jenkins & Groovy hacks ● RPM ● MCollective ● Hipchat integration ● Emergency job
  • 35. Jenkins & Groovy hacks ● Accessing all the classes of jenkins ● How do we make sure the SVN revision will be static across all the jobs?
  • 36. Jenkins & Groovy hacks ● Accessing all the classes of jenkins ● How do we make sure the SVN revision will be static across all the jobs? ● How do we know which files changed? Flow #9 Flow #8 Flow #7 Flow #6 Prepare workspace Prepare workspace Prepare workspace Prepare workspace Flow #5 Prepare workspace
  • 37. RPM RPM (RedHat Package Manager) - Package management system for RedHat (Originally). Contains arbitrary set of files, configurations files and pre & post scripts.
  • 38. RPM (continue) ● Why RPM? (In short? a lot) ○ Mature ○ Config files are managed/tracked ○ Version tracking ○ Dependency management ○ Native OS tools to manage lifecycle (install/query/update/uninstall/downgrade) ○ Rich ecosystem and toolchain ○ Always contains the entire codebase (easier to recover from missed updates) ○ Doesn’t touch unmanaged files (i.e PID files) ● Problems we have encountered.. ○ Large packages (Reduced from a ~700M to currently ~450M) ○ I/O & Network usage on the repo machine (simple HTTP server) ○ Yum locking mechanism in Puppet
  • 39. MCollective MCollective - a framework for building server orchestration or parallel job-execution systems. Most users programmatically execute administrative tasks on clusters of servers.
  • 40. MCollective (Continue) ● Packages plugin - https://github.com/myheritage/mcollective-plugin- packages ● Distributor plugin - In-house ○ Used for emergency dists (explained later) ○ clear cache/reload apache ● Dynamic host list ○ Easier to manage - Given free by Mcollective ○ Host in maintenance - Simply stop Mcollective service ● Scaleable
  • 41. HipChat Group and private chat, file sharing, and integrations. ● Has API ● Web, Mobile & desktop clients ● Mentioning ● History ● Rooms
  • 42. HipChat (Continue) ● Using HipChat plugin V0.1.8 ● Plugin allows only limited functionality (0.1.9 offers more), No customized messages, no mentioning ● Groovy for the rescue! ● HuBot for the rescue!
  • 43. Emergency job We have problems in the site, what do we do? 1. Put a stop flag - Disabling new dists 2. Committing a fix and disting emergency
  • 44. Emergency job Get changed files Compress Upload to httpd “Go, download and extract”
  • 45. Additional problems we’ve encountered ● Parallelism of UnitTests ● Minify failures ● Stop flag job ● Clear cache ○ PHP is script based language ○ Cache is used to improve performance ○ requires cache invalidation
  • 46. CD 2.0 / Lessons learned ● Improving visibility of the root cause ● Break the Groovy to files and methods ● Yum locking (Should be resolved at Puppet 4.x) ● RPM has it’s disadvantages ○ MCollective RSync plugin (https://github. com/myheritage/mcollective-rsync-agent)
  • 47. Agenda ● Overview about MyHeritage ● Background – the days before CD ● Why switching to CD? ● CD ● Wins
  • 48. Wins ● Around 20-30 dists per day to deliver close feedback and higher business value. ● Reduced maintenance time for dist procedure. ● Higher quality: ○ Less bugs. ○ Better coding. ○ Increased testing coverage.
  • 49. Wins ● Reduced code base and assets separation from code base. ● Higher velocity. ● Easy and fast recovery. ● Satisfaction or R&D, DevOps and the organization.