SlideShare a Scribd company logo
1 of 28
Download to read offline
Rolling Updates: Database
Version Migrations with
minimum Disruption
Anton Kovalenko,
YDB TPM
2
1 2
Rolling
update
YDB Layered
Architecture
3 4
Rolling update:
YDB way
Availability
and Hardware
Failures
Agenda
3
YDB — Open-Source
Distributed SQL
Database
• Relational
ACID OLTP transactions
• Consistency
Strongly consistent
Serializable transaction isolation level
• Mission critical database
Works for projects with 24x7 requirements
• Highly available
Survives AZ plus rack failure w/o human
intervention, available for read/write
4
Users operate tables
to read and write data
• Tables have a primary key (PK)
• Tables are sorted by PK
• Tables could grow up
to petabytes of data
• Tables are automatically
partitioned
Row 1
Row 2
…
Row N
Column 1 Column 2 … Column N
Primary key
Partition 1
…
Partition N
Split point
7
Every software requires update
Single DB server
App1 App2
DB Cluster
App1 App2 App4
App3
DB Node DB Node 1 DB Node 2 DB Node 3
8
What is rolling update
App1 App2
Compute Node 2 Compute Node 3
App3
Compute Node 1
9
1 2 3
Minimize
error rate
Keep read
and write
availability
Minimize latency
degradation
Rolling update challenges are
10
YDB Architecture
application layer
User Application
Tablet
YDB SDK
Compute Layer
gRPC Proxies
Query Processor
Distributed Transactions
User tablets
Tablet
…
Tablet
System tablets
Tablet
…
Storage Layer
Distributed Storage
Internal cluster network
11
YDB SDK hides the complexity
Compute Node 1
App1 App2
Compute Node 2 Compute Node 3
App3
12
1 2 3
Compute
YDB SDK Distributed Storage
YDB Layers
13
YDB storage availability model
NVME
Storage server 1
NVME NVME NVME
Storage server 2
NVME NVME NVME
Storage server 3
NVME NVME
AZ1 AZ2 AZ3
14
YDB storage availability model
vdisk 1
AZ1
vdisk 2 vdisk 3 vdisk 4
AZ2
vdisk 5 vdisk 6 vdisk 7
AZ3
vdisk 8 vdisk 9
Compute Node 1
15
Compute node can
run on any cluster node
Storage Layer
BlobStorage Component
Internal cluster network
Compute
node 1
Compute
node 2
Compute
node 3
Compute
node 4
Compute
node 5
DbName = DB2
DbName = DB1
16
Compute node restart
causes transient errors
Compute
node 1
Compute
node 2
Compute
node 3
Compute
node 4
Compute
node 5
Compute
node 6
App1 App2 App3
AZ1 AZ2 AZ3
17
1 2 3
Minimize
error rate
Keep read
and write
availability
Minimize latency
degradation
Rolling update
is a challenging task
18
Restart storage nodes one by one
AZ1 AZ2 AZ3
Compute
node 100
Rolling restart tool
Storage server 1
Compute
node 101
Compute
node 102
Storage server 2
Compute
node 103
Compute
node 104
Storage server 3
Compute
node 105
19
YDB helps to restart storage
Rolling
restart
tool
4: list of nodes safe to restart
Storage restart constraints
• Keep read and right availability
• Restart as fast as possible
Large cluster restart is long
• 1 node restarts about 10s
• 1k node cluster restart 3h
YDB
Cluster
Management
System
3: request for restart
2: token + list of all nodes
1: restart storage nodes
20
CMS controls compute restarts
Rolling
restart
tool
Compute restart constraints
• Keep enough resources
• Restart as fast as possible
Restart multiple databases
• Databases are independent
• Different databases could be restarted
simultaneously
YDB
Cluster
Management
System
4: list of nodes safe to restart
3: request for restart
2: token + list of all nodes
1: restart compute nodes for some databases
21
CMS allows
to keep availability
Cluster Management System
• YDB Component
• Protects cluster
from unavailability
• Enables restart orchestration
22
Minimize user
operations disruption
Compute node 102
Tablet
Tablet
Tablet
App1
UNAVAILABLE
select name from product where id = 'ydb';
Compute node 101
Tablet
Tablet
Tablet
23
Minimize user operations
disruption
Compute
node 1
Compute
node 2
Compute
node 3
Compute
node 4
Compute
node 5
Compute
node 6
App1 App2 App3
AZ1 AZ2 AZ3
24
Compute node restart
causes errors
Unavailable
Bad session
25
Graceful tablets evacuation
Tablet
AZ1 AZ2 AZ3
Compute
Node 100
Tablet
Tablet
Tablet
Tablet
Compute
Node 101
Tablet
Tablet
Tablet
Rolling restart tool
Tablet
Compute
Node 102
Tablet
Tablet
Tablet
Tablet
Compute
Node 103
Tablet
Tablet
Tablet
Tablet
Compute
Node 104
Tablet
Tablet
Tablet
Tablet
Compute
Node 105
Tablet
Tablet
Tablet
SIGSTOP
26
Graceful session evacuation
Tablet
Tablet
Tablet
Tablet
Tablet
Compute
Node 101
Tablet
Tablet
Tablet
Tablet
Compute
Node 102
Tablet
Tablet
Tablet
Tablet
Compute
Node 103
Tablet
Tablet
Tablet
Tablet
Compute
Node 104
Tablet
Tablet
Tablet
Tablet
Compute
Node 105
Tablet
Tablet
Tablet
SIGSTOP
YDB App
x-ydb-server-hints: session-close
Rolling restart tool
AZ1 AZ2 AZ3
Compute
Node 100
27
• Cluster Management System
Tracks availability
Speeds-up restart
• Session and tablets evacuation
Reduces errors
YDB solves
challenges
28
• PostgreSQL wire and syntax
compatibility (C++)
To simplify migration of our users
we make PostgreSQL compatibility
• OLAP engine (C++)
We build OLAP engine
to improve analytical experience
• Column-organized tables (C++)
We make column-organized tables
to improve performance of analytical queries
• K8S deployment (Go)
We make our own k8s operator to make
it easyto deploy our database
in a cloud environment
Current
challenges
29
It’s easy
to try YDB
ydb.tech
• Managed service in Nebius Cloud
• On premise deployment options
Thank you!
Anton Kovalenko
kovalad@ydb.tech
Join our telegram chat t.me/ydb_en

More Related Content

Similar to stackconf 2023 | Rolling Updates: Database Version Migrations with minimum Disruption by Anton Kovalenko

Leveraging Cassandra for real-time multi-datacenter public cloud analytics
Leveraging Cassandra for real-time multi-datacenter public cloud analyticsLeveraging Cassandra for real-time multi-datacenter public cloud analytics
Leveraging Cassandra for real-time multi-datacenter public cloud analyticsJulien Anguenot
 
iland Internet Solutions: Leveraging Cassandra for real-time multi-datacenter...
iland Internet Solutions: Leveraging Cassandra for real-time multi-datacenter...iland Internet Solutions: Leveraging Cassandra for real-time multi-datacenter...
iland Internet Solutions: Leveraging Cassandra for real-time multi-datacenter...DataStax Academy
 
Reduced instruction set computers
Reduced instruction set computersReduced instruction set computers
Reduced instruction set computersSyed Zaid Irshad
 
Hadoop 3.0 - Revolution or evolution?
Hadoop 3.0 - Revolution or evolution?Hadoop 3.0 - Revolution or evolution?
Hadoop 3.0 - Revolution or evolution?Uwe Printz
 
Scylla Summit 2016: Outbrain Case Study - Lowering Latency While Doing 20X IO...
Scylla Summit 2016: Outbrain Case Study - Lowering Latency While Doing 20X IO...Scylla Summit 2016: Outbrain Case Study - Lowering Latency While Doing 20X IO...
Scylla Summit 2016: Outbrain Case Study - Lowering Latency While Doing 20X IO...ScyllaDB
 
Introducing Cloudian HyperStore 6.0
Introducing Cloudian HyperStore 6.0Introducing Cloudian HyperStore 6.0
Introducing Cloudian HyperStore 6.0Cloudian
 
Red Hat Storage Day Seattle: Stabilizing Petabyte Ceph Cluster in OpenStack C...
Red Hat Storage Day Seattle: Stabilizing Petabyte Ceph Cluster in OpenStack C...Red Hat Storage Day Seattle: Stabilizing Petabyte Ceph Cluster in OpenStack C...
Red Hat Storage Day Seattle: Stabilizing Petabyte Ceph Cluster in OpenStack C...Red_Hat_Storage
 
Migration challenges and process
Migration challenges and processMigration challenges and process
Migration challenges and processAndrejs Vorobjovs
 
Oracle Performance On Linux X86 systems
Oracle  Performance On Linux  X86 systems Oracle  Performance On Linux  X86 systems
Oracle Performance On Linux X86 systems Baruch Osoveskiy
 
Understand oracle real application cluster
Understand oracle real application clusterUnderstand oracle real application cluster
Understand oracle real application clusterSatishbabu Gunukula
 
Resolving Firebird performance problems
Resolving Firebird performance problemsResolving Firebird performance problems
Resolving Firebird performance problemsAlexey Kovyazin
 
Teradata introduction - A basic introduction for Taradate system Architecture
Teradata introduction - A basic introduction for Taradate system ArchitectureTeradata introduction - A basic introduction for Taradate system Architecture
Teradata introduction - A basic introduction for Taradate system ArchitectureMohammad Tahoon
 
Journey to Stability: Petabyte Ceph Cluster in OpenStack Cloud
Journey to Stability: Petabyte Ceph Cluster in OpenStack CloudJourney to Stability: Petabyte Ceph Cluster in OpenStack Cloud
Journey to Stability: Petabyte Ceph Cluster in OpenStack CloudCeph Community
 
Journey to Stability: Petabyte Ceph Cluster in OpenStack Cloud
Journey to Stability: Petabyte Ceph Cluster in OpenStack CloudJourney to Stability: Petabyte Ceph Cluster in OpenStack Cloud
Journey to Stability: Petabyte Ceph Cluster in OpenStack CloudPatrick McGarry
 
Kubernetes at NU.nl (Kubernetes meetup 2019-09-05)
Kubernetes at NU.nl   (Kubernetes meetup 2019-09-05)Kubernetes at NU.nl   (Kubernetes meetup 2019-09-05)
Kubernetes at NU.nl (Kubernetes meetup 2019-09-05)Tibo Beijen
 

Similar to stackconf 2023 | Rolling Updates: Database Version Migrations with minimum Disruption by Anton Kovalenko (20)

Leveraging Cassandra for real-time multi-datacenter public cloud analytics
Leveraging Cassandra for real-time multi-datacenter public cloud analyticsLeveraging Cassandra for real-time multi-datacenter public cloud analytics
Leveraging Cassandra for real-time multi-datacenter public cloud analytics
 
iland Internet Solutions: Leveraging Cassandra for real-time multi-datacenter...
iland Internet Solutions: Leveraging Cassandra for real-time multi-datacenter...iland Internet Solutions: Leveraging Cassandra for real-time multi-datacenter...
iland Internet Solutions: Leveraging Cassandra for real-time multi-datacenter...
 
Reduced instruction set computers
Reduced instruction set computersReduced instruction set computers
Reduced instruction set computers
 
RISC.ppt
RISC.pptRISC.ppt
RISC.ppt
 
13 risc
13 risc13 risc
13 risc
 
Hadoop 3.0 - Revolution or evolution?
Hadoop 3.0 - Revolution or evolution?Hadoop 3.0 - Revolution or evolution?
Hadoop 3.0 - Revolution or evolution?
 
Scylla Summit 2016: Outbrain Case Study - Lowering Latency While Doing 20X IO...
Scylla Summit 2016: Outbrain Case Study - Lowering Latency While Doing 20X IO...Scylla Summit 2016: Outbrain Case Study - Lowering Latency While Doing 20X IO...
Scylla Summit 2016: Outbrain Case Study - Lowering Latency While Doing 20X IO...
 
Introducing Cloudian HyperStore 6.0
Introducing Cloudian HyperStore 6.0Introducing Cloudian HyperStore 6.0
Introducing Cloudian HyperStore 6.0
 
Red Hat Storage Day Seattle: Stabilizing Petabyte Ceph Cluster in OpenStack C...
Red Hat Storage Day Seattle: Stabilizing Petabyte Ceph Cluster in OpenStack C...Red Hat Storage Day Seattle: Stabilizing Petabyte Ceph Cluster in OpenStack C...
Red Hat Storage Day Seattle: Stabilizing Petabyte Ceph Cluster in OpenStack C...
 
Migration challenges and process
Migration challenges and processMigration challenges and process
Migration challenges and process
 
WW Historian 10
WW Historian 10WW Historian 10
WW Historian 10
 
Oracle Performance On Linux X86 systems
Oracle  Performance On Linux  X86 systems Oracle  Performance On Linux  X86 systems
Oracle Performance On Linux X86 systems
 
Understand oracle real application cluster
Understand oracle real application clusterUnderstand oracle real application cluster
Understand oracle real application cluster
 
Resolving Firebird performance problems
Resolving Firebird performance problemsResolving Firebird performance problems
Resolving Firebird performance problems
 
Redshift overview
Redshift overviewRedshift overview
Redshift overview
 
Teradata introduction - A basic introduction for Taradate system Architecture
Teradata introduction - A basic introduction for Taradate system ArchitectureTeradata introduction - A basic introduction for Taradate system Architecture
Teradata introduction - A basic introduction for Taradate system Architecture
 
Journey to Stability: Petabyte Ceph Cluster in OpenStack Cloud
Journey to Stability: Petabyte Ceph Cluster in OpenStack CloudJourney to Stability: Petabyte Ceph Cluster in OpenStack Cloud
Journey to Stability: Petabyte Ceph Cluster in OpenStack Cloud
 
Journey to Stability: Petabyte Ceph Cluster in OpenStack Cloud
Journey to Stability: Petabyte Ceph Cluster in OpenStack CloudJourney to Stability: Petabyte Ceph Cluster in OpenStack Cloud
Journey to Stability: Petabyte Ceph Cluster in OpenStack Cloud
 
Kubernetes at NU.nl (Kubernetes meetup 2019-09-05)
Kubernetes at NU.nl   (Kubernetes meetup 2019-09-05)Kubernetes at NU.nl   (Kubernetes meetup 2019-09-05)
Kubernetes at NU.nl (Kubernetes meetup 2019-09-05)
 
Linux introduction
Linux introductionLinux introduction
Linux introduction
 

Recently uploaded

Top profile Call Girls In Bihar Sharif [ 7014168258 ] Call Me For Genuine Mod...
Top profile Call Girls In Bihar Sharif [ 7014168258 ] Call Me For Genuine Mod...Top profile Call Girls In Bihar Sharif [ 7014168258 ] Call Me For Genuine Mod...
Top profile Call Girls In Bihar Sharif [ 7014168258 ] Call Me For Genuine Mod...nirzagarg
 
Jual obat aborsi Bandung ( 085657271886 ) Cytote pil telat bulan penggugur ka...
Jual obat aborsi Bandung ( 085657271886 ) Cytote pil telat bulan penggugur ka...Jual obat aborsi Bandung ( 085657271886 ) Cytote pil telat bulan penggugur ka...
Jual obat aborsi Bandung ( 085657271886 ) Cytote pil telat bulan penggugur ka...Klinik kandungan
 
5CL-ADBA,5cladba, Chinese supplier, safety is guaranteed
5CL-ADBA,5cladba, Chinese supplier, safety is guaranteed5CL-ADBA,5cladba, Chinese supplier, safety is guaranteed
5CL-ADBA,5cladba, Chinese supplier, safety is guaranteedamy56318795
 
Top profile Call Girls In Satna [ 7014168258 ] Call Me For Genuine Models We ...
Top profile Call Girls In Satna [ 7014168258 ] Call Me For Genuine Models We ...Top profile Call Girls In Satna [ 7014168258 ] Call Me For Genuine Models We ...
Top profile Call Girls In Satna [ 7014168258 ] Call Me For Genuine Models We ...nirzagarg
 
In Riyadh ((+919101817206)) Cytotec kit @ Abortion Pills Saudi Arabia
In Riyadh ((+919101817206)) Cytotec kit @ Abortion Pills Saudi ArabiaIn Riyadh ((+919101817206)) Cytotec kit @ Abortion Pills Saudi Arabia
In Riyadh ((+919101817206)) Cytotec kit @ Abortion Pills Saudi Arabiaahmedjiabur940
 
Top profile Call Girls In bhavnagar [ 7014168258 ] Call Me For Genuine Models...
Top profile Call Girls In bhavnagar [ 7014168258 ] Call Me For Genuine Models...Top profile Call Girls In bhavnagar [ 7014168258 ] Call Me For Genuine Models...
Top profile Call Girls In bhavnagar [ 7014168258 ] Call Me For Genuine Models...gajnagarg
 
Charbagh + Female Escorts Service in Lucknow | Starting ₹,5K To @25k with A/C...
Charbagh + Female Escorts Service in Lucknow | Starting ₹,5K To @25k with A/C...Charbagh + Female Escorts Service in Lucknow | Starting ₹,5K To @25k with A/C...
Charbagh + Female Escorts Service in Lucknow | Starting ₹,5K To @25k with A/C...HyderabadDolls
 
Giridih Escorts Service Girl ^ 9332606886, WhatsApp Anytime Giridih
Giridih Escorts Service Girl ^ 9332606886, WhatsApp Anytime GiridihGiridih Escorts Service Girl ^ 9332606886, WhatsApp Anytime Giridih
Giridih Escorts Service Girl ^ 9332606886, WhatsApp Anytime Giridihmeghakumariji156
 
Oral Sex Call Girls Kashmiri Gate Delhi Just Call 👉👉 📞 8448380779 Top Class C...
Oral Sex Call Girls Kashmiri Gate Delhi Just Call 👉👉 📞 8448380779 Top Class C...Oral Sex Call Girls Kashmiri Gate Delhi Just Call 👉👉 📞 8448380779 Top Class C...
Oral Sex Call Girls Kashmiri Gate Delhi Just Call 👉👉 📞 8448380779 Top Class C...Delhi Call girls
 
Dubai Call Girls Peeing O525547819 Call Girls Dubai
Dubai Call Girls Peeing O525547819 Call Girls DubaiDubai Call Girls Peeing O525547819 Call Girls Dubai
Dubai Call Girls Peeing O525547819 Call Girls Dubaikojalkojal131
 
💞 Safe And Secure Call Girls Agra Call Girls Service Just Call 🍑👄6378878445 🍑...
💞 Safe And Secure Call Girls Agra Call Girls Service Just Call 🍑👄6378878445 🍑...💞 Safe And Secure Call Girls Agra Call Girls Service Just Call 🍑👄6378878445 🍑...
💞 Safe And Secure Call Girls Agra Call Girls Service Just Call 🍑👄6378878445 🍑...vershagrag
 
Top profile Call Girls In dimapur [ 7014168258 ] Call Me For Genuine Models W...
Top profile Call Girls In dimapur [ 7014168258 ] Call Me For Genuine Models W...Top profile Call Girls In dimapur [ 7014168258 ] Call Me For Genuine Models W...
Top profile Call Girls In dimapur [ 7014168258 ] Call Me For Genuine Models W...gajnagarg
 
Digital Transformation Playbook by Graham Ware
Digital Transformation Playbook by Graham WareDigital Transformation Playbook by Graham Ware
Digital Transformation Playbook by Graham WareGraham Ware
 
Sealdah % High Class Call Girls Kolkata - 450+ Call Girl Cash Payment 8005736...
Sealdah % High Class Call Girls Kolkata - 450+ Call Girl Cash Payment 8005736...Sealdah % High Class Call Girls Kolkata - 450+ Call Girl Cash Payment 8005736...
Sealdah % High Class Call Girls Kolkata - 450+ Call Girl Cash Payment 8005736...HyderabadDolls
 
Lake Town / Independent Kolkata Call Girls Phone No 8005736733 Elite Escort S...
Lake Town / Independent Kolkata Call Girls Phone No 8005736733 Elite Escort S...Lake Town / Independent Kolkata Call Girls Phone No 8005736733 Elite Escort S...
Lake Town / Independent Kolkata Call Girls Phone No 8005736733 Elite Escort S...HyderabadDolls
 
Identify Customer Segments to Create Customer Offers for Each Segment - Appli...
Identify Customer Segments to Create Customer Offers for Each Segment - Appli...Identify Customer Segments to Create Customer Offers for Each Segment - Appli...
Identify Customer Segments to Create Customer Offers for Each Segment - Appli...ThinkInnovation
 
Diamond Harbour \ Russian Call Girls Kolkata | Book 8005736733 Extreme Naught...
Diamond Harbour \ Russian Call Girls Kolkata | Book 8005736733 Extreme Naught...Diamond Harbour \ Russian Call Girls Kolkata | Book 8005736733 Extreme Naught...
Diamond Harbour \ Russian Call Girls Kolkata | Book 8005736733 Extreme Naught...HyderabadDolls
 
Top profile Call Girls In Begusarai [ 7014168258 ] Call Me For Genuine Models...
Top profile Call Girls In Begusarai [ 7014168258 ] Call Me For Genuine Models...Top profile Call Girls In Begusarai [ 7014168258 ] Call Me For Genuine Models...
Top profile Call Girls In Begusarai [ 7014168258 ] Call Me For Genuine Models...nirzagarg
 
Kalyani ? Call Girl in Kolkata | Service-oriented sexy call girls 8005736733 ...
Kalyani ? Call Girl in Kolkata | Service-oriented sexy call girls 8005736733 ...Kalyani ? Call Girl in Kolkata | Service-oriented sexy call girls 8005736733 ...
Kalyani ? Call Girl in Kolkata | Service-oriented sexy call girls 8005736733 ...HyderabadDolls
 

Recently uploaded (20)

Top profile Call Girls In Bihar Sharif [ 7014168258 ] Call Me For Genuine Mod...
Top profile Call Girls In Bihar Sharif [ 7014168258 ] Call Me For Genuine Mod...Top profile Call Girls In Bihar Sharif [ 7014168258 ] Call Me For Genuine Mod...
Top profile Call Girls In Bihar Sharif [ 7014168258 ] Call Me For Genuine Mod...
 
Jual obat aborsi Bandung ( 085657271886 ) Cytote pil telat bulan penggugur ka...
Jual obat aborsi Bandung ( 085657271886 ) Cytote pil telat bulan penggugur ka...Jual obat aborsi Bandung ( 085657271886 ) Cytote pil telat bulan penggugur ka...
Jual obat aborsi Bandung ( 085657271886 ) Cytote pil telat bulan penggugur ka...
 
5CL-ADBA,5cladba, Chinese supplier, safety is guaranteed
5CL-ADBA,5cladba, Chinese supplier, safety is guaranteed5CL-ADBA,5cladba, Chinese supplier, safety is guaranteed
5CL-ADBA,5cladba, Chinese supplier, safety is guaranteed
 
Top profile Call Girls In Satna [ 7014168258 ] Call Me For Genuine Models We ...
Top profile Call Girls In Satna [ 7014168258 ] Call Me For Genuine Models We ...Top profile Call Girls In Satna [ 7014168258 ] Call Me For Genuine Models We ...
Top profile Call Girls In Satna [ 7014168258 ] Call Me For Genuine Models We ...
 
Call Girls in G.T.B. Nagar (delhi) call me [🔝9953056974🔝] escort service 24X7
Call Girls in G.T.B. Nagar  (delhi) call me [🔝9953056974🔝] escort service 24X7Call Girls in G.T.B. Nagar  (delhi) call me [🔝9953056974🔝] escort service 24X7
Call Girls in G.T.B. Nagar (delhi) call me [🔝9953056974🔝] escort service 24X7
 
In Riyadh ((+919101817206)) Cytotec kit @ Abortion Pills Saudi Arabia
In Riyadh ((+919101817206)) Cytotec kit @ Abortion Pills Saudi ArabiaIn Riyadh ((+919101817206)) Cytotec kit @ Abortion Pills Saudi Arabia
In Riyadh ((+919101817206)) Cytotec kit @ Abortion Pills Saudi Arabia
 
Top profile Call Girls In bhavnagar [ 7014168258 ] Call Me For Genuine Models...
Top profile Call Girls In bhavnagar [ 7014168258 ] Call Me For Genuine Models...Top profile Call Girls In bhavnagar [ 7014168258 ] Call Me For Genuine Models...
Top profile Call Girls In bhavnagar [ 7014168258 ] Call Me For Genuine Models...
 
Charbagh + Female Escorts Service in Lucknow | Starting ₹,5K To @25k with A/C...
Charbagh + Female Escorts Service in Lucknow | Starting ₹,5K To @25k with A/C...Charbagh + Female Escorts Service in Lucknow | Starting ₹,5K To @25k with A/C...
Charbagh + Female Escorts Service in Lucknow | Starting ₹,5K To @25k with A/C...
 
Giridih Escorts Service Girl ^ 9332606886, WhatsApp Anytime Giridih
Giridih Escorts Service Girl ^ 9332606886, WhatsApp Anytime GiridihGiridih Escorts Service Girl ^ 9332606886, WhatsApp Anytime Giridih
Giridih Escorts Service Girl ^ 9332606886, WhatsApp Anytime Giridih
 
Oral Sex Call Girls Kashmiri Gate Delhi Just Call 👉👉 📞 8448380779 Top Class C...
Oral Sex Call Girls Kashmiri Gate Delhi Just Call 👉👉 📞 8448380779 Top Class C...Oral Sex Call Girls Kashmiri Gate Delhi Just Call 👉👉 📞 8448380779 Top Class C...
Oral Sex Call Girls Kashmiri Gate Delhi Just Call 👉👉 📞 8448380779 Top Class C...
 
Dubai Call Girls Peeing O525547819 Call Girls Dubai
Dubai Call Girls Peeing O525547819 Call Girls DubaiDubai Call Girls Peeing O525547819 Call Girls Dubai
Dubai Call Girls Peeing O525547819 Call Girls Dubai
 
💞 Safe And Secure Call Girls Agra Call Girls Service Just Call 🍑👄6378878445 🍑...
💞 Safe And Secure Call Girls Agra Call Girls Service Just Call 🍑👄6378878445 🍑...💞 Safe And Secure Call Girls Agra Call Girls Service Just Call 🍑👄6378878445 🍑...
💞 Safe And Secure Call Girls Agra Call Girls Service Just Call 🍑👄6378878445 🍑...
 
Top profile Call Girls In dimapur [ 7014168258 ] Call Me For Genuine Models W...
Top profile Call Girls In dimapur [ 7014168258 ] Call Me For Genuine Models W...Top profile Call Girls In dimapur [ 7014168258 ] Call Me For Genuine Models W...
Top profile Call Girls In dimapur [ 7014168258 ] Call Me For Genuine Models W...
 
Digital Transformation Playbook by Graham Ware
Digital Transformation Playbook by Graham WareDigital Transformation Playbook by Graham Ware
Digital Transformation Playbook by Graham Ware
 
Sealdah % High Class Call Girls Kolkata - 450+ Call Girl Cash Payment 8005736...
Sealdah % High Class Call Girls Kolkata - 450+ Call Girl Cash Payment 8005736...Sealdah % High Class Call Girls Kolkata - 450+ Call Girl Cash Payment 8005736...
Sealdah % High Class Call Girls Kolkata - 450+ Call Girl Cash Payment 8005736...
 
Lake Town / Independent Kolkata Call Girls Phone No 8005736733 Elite Escort S...
Lake Town / Independent Kolkata Call Girls Phone No 8005736733 Elite Escort S...Lake Town / Independent Kolkata Call Girls Phone No 8005736733 Elite Escort S...
Lake Town / Independent Kolkata Call Girls Phone No 8005736733 Elite Escort S...
 
Identify Customer Segments to Create Customer Offers for Each Segment - Appli...
Identify Customer Segments to Create Customer Offers for Each Segment - Appli...Identify Customer Segments to Create Customer Offers for Each Segment - Appli...
Identify Customer Segments to Create Customer Offers for Each Segment - Appli...
 
Diamond Harbour \ Russian Call Girls Kolkata | Book 8005736733 Extreme Naught...
Diamond Harbour \ Russian Call Girls Kolkata | Book 8005736733 Extreme Naught...Diamond Harbour \ Russian Call Girls Kolkata | Book 8005736733 Extreme Naught...
Diamond Harbour \ Russian Call Girls Kolkata | Book 8005736733 Extreme Naught...
 
Top profile Call Girls In Begusarai [ 7014168258 ] Call Me For Genuine Models...
Top profile Call Girls In Begusarai [ 7014168258 ] Call Me For Genuine Models...Top profile Call Girls In Begusarai [ 7014168258 ] Call Me For Genuine Models...
Top profile Call Girls In Begusarai [ 7014168258 ] Call Me For Genuine Models...
 
Kalyani ? Call Girl in Kolkata | Service-oriented sexy call girls 8005736733 ...
Kalyani ? Call Girl in Kolkata | Service-oriented sexy call girls 8005736733 ...Kalyani ? Call Girl in Kolkata | Service-oriented sexy call girls 8005736733 ...
Kalyani ? Call Girl in Kolkata | Service-oriented sexy call girls 8005736733 ...
 

stackconf 2023 | Rolling Updates: Database Version Migrations with minimum Disruption by Anton Kovalenko

  • 1. Rolling Updates: Database Version Migrations with minimum Disruption Anton Kovalenko, YDB TPM
  • 2. 2 1 2 Rolling update YDB Layered Architecture 3 4 Rolling update: YDB way Availability and Hardware Failures Agenda
  • 3. 3 YDB — Open-Source Distributed SQL Database • Relational ACID OLTP transactions • Consistency Strongly consistent Serializable transaction isolation level • Mission critical database Works for projects with 24x7 requirements • Highly available Survives AZ plus rack failure w/o human intervention, available for read/write
  • 4. 4 Users operate tables to read and write data • Tables have a primary key (PK) • Tables are sorted by PK • Tables could grow up to petabytes of data • Tables are automatically partitioned Row 1 Row 2 … Row N Column 1 Column 2 … Column N Primary key Partition 1 … Partition N Split point
  • 5. 7 Every software requires update Single DB server App1 App2 DB Cluster App1 App2 App4 App3 DB Node DB Node 1 DB Node 2 DB Node 3
  • 6. 8 What is rolling update App1 App2 Compute Node 2 Compute Node 3 App3 Compute Node 1
  • 7. 9 1 2 3 Minimize error rate Keep read and write availability Minimize latency degradation Rolling update challenges are
  • 8. 10 YDB Architecture application layer User Application Tablet YDB SDK Compute Layer gRPC Proxies Query Processor Distributed Transactions User tablets Tablet … Tablet System tablets Tablet … Storage Layer Distributed Storage Internal cluster network
  • 9. 11 YDB SDK hides the complexity Compute Node 1 App1 App2 Compute Node 2 Compute Node 3 App3
  • 10. 12 1 2 3 Compute YDB SDK Distributed Storage YDB Layers
  • 11. 13 YDB storage availability model NVME Storage server 1 NVME NVME NVME Storage server 2 NVME NVME NVME Storage server 3 NVME NVME AZ1 AZ2 AZ3
  • 12. 14 YDB storage availability model vdisk 1 AZ1 vdisk 2 vdisk 3 vdisk 4 AZ2 vdisk 5 vdisk 6 vdisk 7 AZ3 vdisk 8 vdisk 9 Compute Node 1
  • 13. 15 Compute node can run on any cluster node Storage Layer BlobStorage Component Internal cluster network Compute node 1 Compute node 2 Compute node 3 Compute node 4 Compute node 5 DbName = DB2 DbName = DB1
  • 14. 16 Compute node restart causes transient errors Compute node 1 Compute node 2 Compute node 3 Compute node 4 Compute node 5 Compute node 6 App1 App2 App3 AZ1 AZ2 AZ3
  • 15. 17 1 2 3 Minimize error rate Keep read and write availability Minimize latency degradation Rolling update is a challenging task
  • 16. 18 Restart storage nodes one by one AZ1 AZ2 AZ3 Compute node 100 Rolling restart tool Storage server 1 Compute node 101 Compute node 102 Storage server 2 Compute node 103 Compute node 104 Storage server 3 Compute node 105
  • 17. 19 YDB helps to restart storage Rolling restart tool 4: list of nodes safe to restart Storage restart constraints • Keep read and right availability • Restart as fast as possible Large cluster restart is long • 1 node restarts about 10s • 1k node cluster restart 3h YDB Cluster Management System 3: request for restart 2: token + list of all nodes 1: restart storage nodes
  • 18. 20 CMS controls compute restarts Rolling restart tool Compute restart constraints • Keep enough resources • Restart as fast as possible Restart multiple databases • Databases are independent • Different databases could be restarted simultaneously YDB Cluster Management System 4: list of nodes safe to restart 3: request for restart 2: token + list of all nodes 1: restart compute nodes for some databases
  • 19. 21 CMS allows to keep availability Cluster Management System • YDB Component • Protects cluster from unavailability • Enables restart orchestration
  • 20. 22 Minimize user operations disruption Compute node 102 Tablet Tablet Tablet App1 UNAVAILABLE select name from product where id = 'ydb'; Compute node 101 Tablet Tablet Tablet
  • 21. 23 Minimize user operations disruption Compute node 1 Compute node 2 Compute node 3 Compute node 4 Compute node 5 Compute node 6 App1 App2 App3 AZ1 AZ2 AZ3
  • 22. 24 Compute node restart causes errors Unavailable Bad session
  • 23. 25 Graceful tablets evacuation Tablet AZ1 AZ2 AZ3 Compute Node 100 Tablet Tablet Tablet Tablet Compute Node 101 Tablet Tablet Tablet Rolling restart tool Tablet Compute Node 102 Tablet Tablet Tablet Tablet Compute Node 103 Tablet Tablet Tablet Tablet Compute Node 104 Tablet Tablet Tablet Tablet Compute Node 105 Tablet Tablet Tablet SIGSTOP
  • 24. 26 Graceful session evacuation Tablet Tablet Tablet Tablet Tablet Compute Node 101 Tablet Tablet Tablet Tablet Compute Node 102 Tablet Tablet Tablet Tablet Compute Node 103 Tablet Tablet Tablet Tablet Compute Node 104 Tablet Tablet Tablet Tablet Compute Node 105 Tablet Tablet Tablet SIGSTOP YDB App x-ydb-server-hints: session-close Rolling restart tool AZ1 AZ2 AZ3 Compute Node 100
  • 25. 27 • Cluster Management System Tracks availability Speeds-up restart • Session and tablets evacuation Reduces errors YDB solves challenges
  • 26. 28 • PostgreSQL wire and syntax compatibility (C++) To simplify migration of our users we make PostgreSQL compatibility • OLAP engine (C++) We build OLAP engine to improve analytical experience • Column-organized tables (C++) We make column-organized tables to improve performance of analytical queries • K8S deployment (Go) We make our own k8s operator to make it easyto deploy our database in a cloud environment Current challenges
  • 27. 29 It’s easy to try YDB ydb.tech • Managed service in Nebius Cloud • On premise deployment options
  • 28. Thank you! Anton Kovalenko kovalad@ydb.tech Join our telegram chat t.me/ydb_en