SlideShare a Scribd company logo
Paul Puschmann | 16.06.2021
How we finally migrated an
eCommerce-Platform to GCP
1
Who’s speaking?
Paul Puschmann, Squad Architect Platform at REWE Digital GmbH

Since July 2014 at REWE Digital GmbH



Taking care about the eCom-infrastructure
2
eCom: What is this?
• eCom / eCommerce-environment is providing customer-faced

applications for REWE

• www.rewe.de

• shop.rewe.de

• Mobile-Apps & API
3
2018
Previous talk: „From Monolith to Microservices“
4
Recap
• Virtual Machines running on dedicated hardware & bare-metal machines

• Automation and configuration with Ansible
5
Migrate to GCP
…meant „migrate to GKE“
6
New approach: "Lift & Shift"?
Use exact the same tooling as in current eCom-setup:

• Terraform everything at GCP

• Use simple GCE-instances

• Configure GCE-instances with Ansible

• "just" migrate datacenters
7
Prerequisites
What’s already in our stack supporting the migration?
• external Cortex & Grafana setup (scalable Prometheus)

• Consul

• Postgres-setup with PgBouncer

• Nomad

• Kafka

• Centralised Container Deployment-Scripts
8
Consul
Basics
9
Consul
Services
10
{
"service": {
"name": "pgbouncer",
"address": "172.30.124.51",
"port": 5432,
"checks": [
{
"id": "pgbouncer_tcp",
"name": "PgBouncer TCP Port 5432",
"tcp": "localhost:5432",
"interval": "10s",
"timeout": "1s"
}
]
}
}
Consul
Docker-Hosts
11
Docker-Host
Consul
Service Discovery
12
Docker-Host-A / 172.30.124.50 Docker-Host-B / 172.30.124.51
nslookup
app-b.service.consul.myinternal-domain1.net. 5 IN A 172.30.124.51
app-b.service.consul.myinternal-domain1.net. 5 IN A 172.30.124.50
Consul
Service Discovery
13
Consul + Prometheus
Service Discovery and Tags
14
"tags": [
"nomad",
„scrape-interval:high",
„prometheus:/admin/metrics"
],
Consul + Prometheus
Service Discovery and Tags
15
{
"service": {
"name": "filebeat-exporter",
"address": "172.30.124.140",
"port": 9479,
"checks": [
{
"id": "http",
"name": "HTTP check",
"http": "http://localhost:9479/",
"interval": "30s",
"timeout": "1s"
}
],
"tags": [
"filebeat",
"scrape-interval:low",
"prometheus:/metrics"
],
}
}
Consul
16
<servicename>.service.consul.<domain> is limited to the local datacenter

Consul
Prepared queries
17
Prepared-Query:

{
"Name": "",
"Template": {
"Type": "name_prefix_match"
},
"Service": {
"Service": "${name.full}",
"Failover": {
"NearestN": 2
}
}
}
<servicename>.service.consul.<domain> is limited to the local datacenter

Solution:



<servicename>.query.consul.<domain>




Not an option:

<servicename>.service.datacenter2.consul.<domain>
How to move from .service.consul. to .query.consul. ?

Using shortnames: change the search-domain in /etc/resolv.conf

Using FQDN: Change the FQDN ;-)
Consul
Prepared queries
18
Consul
Prepared queries in place
19
PostgreSQL
20
PostgreSQL
21
Nomad
Migration of Nomad-jobs / containers
22
Kafka
23
Kafka
Topic / partition reallocation
24
Kafka
Finished reallocation
25
The migrations
26
Migrate Test-environment
• Migrate stuff and don’t tell anybody

• Move back and forth

• Learn

• Read metrics
27
Migrate PRE & prepare PROD
• Setup „hardware“ for PRE & PROD at the same time

• Do it like PROD:

• orchestrated & condensed

• no downtime for PRE
28
The PROD migration
29
The PROD migration
1. Stop external traffic

2. Primary-failover of Postgres & create new replicas

3. Migrate services between datacenters in Nomad

4. Migrate Solr, Redis, Elasticsearch

5. Reconfigure external DNS

6. Reallocate Kafka-Topics in two batches (pareto-split)

1. All smaller topics first

2. The few big topics at last
30
The PROD migration
Finish-line
1. Testing

2. Start external traffic

3. DONE, after 6 hours and 25 minutes

… 50 hours and 50 minutes after „going live again“ all Kafka-data was
reallocated.
31
The PROD migration
Summary of PROD
• 119 new GCE-instances

• 200 micro-services migrated

• 138 databases migrated

• 5 Terabyte of production-data moved (replicas not counted)
32
„Lift & Shift“
Summary
The Platform-Team migrated a complete PROD eCommerce-platform

in six hours from a VMware-environment to GCP

without any other external configuration changes.

The downtime during the migration was only committed to maximise

the data-consistency of the eCommerce-platform.

Everything is in code. Nice!
33
Hashicorp rocks!
We had configured everything using Consul service-discovery,

and this was a huge benefit.
34
was the most essential thing in this migration.
How we finally migrated an eCommerce-Platform to GCP
35
Source: https://vine.co/v/5blZLuKaZrQ
Thank you!
And now: Ask your questions!

Paul Puschmann, @ppuschmann
36

More Related Content

What's hot

Cloud Solution Day 2016: Service Mesh for Kubernetes
Cloud Solution Day 2016: Service Mesh for KubernetesCloud Solution Day 2016: Service Mesh for Kubernetes
Cloud Solution Day 2016: Service Mesh for Kubernetes
AWS Vietnam Community
 
基於 K8S 開發的 FaaS 專案 - riff
基於 K8S 開發的 FaaS 專案 - riff基於 K8S 開發的 FaaS 專案 - riff
基於 K8S 開發的 FaaS 專案 - riff
inwin stack
 
TechTalk - Building Serverless Applications with IBM Bluemix
TechTalk - Building Serverless Applications with IBM BluemixTechTalk - Building Serverless Applications with IBM Bluemix
TechTalk - Building Serverless Applications with IBM Bluemix
Janakiram MSV
 
Knative, Serverless on Kubernetes, and Openshift
Knative, Serverless on Kubernetes, and OpenshiftKnative, Serverless on Kubernetes, and Openshift
Knative, Serverless on Kubernetes, and Openshift
Chris Suszyński
 
[Lakmal] Automate Microservice to API
[Lakmal] Automate Microservice to API[Lakmal] Automate Microservice to API
[Lakmal] Automate Microservice to API
Lakmal Warusawithana
 
Netflix Cloud Platform and Open Source
Netflix Cloud Platform and Open SourceNetflix Cloud Platform and Open Source
Netflix Cloud Platform and Open Source
aspyker
 
IPaaS 2.0: Fuse Integration Services (Robert Davies & Keith Babo)
IPaaS 2.0: Fuse Integration Services (Robert Davies & Keith Babo)IPaaS 2.0: Fuse Integration Services (Robert Davies & Keith Babo)
IPaaS 2.0: Fuse Integration Services (Robert Davies & Keith Babo)
Red Hat Developers
 
Cinder Updates - Liberty Edition
Cinder Updates - Liberty Edition Cinder Updates - Liberty Edition
Cinder Updates - Liberty Edition
OpenStack Foundation
 
ManageIQ Overview at Management and Orchestration Developer (MODM) Meet-up
ManageIQ Overview at Management and Orchestration Developer (MODM) Meet-upManageIQ Overview at Management and Orchestration Developer (MODM) Meet-up
ManageIQ Overview at Management and Orchestration Developer (MODM) Meet-up
Jerome Marc
 
Real World Example of Orchestrating Docker, Node JS, NFV on OpenStack
Real World Example of Orchestrating Docker, Node JS, NFV on OpenStackReal World Example of Orchestrating Docker, Node JS, NFV on OpenStack
Real World Example of Orchestrating Docker, Node JS, NFV on OpenStack
Nati Shalom
 
"Using Automation Tools To Deploy And Operate Applications In Real World Scen...
"Using Automation Tools To Deploy And Operate Applications In Real World Scen..."Using Automation Tools To Deploy And Operate Applications In Real World Scen...
"Using Automation Tools To Deploy And Operate Applications In Real World Scen...
ConSol Consulting & Solutions Software GmbH
 
Microservices architecture pitfalls
Microservices architecture pitfallsMicroservices architecture pitfalls
Microservices architecture pitfalls
allegro.tech
 
Manage thousands of k8s applications with minimal efforts using kube carrier
Manage thousands of k8s applications with minimal efforts using kube carrierManage thousands of k8s applications with minimal efforts using kube carrier
Manage thousands of k8s applications with minimal efforts using kube carrier
LibbySchulze
 
Setup Hybrid Clusters Using Kubernetes Federation
Setup Hybrid Clusters Using Kubernetes FederationSetup Hybrid Clusters Using Kubernetes Federation
Setup Hybrid Clusters Using Kubernetes Federation
inwin stack
 
Nova Updates - Kilo Edition
Nova Updates - Kilo EditionNova Updates - Kilo Edition
Nova Updates - Kilo Edition
OpenStack Foundation
 
Operator development made easy with helm
Operator development made easy with helmOperator development made easy with helm
Operator development made easy with helm
ConSol Consulting & Solutions Software GmbH
 
Spring Cloud and Netflix OSS overview v1
Spring Cloud and Netflix OSS overview v1Spring Cloud and Netflix OSS overview v1
Spring Cloud and Netflix OSS overview v1
Dmitry Skaredov
 
Cloud hub - Overview
Cloud hub - OverviewCloud hub - Overview
Cloud hub - Overview
Prakash Chakravarthi
 
Build your First IoT Application with IBM Watson IoT
Build your First IoT Application with IBM Watson IoTBuild your First IoT Application with IBM Watson IoT
Build your First IoT Application with IBM Watson IoT
Janakiram MSV
 
2019 hashiconf seattle_consul_ioc
2019 hashiconf seattle_consul_ioc2019 hashiconf seattle_consul_ioc
2019 hashiconf seattle_consul_ioc
Pierre Souchay
 

What's hot (20)

Cloud Solution Day 2016: Service Mesh for Kubernetes
Cloud Solution Day 2016: Service Mesh for KubernetesCloud Solution Day 2016: Service Mesh for Kubernetes
Cloud Solution Day 2016: Service Mesh for Kubernetes
 
基於 K8S 開發的 FaaS 專案 - riff
基於 K8S 開發的 FaaS 專案 - riff基於 K8S 開發的 FaaS 專案 - riff
基於 K8S 開發的 FaaS 專案 - riff
 
TechTalk - Building Serverless Applications with IBM Bluemix
TechTalk - Building Serverless Applications with IBM BluemixTechTalk - Building Serverless Applications with IBM Bluemix
TechTalk - Building Serverless Applications with IBM Bluemix
 
Knative, Serverless on Kubernetes, and Openshift
Knative, Serverless on Kubernetes, and OpenshiftKnative, Serverless on Kubernetes, and Openshift
Knative, Serverless on Kubernetes, and Openshift
 
[Lakmal] Automate Microservice to API
[Lakmal] Automate Microservice to API[Lakmal] Automate Microservice to API
[Lakmal] Automate Microservice to API
 
Netflix Cloud Platform and Open Source
Netflix Cloud Platform and Open SourceNetflix Cloud Platform and Open Source
Netflix Cloud Platform and Open Source
 
IPaaS 2.0: Fuse Integration Services (Robert Davies & Keith Babo)
IPaaS 2.0: Fuse Integration Services (Robert Davies & Keith Babo)IPaaS 2.0: Fuse Integration Services (Robert Davies & Keith Babo)
IPaaS 2.0: Fuse Integration Services (Robert Davies & Keith Babo)
 
Cinder Updates - Liberty Edition
Cinder Updates - Liberty Edition Cinder Updates - Liberty Edition
Cinder Updates - Liberty Edition
 
ManageIQ Overview at Management and Orchestration Developer (MODM) Meet-up
ManageIQ Overview at Management and Orchestration Developer (MODM) Meet-upManageIQ Overview at Management and Orchestration Developer (MODM) Meet-up
ManageIQ Overview at Management and Orchestration Developer (MODM) Meet-up
 
Real World Example of Orchestrating Docker, Node JS, NFV on OpenStack
Real World Example of Orchestrating Docker, Node JS, NFV on OpenStackReal World Example of Orchestrating Docker, Node JS, NFV on OpenStack
Real World Example of Orchestrating Docker, Node JS, NFV on OpenStack
 
"Using Automation Tools To Deploy And Operate Applications In Real World Scen...
"Using Automation Tools To Deploy And Operate Applications In Real World Scen..."Using Automation Tools To Deploy And Operate Applications In Real World Scen...
"Using Automation Tools To Deploy And Operate Applications In Real World Scen...
 
Microservices architecture pitfalls
Microservices architecture pitfallsMicroservices architecture pitfalls
Microservices architecture pitfalls
 
Manage thousands of k8s applications with minimal efforts using kube carrier
Manage thousands of k8s applications with minimal efforts using kube carrierManage thousands of k8s applications with minimal efforts using kube carrier
Manage thousands of k8s applications with minimal efforts using kube carrier
 
Setup Hybrid Clusters Using Kubernetes Federation
Setup Hybrid Clusters Using Kubernetes FederationSetup Hybrid Clusters Using Kubernetes Federation
Setup Hybrid Clusters Using Kubernetes Federation
 
Nova Updates - Kilo Edition
Nova Updates - Kilo EditionNova Updates - Kilo Edition
Nova Updates - Kilo Edition
 
Operator development made easy with helm
Operator development made easy with helmOperator development made easy with helm
Operator development made easy with helm
 
Spring Cloud and Netflix OSS overview v1
Spring Cloud and Netflix OSS overview v1Spring Cloud and Netflix OSS overview v1
Spring Cloud and Netflix OSS overview v1
 
Cloud hub - Overview
Cloud hub - OverviewCloud hub - Overview
Cloud hub - Overview
 
Build your First IoT Application with IBM Watson IoT
Build your First IoT Application with IBM Watson IoTBuild your First IoT Application with IBM Watson IoT
Build your First IoT Application with IBM Watson IoT
 
2019 hashiconf seattle_consul_ioc
2019 hashiconf seattle_consul_ioc2019 hashiconf seattle_consul_ioc
2019 hashiconf seattle_consul_ioc
 

Similar to stackconf 2021 | How we finally migrated an eCommerce-Platform to GCP

Deep Dive Into the CERN Cloud Infrastructure - November, 2013
Deep Dive Into the CERN Cloud Infrastructure - November, 2013Deep Dive Into the CERN Cloud Infrastructure - November, 2013
Deep Dive Into the CERN Cloud Infrastructure - November, 2013
Belmiro Moreira
 
2014 11-05 hpcac-kniep_christian_dockermpi
2014 11-05 hpcac-kniep_christian_dockermpi2014 11-05 hpcac-kniep_christian_dockermpi
2014 11-05 hpcac-kniep_christian_dockermpi
QNIB Solutions
 
Globus Compute with Integrated Research Infrastructure (IRI) workflows
Globus Compute with Integrated Research Infrastructure (IRI) workflowsGlobus Compute with Integrated Research Infrastructure (IRI) workflows
Globus Compute with Integrated Research Infrastructure (IRI) workflows
Globus
 
Globus Compute wth IRI Workflows - GlobusWorld 2024
Globus Compute wth IRI Workflows - GlobusWorld 2024Globus Compute wth IRI Workflows - GlobusWorld 2024
Globus Compute wth IRI Workflows - GlobusWorld 2024
Globus
 
The Kubernetes Operator Pattern - ContainerConf Nov 2017
The Kubernetes Operator Pattern - ContainerConf Nov 2017The Kubernetes Operator Pattern - ContainerConf Nov 2017
The Kubernetes Operator Pattern - ContainerConf Nov 2017
Jakob Karalus
 
Distributed Tensorflow with Kubernetes - data2day - Jakob Karalus
Distributed Tensorflow with Kubernetes - data2day - Jakob KaralusDistributed Tensorflow with Kubernetes - data2day - Jakob Karalus
Distributed Tensorflow with Kubernetes - data2day - Jakob Karalus
Jakob Karalus
 
Webinar- Tea for the Tillerman
Webinar- Tea for the TillermanWebinar- Tea for the Tillerman
Webinar- Tea for the Tillerman
Cumulus Networks
 
H-Hypermap Heatmap Analytics at Scale
H-Hypermap Heatmap Analytics at ScaleH-Hypermap Heatmap Analytics at Scale
H-Hypermap Heatmap Analytics at Scale
David Smiley
 
Containers and CloudStack
Containers and CloudStackContainers and CloudStack
Containers and CloudStack
ShapeBlue
 
141204 upload
141204 upload141204 upload
141204 upload
Quey-Liang Kao
 
CDC to the Max!
CDC to the Max!CDC to the Max!
CDC to the Max!
Bronco Oostermeyer
 
Webinar kubernetes and-spark
Webinar  kubernetes and-sparkWebinar  kubernetes and-spark
Webinar kubernetes and-spark
cnvrg.io AI OS - Hands-on ML Workshops
 
Running Airflow Workflows as ETL Processes on Hadoop
Running Airflow Workflows as ETL Processes on HadoopRunning Airflow Workflows as ETL Processes on Hadoop
Running Airflow Workflows as ETL Processes on Hadoop
clairvoyantllc
 
PuppetConf 2016: Changing the Engine While in Flight – Neil Armitage, VMware
PuppetConf 2016: Changing the Engine While in Flight – Neil Armitage, VMwarePuppetConf 2016: Changing the Engine While in Flight – Neil Armitage, VMware
PuppetConf 2016: Changing the Engine While in Flight – Neil Armitage, VMware
Puppet
 
Performance Tuning a Cloud Application: A Real World Case Study
Performance Tuning a Cloud Application: A Real World Case StudyPerformance Tuning a Cloud Application: A Real World Case Study
Performance Tuning a Cloud Application: A Real World Case Study
shane_gibson
 
CloudStack and GitOps at Enterprise Scale - Alex Dometrius, Rene Glover - AT&T
CloudStack and GitOps at Enterprise Scale - Alex Dometrius, Rene Glover - AT&TCloudStack and GitOps at Enterprise Scale - Alex Dometrius, Rene Glover - AT&T
CloudStack and GitOps at Enterprise Scale - Alex Dometrius, Rene Glover - AT&T
ShapeBlue
 
Putting Kafka In Jail – Best Practices To Run Kafka On Kubernetes & DC/OS
Putting Kafka In Jail – Best Practices To Run Kafka On Kubernetes & DC/OSPutting Kafka In Jail – Best Practices To Run Kafka On Kubernetes & DC/OS
Putting Kafka In Jail – Best Practices To Run Kafka On Kubernetes & DC/OS
Lightbend
 
H-Hypermap - Heatmap Analytics at Scale: Presented by David Smiley, D W Smile...
H-Hypermap - Heatmap Analytics at Scale: Presented by David Smiley, D W Smile...H-Hypermap - Heatmap Analytics at Scale: Presented by David Smiley, D W Smile...
H-Hypermap - Heatmap Analytics at Scale: Presented by David Smiley, D W Smile...
Lucidworks
 
RedisConf18 - Redis Enterprise on Cloud Native Platforms
RedisConf18 - Redis Enterprise on Cloud  Native  Platforms RedisConf18 - Redis Enterprise on Cloud  Native  Platforms
RedisConf18 - Redis Enterprise on Cloud Native Platforms
Redis Labs
 
99cloud Docker Training module 2
99cloud Docker Training module 299cloud Docker Training module 2
99cloud Docker Training module 2
Liang Bo
 

Similar to stackconf 2021 | How we finally migrated an eCommerce-Platform to GCP (20)

Deep Dive Into the CERN Cloud Infrastructure - November, 2013
Deep Dive Into the CERN Cloud Infrastructure - November, 2013Deep Dive Into the CERN Cloud Infrastructure - November, 2013
Deep Dive Into the CERN Cloud Infrastructure - November, 2013
 
2014 11-05 hpcac-kniep_christian_dockermpi
2014 11-05 hpcac-kniep_christian_dockermpi2014 11-05 hpcac-kniep_christian_dockermpi
2014 11-05 hpcac-kniep_christian_dockermpi
 
Globus Compute with Integrated Research Infrastructure (IRI) workflows
Globus Compute with Integrated Research Infrastructure (IRI) workflowsGlobus Compute with Integrated Research Infrastructure (IRI) workflows
Globus Compute with Integrated Research Infrastructure (IRI) workflows
 
Globus Compute wth IRI Workflows - GlobusWorld 2024
Globus Compute wth IRI Workflows - GlobusWorld 2024Globus Compute wth IRI Workflows - GlobusWorld 2024
Globus Compute wth IRI Workflows - GlobusWorld 2024
 
The Kubernetes Operator Pattern - ContainerConf Nov 2017
The Kubernetes Operator Pattern - ContainerConf Nov 2017The Kubernetes Operator Pattern - ContainerConf Nov 2017
The Kubernetes Operator Pattern - ContainerConf Nov 2017
 
Distributed Tensorflow with Kubernetes - data2day - Jakob Karalus
Distributed Tensorflow with Kubernetes - data2day - Jakob KaralusDistributed Tensorflow with Kubernetes - data2day - Jakob Karalus
Distributed Tensorflow with Kubernetes - data2day - Jakob Karalus
 
Webinar- Tea for the Tillerman
Webinar- Tea for the TillermanWebinar- Tea for the Tillerman
Webinar- Tea for the Tillerman
 
H-Hypermap Heatmap Analytics at Scale
H-Hypermap Heatmap Analytics at ScaleH-Hypermap Heatmap Analytics at Scale
H-Hypermap Heatmap Analytics at Scale
 
Containers and CloudStack
Containers and CloudStackContainers and CloudStack
Containers and CloudStack
 
141204 upload
141204 upload141204 upload
141204 upload
 
CDC to the Max!
CDC to the Max!CDC to the Max!
CDC to the Max!
 
Webinar kubernetes and-spark
Webinar  kubernetes and-sparkWebinar  kubernetes and-spark
Webinar kubernetes and-spark
 
Running Airflow Workflows as ETL Processes on Hadoop
Running Airflow Workflows as ETL Processes on HadoopRunning Airflow Workflows as ETL Processes on Hadoop
Running Airflow Workflows as ETL Processes on Hadoop
 
PuppetConf 2016: Changing the Engine While in Flight – Neil Armitage, VMware
PuppetConf 2016: Changing the Engine While in Flight – Neil Armitage, VMwarePuppetConf 2016: Changing the Engine While in Flight – Neil Armitage, VMware
PuppetConf 2016: Changing the Engine While in Flight – Neil Armitage, VMware
 
Performance Tuning a Cloud Application: A Real World Case Study
Performance Tuning a Cloud Application: A Real World Case StudyPerformance Tuning a Cloud Application: A Real World Case Study
Performance Tuning a Cloud Application: A Real World Case Study
 
CloudStack and GitOps at Enterprise Scale - Alex Dometrius, Rene Glover - AT&T
CloudStack and GitOps at Enterprise Scale - Alex Dometrius, Rene Glover - AT&TCloudStack and GitOps at Enterprise Scale - Alex Dometrius, Rene Glover - AT&T
CloudStack and GitOps at Enterprise Scale - Alex Dometrius, Rene Glover - AT&T
 
Putting Kafka In Jail – Best Practices To Run Kafka On Kubernetes & DC/OS
Putting Kafka In Jail – Best Practices To Run Kafka On Kubernetes & DC/OSPutting Kafka In Jail – Best Practices To Run Kafka On Kubernetes & DC/OS
Putting Kafka In Jail – Best Practices To Run Kafka On Kubernetes & DC/OS
 
H-Hypermap - Heatmap Analytics at Scale: Presented by David Smiley, D W Smile...
H-Hypermap - Heatmap Analytics at Scale: Presented by David Smiley, D W Smile...H-Hypermap - Heatmap Analytics at Scale: Presented by David Smiley, D W Smile...
H-Hypermap - Heatmap Analytics at Scale: Presented by David Smiley, D W Smile...
 
RedisConf18 - Redis Enterprise on Cloud Native Platforms
RedisConf18 - Redis Enterprise on Cloud  Native  Platforms RedisConf18 - Redis Enterprise on Cloud  Native  Platforms
RedisConf18 - Redis Enterprise on Cloud Native Platforms
 
99cloud Docker Training module 2
99cloud Docker Training module 299cloud Docker Training module 2
99cloud Docker Training module 2
 

Recently uploaded

Using Xen Hypervisor for Functional Safety
Using Xen Hypervisor for Functional SafetyUsing Xen Hypervisor for Functional Safety
Using Xen Hypervisor for Functional Safety
Ayan Halder
 
Vitthal Shirke Java Microservices Resume.pdf
Vitthal Shirke Java Microservices Resume.pdfVitthal Shirke Java Microservices Resume.pdf
Vitthal Shirke Java Microservices Resume.pdf
Vitthal Shirke
 
AI Fusion Buddy Review: Brand New, Groundbreaking Gemini-Powered AI App
AI Fusion Buddy Review: Brand New, Groundbreaking Gemini-Powered AI AppAI Fusion Buddy Review: Brand New, Groundbreaking Gemini-Powered AI App
AI Fusion Buddy Review: Brand New, Groundbreaking Gemini-Powered AI App
Google
 
Artificia Intellicence and XPath Extension Functions
Artificia Intellicence and XPath Extension FunctionsArtificia Intellicence and XPath Extension Functions
Artificia Intellicence and XPath Extension Functions
Octavian Nadolu
 
Need for Speed: Removing speed bumps from your Symfony projects ⚡️
Need for Speed: Removing speed bumps from your Symfony projects ⚡️Need for Speed: Removing speed bumps from your Symfony projects ⚡️
Need for Speed: Removing speed bumps from your Symfony projects ⚡️
Łukasz Chruściel
 
E-commerce Application Development Company.pdf
E-commerce Application Development Company.pdfE-commerce Application Development Company.pdf
E-commerce Application Development Company.pdf
Hornet Dynamics
 
Oracle Database 19c New Features for DBAs and Developers.pptx
Oracle Database 19c New Features for DBAs and Developers.pptxOracle Database 19c New Features for DBAs and Developers.pptx
Oracle Database 19c New Features for DBAs and Developers.pptx
Remote DBA Services
 
Atelier - Innover avec l’IA Générative et les graphes de connaissances
Atelier - Innover avec l’IA Générative et les graphes de connaissancesAtelier - Innover avec l’IA Générative et les graphes de connaissances
Atelier - Innover avec l’IA Générative et les graphes de connaissances
Neo4j
 
Energy consumption of Database Management - Florina Jonuzi
Energy consumption of Database Management - Florina JonuziEnergy consumption of Database Management - Florina Jonuzi
Energy consumption of Database Management - Florina Jonuzi
Green Software Development
 
Fundamentals of Programming and Language Processors
Fundamentals of Programming and Language ProcessorsFundamentals of Programming and Language Processors
Fundamentals of Programming and Language Processors
Rakesh Kumar R
 
E-commerce Development Services- Hornet Dynamics
E-commerce Development Services- Hornet DynamicsE-commerce Development Services- Hornet Dynamics
E-commerce Development Services- Hornet Dynamics
Hornet Dynamics
 
A Study of Variable-Role-based Feature Enrichment in Neural Models of Code
A Study of Variable-Role-based Feature Enrichment in Neural Models of CodeA Study of Variable-Role-based Feature Enrichment in Neural Models of Code
A Study of Variable-Role-based Feature Enrichment in Neural Models of Code
Aftab Hussain
 
Transform Your Communication with Cloud-Based IVR Solutions
Transform Your Communication with Cloud-Based IVR SolutionsTransform Your Communication with Cloud-Based IVR Solutions
Transform Your Communication with Cloud-Based IVR Solutions
TheSMSPoint
 
2024 eCommerceDays Toulouse - Sylius 2.0.pdf
2024 eCommerceDays Toulouse - Sylius 2.0.pdf2024 eCommerceDays Toulouse - Sylius 2.0.pdf
2024 eCommerceDays Toulouse - Sylius 2.0.pdf
Łukasz Chruściel
 
SMS API Integration in Saudi Arabia| Best SMS API Service
SMS API Integration in Saudi Arabia| Best SMS API ServiceSMS API Integration in Saudi Arabia| Best SMS API Service
SMS API Integration in Saudi Arabia| Best SMS API Service
Yara Milbes
 
Graspan: A Big Data System for Big Code Analysis
Graspan: A Big Data System for Big Code AnalysisGraspan: A Big Data System for Big Code Analysis
Graspan: A Big Data System for Big Code Analysis
Aftab Hussain
 
openEuler Case Study - The Journey to Supply Chain Security
openEuler Case Study - The Journey to Supply Chain SecurityopenEuler Case Study - The Journey to Supply Chain Security
openEuler Case Study - The Journey to Supply Chain Security
Shane Coughlan
 
Essentials of Automations: The Art of Triggers and Actions in FME
Essentials of Automations: The Art of Triggers and Actions in FMEEssentials of Automations: The Art of Triggers and Actions in FME
Essentials of Automations: The Art of Triggers and Actions in FME
Safe Software
 
What is Augmented Reality Image Tracking
What is Augmented Reality Image TrackingWhat is Augmented Reality Image Tracking
What is Augmented Reality Image Tracking
pavan998932
 
Hand Rolled Applicative User Validation Code Kata
Hand Rolled Applicative User ValidationCode KataHand Rolled Applicative User ValidationCode Kata
Hand Rolled Applicative User Validation Code Kata
Philip Schwarz
 

Recently uploaded (20)

Using Xen Hypervisor for Functional Safety
Using Xen Hypervisor for Functional SafetyUsing Xen Hypervisor for Functional Safety
Using Xen Hypervisor for Functional Safety
 
Vitthal Shirke Java Microservices Resume.pdf
Vitthal Shirke Java Microservices Resume.pdfVitthal Shirke Java Microservices Resume.pdf
Vitthal Shirke Java Microservices Resume.pdf
 
AI Fusion Buddy Review: Brand New, Groundbreaking Gemini-Powered AI App
AI Fusion Buddy Review: Brand New, Groundbreaking Gemini-Powered AI AppAI Fusion Buddy Review: Brand New, Groundbreaking Gemini-Powered AI App
AI Fusion Buddy Review: Brand New, Groundbreaking Gemini-Powered AI App
 
Artificia Intellicence and XPath Extension Functions
Artificia Intellicence and XPath Extension FunctionsArtificia Intellicence and XPath Extension Functions
Artificia Intellicence and XPath Extension Functions
 
Need for Speed: Removing speed bumps from your Symfony projects ⚡️
Need for Speed: Removing speed bumps from your Symfony projects ⚡️Need for Speed: Removing speed bumps from your Symfony projects ⚡️
Need for Speed: Removing speed bumps from your Symfony projects ⚡️
 
E-commerce Application Development Company.pdf
E-commerce Application Development Company.pdfE-commerce Application Development Company.pdf
E-commerce Application Development Company.pdf
 
Oracle Database 19c New Features for DBAs and Developers.pptx
Oracle Database 19c New Features for DBAs and Developers.pptxOracle Database 19c New Features for DBAs and Developers.pptx
Oracle Database 19c New Features for DBAs and Developers.pptx
 
Atelier - Innover avec l’IA Générative et les graphes de connaissances
Atelier - Innover avec l’IA Générative et les graphes de connaissancesAtelier - Innover avec l’IA Générative et les graphes de connaissances
Atelier - Innover avec l’IA Générative et les graphes de connaissances
 
Energy consumption of Database Management - Florina Jonuzi
Energy consumption of Database Management - Florina JonuziEnergy consumption of Database Management - Florina Jonuzi
Energy consumption of Database Management - Florina Jonuzi
 
Fundamentals of Programming and Language Processors
Fundamentals of Programming and Language ProcessorsFundamentals of Programming and Language Processors
Fundamentals of Programming and Language Processors
 
E-commerce Development Services- Hornet Dynamics
E-commerce Development Services- Hornet DynamicsE-commerce Development Services- Hornet Dynamics
E-commerce Development Services- Hornet Dynamics
 
A Study of Variable-Role-based Feature Enrichment in Neural Models of Code
A Study of Variable-Role-based Feature Enrichment in Neural Models of CodeA Study of Variable-Role-based Feature Enrichment in Neural Models of Code
A Study of Variable-Role-based Feature Enrichment in Neural Models of Code
 
Transform Your Communication with Cloud-Based IVR Solutions
Transform Your Communication with Cloud-Based IVR SolutionsTransform Your Communication with Cloud-Based IVR Solutions
Transform Your Communication with Cloud-Based IVR Solutions
 
2024 eCommerceDays Toulouse - Sylius 2.0.pdf
2024 eCommerceDays Toulouse - Sylius 2.0.pdf2024 eCommerceDays Toulouse - Sylius 2.0.pdf
2024 eCommerceDays Toulouse - Sylius 2.0.pdf
 
SMS API Integration in Saudi Arabia| Best SMS API Service
SMS API Integration in Saudi Arabia| Best SMS API ServiceSMS API Integration in Saudi Arabia| Best SMS API Service
SMS API Integration in Saudi Arabia| Best SMS API Service
 
Graspan: A Big Data System for Big Code Analysis
Graspan: A Big Data System for Big Code AnalysisGraspan: A Big Data System for Big Code Analysis
Graspan: A Big Data System for Big Code Analysis
 
openEuler Case Study - The Journey to Supply Chain Security
openEuler Case Study - The Journey to Supply Chain SecurityopenEuler Case Study - The Journey to Supply Chain Security
openEuler Case Study - The Journey to Supply Chain Security
 
Essentials of Automations: The Art of Triggers and Actions in FME
Essentials of Automations: The Art of Triggers and Actions in FMEEssentials of Automations: The Art of Triggers and Actions in FME
Essentials of Automations: The Art of Triggers and Actions in FME
 
What is Augmented Reality Image Tracking
What is Augmented Reality Image TrackingWhat is Augmented Reality Image Tracking
What is Augmented Reality Image Tracking
 
Hand Rolled Applicative User Validation Code Kata
Hand Rolled Applicative User ValidationCode KataHand Rolled Applicative User ValidationCode Kata
Hand Rolled Applicative User Validation Code Kata
 

stackconf 2021 | How we finally migrated an eCommerce-Platform to GCP

  • 1. Paul Puschmann | 16.06.2021 How we finally migrated an eCommerce-Platform to GCP 1
  • 2. Who’s speaking? Paul Puschmann, Squad Architect Platform at REWE Digital GmbH Since July 2014 at REWE Digital GmbH
 
 Taking care about the eCom-infrastructure 2
  • 3. eCom: What is this? • eCom / eCommerce-environment is providing customer-faced
 applications for REWE • www.rewe.de • shop.rewe.de • Mobile-Apps & API 3
  • 4. 2018 Previous talk: „From Monolith to Microservices“ 4
  • 5. Recap • Virtual Machines running on dedicated hardware & bare-metal machines • Automation and configuration with Ansible 5
  • 6. Migrate to GCP …meant „migrate to GKE“ 6
  • 7. New approach: "Lift & Shift"? Use exact the same tooling as in current eCom-setup: • Terraform everything at GCP • Use simple GCE-instances • Configure GCE-instances with Ansible • "just" migrate datacenters 7
  • 8. Prerequisites What’s already in our stack supporting the migration? • external Cortex & Grafana setup (scalable Prometheus) • Consul • Postgres-setup with PgBouncer • Nomad • Kafka • Centralised Container Deployment-Scripts 8
  • 10. Consul Services 10 { "service": { "name": "pgbouncer", "address": "172.30.124.51", "port": 5432, "checks": [ { "id": "pgbouncer_tcp", "name": "PgBouncer TCP Port 5432", "tcp": "localhost:5432", "interval": "10s", "timeout": "1s" } ] } }
  • 12. Consul Service Discovery 12 Docker-Host-A / 172.30.124.50 Docker-Host-B / 172.30.124.51 nslookup app-b.service.consul.myinternal-domain1.net. 5 IN A 172.30.124.51 app-b.service.consul.myinternal-domain1.net. 5 IN A 172.30.124.50
  • 14. Consul + Prometheus Service Discovery and Tags 14 "tags": [ "nomad", „scrape-interval:high", „prometheus:/admin/metrics" ],
  • 15. Consul + Prometheus Service Discovery and Tags 15 { "service": { "name": "filebeat-exporter", "address": "172.30.124.140", "port": 9479, "checks": [ { "id": "http", "name": "HTTP check", "http": "http://localhost:9479/", "interval": "30s", "timeout": "1s" } ], "tags": [ "filebeat", "scrape-interval:low", "prometheus:/metrics" ], } }
  • 17. <servicename>.service.consul.<domain> is limited to the local datacenter Consul Prepared queries 17 Prepared-Query:
 { "Name": "", "Template": { "Type": "name_prefix_match" }, "Service": { "Service": "${name.full}", "Failover": { "NearestN": 2 } } } <servicename>.service.consul.<domain> is limited to the local datacenter Solution:
 
 <servicename>.query.consul.<domain>
 
 
Not an option: <servicename>.service.datacenter2.consul.<domain>
  • 18. How to move from .service.consul. to .query.consul. ? Using shortnames: change the search-domain in /etc/resolv.conf Using FQDN: Change the FQDN ;-) Consul Prepared queries 18
  • 22. Nomad Migration of Nomad-jobs / containers 22
  • 24. Kafka Topic / partition reallocation 24
  • 27. Migrate Test-environment • Migrate stuff and don’t tell anybody • Move back and forth • Learn • Read metrics 27
  • 28. Migrate PRE & prepare PROD • Setup „hardware“ for PRE & PROD at the same time • Do it like PROD: • orchestrated & condensed • no downtime for PRE 28
  • 30. The PROD migration 1. Stop external traffic 2. Primary-failover of Postgres & create new replicas 3. Migrate services between datacenters in Nomad 4. Migrate Solr, Redis, Elasticsearch 5. Reconfigure external DNS 6. Reallocate Kafka-Topics in two batches (pareto-split) 1. All smaller topics first 2. The few big topics at last 30
  • 31. The PROD migration Finish-line 1. Testing 2. Start external traffic 3. DONE, after 6 hours and 25 minutes … 50 hours and 50 minutes after „going live again“ all Kafka-data was reallocated. 31
  • 32. The PROD migration Summary of PROD • 119 new GCE-instances • 200 micro-services migrated • 138 databases migrated • 5 Terabyte of production-data moved (replicas not counted) 32
  • 33. „Lift & Shift“ Summary The Platform-Team migrated a complete PROD eCommerce-platform
 in six hours from a VMware-environment to GCP
 without any other external configuration changes. The downtime during the migration was only committed to maximise
 the data-consistency of the eCommerce-platform. Everything is in code. Nice! 33
  • 34. Hashicorp rocks! We had configured everything using Consul service-discovery,
 and this was a huge benefit. 34 was the most essential thing in this migration.
  • 35. How we finally migrated an eCommerce-Platform to GCP 35 Source: https://vine.co/v/5blZLuKaZrQ
  • 36. Thank you! And now: Ask your questions! Paul Puschmann, @ppuschmann 36