Say Hello to MyRocks
Sergei Petrunia | Senior Software Engineer, MariaDB
sergey@mariadb.com
M|17, April 11-12th
, 2017
2
3
What can be done about this?
4
Data vs Disk

Put some data into the database

How much is written to disk?
INSERT INTO tbl1 VALUES ('foo')

amplification =
size of data
size of data on disk
5
Amplification

Write amplification

Space amplification

Read amplification
amplification =
size of data
size of data on disk
foo
6
Amplification in InnoDB
● B*-tree
● Read amplification
– Assume random data lookup
– Locate the page, read it
– Root page is cached
● ~1 disk read for the leaf page
– Read amplification is ok
7
Write amplification in InnoDB
● Locate the page to update
● Read; modify; write
– Write more if we caused a page split
● One page write per update!
– page_size / sizeof(int)
● Write amplification is an issue.
8
Space amplification in InnoDB
● Page fill factor <100%
– to allow for updates
● Compression is done per-page
– Compressing bigger portions would be
better
– Page alignment
● Compressed to 3K ? Still on 4k page.
● => Space amplification is an issue
9
InnoDB amplification summary
● Read amplification is ok
● Write and space amplification is an issue
– Saturated IO
– Faster SSD wear out
– Need more space on SSD
● => Low storage efficiency
LSM tree
11
Log-structured merge tree
● Writes go to
– Log
– MemTable
● MemTable is flushed
to SortedStringTable
● Writing 2x
– But only useful data
MemTableWrite
Log SST
MemTable
12
Log-structured merge tree
● Writing produces
more SSTs
● SSTs are immutable
● SSTs may have
multiple versions of
data
MemTableWrite
Log SST
MemTable
SST ...
13
Reads in LSM tree
● Need to merge the
data on read
– Read amplification
suffers
● Should not have too
many SSTs.
MemTable Read
Log SST
MemTable
SST ...SST
14
Compaction
● Merge multiple SSTs into one
● Removes old data versions
● Reduces the number of files
● Write amplification++ :-(
SST SST . . .SST
SST
15
Compaction considerations
● Find the sweetspot
– Reduce # SSTs
– Don’t compact too often
● Be efficient
– Compact files of similar size
– Remove duplicate versions asap
● Many strategies
– Leveled
– Size-tiered
SST SST . . .SST
SST
– ...
16
Leveled Compaction
a-c a-f
. . . . . . . . . . . .
b-gL0
L1 a-e f-i j-n o-z
L2 a-b c-g f-k l-q
L7 a-c d-f g-l q-z
MemTable
q-z
5 mb
50 mb
500 mb
17
Leveled Compaction
MemTable
a-c a-f
. . . . . . . . . . . .
b-gL0
L1 a-e f-i j-n o-z
L2 a-b c-g f-k l-q
L5 a-c d-f g-l q-z
q-z
5 mb
50 mb
500 mb
read(‘f’)
18
Leveled Compaction
MemTable
a-c a-f
. . . . . . . . . . . .
b-gL0
L1 a-e f-i j-n o-z
L2 a-b c-g f-k l-q
L5 a-c d-f g-l q-z
q-z
5 mb
50 mb
500 mb
19
Leveled Compaction
MemTable
a-c a-f
. . . . . . . . . . . .
bL0
L1 a-e f-i j-n o-z
L2 a-b c-g f-k l-q
L5 a-c d-f g-l q-z
q-z
5 mb
50 mb
500 mb
20
LSM Tree summary
● LSM architecture
– Data is stored in log, then SST files
– Writes to SST files are sequential, efficient
● Better compression
– Have to read from multiple SST files
– Compaction process merges SST files
● Efficiency
– Write amplification is reduced
– Space amplification is reduced
– Read amplification increases
RocksDB
22
RocksDB
● “An embeddable key-value store for
fast storage environments”
● Uses LSM architecture
– Leveled compaction
– Server-grade
● Initially a fork of LevelDB
● Developed at Facebook
– First release in 2012
– Used at Facebook and many other companies
23
RocksDB properties
● Embedded library
● Stores (key, value) pairs
– No data types
– No secondary indexes
– No SQL-like tables
● Column Families = tablespaces
● No replication support
– There is a 3rd-party addon
● Efficient, but hard to work with
MyRocks
25
MyRocks
● A MySQL storage engine
● Uses RocksDB for storage
● Implements a MySQL storage engine on top
– Secondary indexes
– Data types
– SQL transactions
– …
● Developed* and used by Facebook
– *-- with some MariaDB involvement
26
Size amplification benchmark
● Benchmark data and
chart from Facebook
● Linkbench run
● 24 hours
27
Write amplification benchmark
● Benchmark data and
chart from Facebook
● Linkbench
28
QPS
● Benchmark data and
chart from Facebook
● Linkbench
29
QPS on in-memory workload
● Benchmark data and
chart from Facebook
● Sysbench read-write,
in-memory
● MyRocks doesn’t
always beat InnoDB
30
QPS
● Benchmark data and
chart from Facebook
● Linkbench
31
A real efficiency test
For a certain workload we could reduce the number of MySQL
servers by 50%
– Yoshinori Matsunobu
32
Another write amplification test
● InnoDB
vs
● MyRocks serving 2x
data
InnoDB 2x RocksDB
0
4
8
12
Flash GC
Binlog / Relay log
Storage engine
33
Cumulative response time
0
50000
100000
150000
200000
250000
300000Kilo-Queries
RocksDB x2
InnoDB
34
CPU usage is higher with MyRocks
Time
InnoDB
2x RocksDB
100%
0%
80%
50-60%
35
MyRocks limitations
● Transactional storage engine
– REPEATABLE READ, READ COMMITTED
– No SERIALIZABLE
● Must use Row-based-Replication
● No cross-engine transactions
● Transaction must fit in memory
● Online DDL more limited than InnoDB
36
MyRocks availability
● Part of github.com/facebook/mysql-5.6
● No binaries
● No packages
● Facebook’s branch of MySQL
– Special extensions
– Special ways to compile, run tests, etc
● Not easy to use
MyRocks in MariaDB
38
MyRocks in MariaDB
● New technology
● Built and used at
Facebook’s scale
● Adoption
● Packaging
● Community
● MariaDB features
● ...
39
Getting MyRocks into MariaDB
● Port MyRocks into MariaDB 10.2
– Decouple it from facebook/mysql-5.6 features
– Make it work with MariaDB’s features
● Set up a merge process
– Need to follow Facebook’s progress
● Setup the process to build packages
● Documentation
● Expertise
● ...
40
Getting MyRocks into MariaDB
● Port MyRocks into MariaDB 10.2
– Decouple it from facebook/mysql-5.6 features
– Make it work with MariaDB’s features
● Set up a merge process
– Need to follow Facebook’s progress
● Setup the process to build packages
● Documentation
● Expertise
● ...
✘
✔
✘
✘✔
✔
✔
✔
41
Current status
● “MariaDB 10.2.5 RC includes an ALPHA version of MyRocks
storage engine”
● It’s a loadable plugin (ha_rocksdb.so)
● Packages
– Bintar, deb, rpm, win64 zip + MSI
– Recent versions of OS due to compilers for RocksDB’s
requirements
● Not all features work yet
– Optimizer and SQL features work
– Replication/binlog features don’t work yet.
42
“Is it stable”?
● The components are stable
– (MyRocks + RocksDB) are run in
production @ Facebook
– RocksDB is also used elsewhere
– MyRocks not much. yet.
● Connections with MariaDB
– Some are stable
– Some are [nearly] missing
MyRocks
MariaDB
RocksDB
43
Plans
● Finish the missing pieces
– Storage Engine + binlog
● Improve support for multiple SEs
– MDEV-12179
● Increase maturity
– Pass the tests
– More test coverage
– Benchmarks
● Documentation
MyRocks
MariaDB
RocksDB
44
References
● https://www.slideshare.net/profyclub_ru/making-the-case-for-writeoptimized-da
tabase-algorithms-mark-callaghan-facebook
● https://code.facebook.com/posts/190251048047090/myrocks-a-space-and-write
-optimized-mysql-database
● https://www.facebook.com/atscaleevents/videos/1775545312718565/
● ...
Further information
● 10.00 Real World: Deploying MyRocks in Production at Facebook, Yoshinori
Matsunobu
● http://myrocks.io
● https://mariadb.com/kb/en/mariadb/myrocks-in-mariadb/
Thanks!
Q&A

More Related Content

PDF
MyRocks in MariaDB
PDF
MyRocks in MariaDB | M18
PDF
MyRocks in MariaDB: why and how
PPTX
When is MyRocks good?
PDF
M|18 How to use MyRocks with MariaDB Server
PDF
MyRocks Deep Dive
PPTX
The Hive Think Tank: Rocking the Database World with RocksDB
PPTX
M|18 How Facebook Migrated to MyRocks
MyRocks in MariaDB
MyRocks in MariaDB | M18
MyRocks in MariaDB: why and how
When is MyRocks good?
M|18 How to use MyRocks with MariaDB Server
MyRocks Deep Dive
The Hive Think Tank: Rocking the Database World with RocksDB
M|18 How Facebook Migrated to MyRocks

What's hot (20)

PDF
When is Myrocks good? 2020 Webinar Series
PPTX
PostgreSQL as an Alternative to MSSQL
PDF
PostgreSQL and MySQL
PDF
Ceph and RocksDB
PPTX
Myrocks in the wild wild west! FOSDEM 2020
PPTX
M|18 Writing Stored Procedures in the Real World
PDF
MariaDB: The 2012 Edition
PDF
MariaDB 5.5 and what comes next - Percona Live NYC 2012
PPTX
Inside CynosDB: MariaDB optimized for the cloud at Tencent
PPTX
M|18 How DBAs at TradingScreen Make Life Easier With Automation
PDF
How to migrate from Oracle Database with ease
PPTX
Galaxy Big Data with MariaDB
PDF
Ora mysql bothGetting the best of both worlds with Oracle 11g and MySQL Enter...
PPTX
MariaDB Enterprise & MariaDB Enterprise Cluster - MariaDB Webinar July 2014 F...
PDF
My first moments with MongoDB
PDF
MariaDB: The New M In LAMP - SCALE10x
PDF
M|18 PolarDB: Extending Shared-storage to MyRocks
PDF
M|18 Under the Hood: Galera Cluster
PDF
InnoDB Cluster Experience (MySQL User Camp)
PDF
Distributions from the view a package
When is Myrocks good? 2020 Webinar Series
PostgreSQL as an Alternative to MSSQL
PostgreSQL and MySQL
Ceph and RocksDB
Myrocks in the wild wild west! FOSDEM 2020
M|18 Writing Stored Procedures in the Real World
MariaDB: The 2012 Edition
MariaDB 5.5 and what comes next - Percona Live NYC 2012
Inside CynosDB: MariaDB optimized for the cloud at Tencent
M|18 How DBAs at TradingScreen Make Life Easier With Automation
How to migrate from Oracle Database with ease
Galaxy Big Data with MariaDB
Ora mysql bothGetting the best of both worlds with Oracle 11g and MySQL Enter...
MariaDB Enterprise & MariaDB Enterprise Cluster - MariaDB Webinar July 2014 F...
My first moments with MongoDB
MariaDB: The New M In LAMP - SCALE10x
M|18 PolarDB: Extending Shared-storage to MyRocks
M|18 Under the Hood: Galera Cluster
InnoDB Cluster Experience (MySQL User Camp)
Distributions from the view a package
Ad

Similar to Say Hello to MyRocks (20)

PPTX
PL22 - Backup and Restore Performance.pptx
PDF
LDAP at Lightning Speed
PDF
MongoDB: Advantages of an Open Source NoSQL Database
ODP
Big data nyu
PDF
Complex Ephemeral Caching With Redis: Jeff Pollard
PDF
Apache Iceberg - A Table Format for Hige Analytic Datasets
PDF
The Parquet Format and Performance Optimization Opportunities
PPTX
Percona XtraBackup - New Features and Improvements
PDF
MySQL Performance - Best practices
PDF
Fractal Tree Indexes : From Theory to Practice
PDF
MariaDB 10 and Beyond
PDF
From HDFS to S3: Migrate Pinterest Apache Spark Clusters
PDF
Presto Summit 2018 - 09 - Netflix Iceberg
PDF
Percona 服务器与 XtraDB 存储引擎
PDF
Spark Summit EU 2015: Lessons from 300+ production users
PDF
Object Compaction in Cloud for High Yield
PPTX
MySQL DBA
PDF
PGConf APAC 2018 - High performance json postgre-sql vs. mongodb
PDF
Big data should be simple
PPTX
Creating a Benchmarking Infrastructure That Just Works
PL22 - Backup and Restore Performance.pptx
LDAP at Lightning Speed
MongoDB: Advantages of an Open Source NoSQL Database
Big data nyu
Complex Ephemeral Caching With Redis: Jeff Pollard
Apache Iceberg - A Table Format for Hige Analytic Datasets
The Parquet Format and Performance Optimization Opportunities
Percona XtraBackup - New Features and Improvements
MySQL Performance - Best practices
Fractal Tree Indexes : From Theory to Practice
MariaDB 10 and Beyond
From HDFS to S3: Migrate Pinterest Apache Spark Clusters
Presto Summit 2018 - 09 - Netflix Iceberg
Percona 服务器与 XtraDB 存储引擎
Spark Summit EU 2015: Lessons from 300+ production users
Object Compaction in Cloud for High Yield
MySQL DBA
PGConf APAC 2018 - High performance json postgre-sql vs. mongodb
Big data should be simple
Creating a Benchmarking Infrastructure That Just Works
Ad

More from Sergey Petrunya (20)

PDF
MariaDB's New-Generation Optimizer Hints
PDF
New optimizer features in MariaDB releases before 10.12
PDF
MariaDB's join optimizer: how it works and current fixes
PDF
Improved histograms in MariaDB 10.8
PDF
Improving MariaDB’s Query Optimizer with better selectivity estimates
PDF
JSON Support in MariaDB: News, non-news and the bigger picture
PDF
Optimizer Trace Walkthrough
PDF
ANALYZE for Statements - MariaDB's hidden gem
PDF
Optimizer features in recent releases of other databases
PDF
MariaDB 10.4 - что нового
PDF
Using histograms to get better performance
PDF
MariaDB Optimizer - further down the rabbit hole
PDF
Query Optimizer in MariaDB 10.4
PDF
Lessons for the optimizer from running the TPC-DS benchmark
PDF
MariaDB 10.3 Optimizer - where does it stand
PDF
New Query Optimizer features in MariaDB 10.3
PDF
Histograms in MariaDB, MySQL and PostgreSQL
PDF
Common Table Expressions in MariaDB 10.2
PDF
Эволюция репликации в MySQL и MariaDB
PDF
Common Table Expressions in MariaDB 10.2 (Percona Live Amsterdam 2016)
MariaDB's New-Generation Optimizer Hints
New optimizer features in MariaDB releases before 10.12
MariaDB's join optimizer: how it works and current fixes
Improved histograms in MariaDB 10.8
Improving MariaDB’s Query Optimizer with better selectivity estimates
JSON Support in MariaDB: News, non-news and the bigger picture
Optimizer Trace Walkthrough
ANALYZE for Statements - MariaDB's hidden gem
Optimizer features in recent releases of other databases
MariaDB 10.4 - что нового
Using histograms to get better performance
MariaDB Optimizer - further down the rabbit hole
Query Optimizer in MariaDB 10.4
Lessons for the optimizer from running the TPC-DS benchmark
MariaDB 10.3 Optimizer - where does it stand
New Query Optimizer features in MariaDB 10.3
Histograms in MariaDB, MySQL and PostgreSQL
Common Table Expressions in MariaDB 10.2
Эволюция репликации в MySQL и MariaDB
Common Table Expressions in MariaDB 10.2 (Percona Live Amsterdam 2016)

Recently uploaded (20)

PPTX
Airline CRS | Airline CRS Systems | CRS System
PPTX
Human-Computer Interaction for Lecture 2
PPTX
DevOpsDays Halifax 2025 - Building 10x Organizations Using Modern Productivit...
PPTX
MLforCyber_MLDataSetsandFeatures_Presentation.pptx
PPTX
ROI from Efficient Content & Campaign Management in the Digital Media Industry
PPTX
4Seller: The All-in-One Multi-Channel E-Commerce Management Platform for Glob...
PDF
CCleaner 6.39.11548 Crack 2025 License Key
PPTX
Plex Media Server 1.28.2.6151 With Crac5 2022 Free .
DOC
UTEP毕业证学历认证,宾夕法尼亚克拉里恩大学毕业证未毕业
PDF
infoteam HELLAS company profile 2025 presentation
PPTX
hospital managemt ,san.dckldnklcdnkdnkdnjadnjdjn
PDF
Microsoft Office 365 Crack Download Free
PDF
BoxLang Dynamic AWS Lambda - Japan Edition
PPTX
Viber For Windows 25.7.1 Crack + Serial Keygen
PPTX
string python Python Strings: Literals, Slicing, Methods, Formatting, and Pra...
PPTX
Download Adobe Photoshop Crack 2025 Free
PDF
Internet Download Manager IDM Crack powerful download accelerator New Version...
PDF
novaPDF Pro 11.9.482 Crack + License Key [Latest 2025]
PPTX
R-Studio Crack Free Download 2025 Latest
PDF
Website Design & Development_ Professional Web Design Services.pdf
Airline CRS | Airline CRS Systems | CRS System
Human-Computer Interaction for Lecture 2
DevOpsDays Halifax 2025 - Building 10x Organizations Using Modern Productivit...
MLforCyber_MLDataSetsandFeatures_Presentation.pptx
ROI from Efficient Content & Campaign Management in the Digital Media Industry
4Seller: The All-in-One Multi-Channel E-Commerce Management Platform for Glob...
CCleaner 6.39.11548 Crack 2025 License Key
Plex Media Server 1.28.2.6151 With Crac5 2022 Free .
UTEP毕业证学历认证,宾夕法尼亚克拉里恩大学毕业证未毕业
infoteam HELLAS company profile 2025 presentation
hospital managemt ,san.dckldnklcdnkdnkdnjadnjdjn
Microsoft Office 365 Crack Download Free
BoxLang Dynamic AWS Lambda - Japan Edition
Viber For Windows 25.7.1 Crack + Serial Keygen
string python Python Strings: Literals, Slicing, Methods, Formatting, and Pra...
Download Adobe Photoshop Crack 2025 Free
Internet Download Manager IDM Crack powerful download accelerator New Version...
novaPDF Pro 11.9.482 Crack + License Key [Latest 2025]
R-Studio Crack Free Download 2025 Latest
Website Design & Development_ Professional Web Design Services.pdf

Say Hello to MyRocks

  • 1. Say Hello to MyRocks Sergei Petrunia | Senior Software Engineer, MariaDB [email protected] M|17, April 11-12th , 2017
  • 2. 2
  • 3. 3 What can be done about this?
  • 4. 4 Data vs Disk  Put some data into the database  How much is written to disk? INSERT INTO tbl1 VALUES ('foo')  amplification = size of data size of data on disk
  • 5. 5 Amplification  Write amplification  Space amplification  Read amplification amplification = size of data size of data on disk foo
  • 6. 6 Amplification in InnoDB ● B*-tree ● Read amplification – Assume random data lookup – Locate the page, read it – Root page is cached ● ~1 disk read for the leaf page – Read amplification is ok
  • 7. 7 Write amplification in InnoDB ● Locate the page to update ● Read; modify; write – Write more if we caused a page split ● One page write per update! – page_size / sizeof(int) ● Write amplification is an issue.
  • 8. 8 Space amplification in InnoDB ● Page fill factor <100% – to allow for updates ● Compression is done per-page – Compressing bigger portions would be better – Page alignment ● Compressed to 3K ? Still on 4k page. ● => Space amplification is an issue
  • 9. 9 InnoDB amplification summary ● Read amplification is ok ● Write and space amplification is an issue – Saturated IO – Faster SSD wear out – Need more space on SSD ● => Low storage efficiency
  • 11. 11 Log-structured merge tree ● Writes go to – Log – MemTable ● MemTable is flushed to SortedStringTable ● Writing 2x – But only useful data MemTableWrite Log SST MemTable
  • 12. 12 Log-structured merge tree ● Writing produces more SSTs ● SSTs are immutable ● SSTs may have multiple versions of data MemTableWrite Log SST MemTable SST ...
  • 13. 13 Reads in LSM tree ● Need to merge the data on read – Read amplification suffers ● Should not have too many SSTs. MemTable Read Log SST MemTable SST ...SST
  • 14. 14 Compaction ● Merge multiple SSTs into one ● Removes old data versions ● Reduces the number of files ● Write amplification++ :-( SST SST . . .SST SST
  • 15. 15 Compaction considerations ● Find the sweetspot – Reduce # SSTs – Don’t compact too often ● Be efficient – Compact files of similar size – Remove duplicate versions asap ● Many strategies – Leveled – Size-tiered SST SST . . .SST SST – ...
  • 16. 16 Leveled Compaction a-c a-f . . . . . . . . . . . . b-gL0 L1 a-e f-i j-n o-z L2 a-b c-g f-k l-q L7 a-c d-f g-l q-z MemTable q-z 5 mb 50 mb 500 mb
  • 17. 17 Leveled Compaction MemTable a-c a-f . . . . . . . . . . . . b-gL0 L1 a-e f-i j-n o-z L2 a-b c-g f-k l-q L5 a-c d-f g-l q-z q-z 5 mb 50 mb 500 mb read(‘f’)
  • 18. 18 Leveled Compaction MemTable a-c a-f . . . . . . . . . . . . b-gL0 L1 a-e f-i j-n o-z L2 a-b c-g f-k l-q L5 a-c d-f g-l q-z q-z 5 mb 50 mb 500 mb
  • 19. 19 Leveled Compaction MemTable a-c a-f . . . . . . . . . . . . bL0 L1 a-e f-i j-n o-z L2 a-b c-g f-k l-q L5 a-c d-f g-l q-z q-z 5 mb 50 mb 500 mb
  • 20. 20 LSM Tree summary ● LSM architecture – Data is stored in log, then SST files – Writes to SST files are sequential, efficient ● Better compression – Have to read from multiple SST files – Compaction process merges SST files ● Efficiency – Write amplification is reduced – Space amplification is reduced – Read amplification increases
  • 22. 22 RocksDB ● “An embeddable key-value store for fast storage environments” ● Uses LSM architecture – Leveled compaction – Server-grade ● Initially a fork of LevelDB ● Developed at Facebook – First release in 2012 – Used at Facebook and many other companies
  • 23. 23 RocksDB properties ● Embedded library ● Stores (key, value) pairs – No data types – No secondary indexes – No SQL-like tables ● Column Families = tablespaces ● No replication support – There is a 3rd-party addon ● Efficient, but hard to work with
  • 25. 25 MyRocks ● A MySQL storage engine ● Uses RocksDB for storage ● Implements a MySQL storage engine on top – Secondary indexes – Data types – SQL transactions – … ● Developed* and used by Facebook – *-- with some MariaDB involvement
  • 26. 26 Size amplification benchmark ● Benchmark data and chart from Facebook ● Linkbench run ● 24 hours
  • 27. 27 Write amplification benchmark ● Benchmark data and chart from Facebook ● Linkbench
  • 28. 28 QPS ● Benchmark data and chart from Facebook ● Linkbench
  • 29. 29 QPS on in-memory workload ● Benchmark data and chart from Facebook ● Sysbench read-write, in-memory ● MyRocks doesn’t always beat InnoDB
  • 30. 30 QPS ● Benchmark data and chart from Facebook ● Linkbench
  • 31. 31 A real efficiency test For a certain workload we could reduce the number of MySQL servers by 50% – Yoshinori Matsunobu
  • 32. 32 Another write amplification test ● InnoDB vs ● MyRocks serving 2x data InnoDB 2x RocksDB 0 4 8 12 Flash GC Binlog / Relay log Storage engine
  • 34. 34 CPU usage is higher with MyRocks Time InnoDB 2x RocksDB 100% 0% 80% 50-60%
  • 35. 35 MyRocks limitations ● Transactional storage engine – REPEATABLE READ, READ COMMITTED – No SERIALIZABLE ● Must use Row-based-Replication ● No cross-engine transactions ● Transaction must fit in memory ● Online DDL more limited than InnoDB
  • 36. 36 MyRocks availability ● Part of github.com/facebook/mysql-5.6 ● No binaries ● No packages ● Facebook’s branch of MySQL – Special extensions – Special ways to compile, run tests, etc ● Not easy to use
  • 38. 38 MyRocks in MariaDB ● New technology ● Built and used at Facebook’s scale ● Adoption ● Packaging ● Community ● MariaDB features ● ...
  • 39. 39 Getting MyRocks into MariaDB ● Port MyRocks into MariaDB 10.2 – Decouple it from facebook/mysql-5.6 features – Make it work with MariaDB’s features ● Set up a merge process – Need to follow Facebook’s progress ● Setup the process to build packages ● Documentation ● Expertise ● ...
  • 40. 40 Getting MyRocks into MariaDB ● Port MyRocks into MariaDB 10.2 – Decouple it from facebook/mysql-5.6 features – Make it work with MariaDB’s features ● Set up a merge process – Need to follow Facebook’s progress ● Setup the process to build packages ● Documentation ● Expertise ● ... ✘ ✔ ✘ ✘✔ ✔ ✔ ✔
  • 41. 41 Current status ● “MariaDB 10.2.5 RC includes an ALPHA version of MyRocks storage engine” ● It’s a loadable plugin (ha_rocksdb.so) ● Packages – Bintar, deb, rpm, win64 zip + MSI – Recent versions of OS due to compilers for RocksDB’s requirements ● Not all features work yet – Optimizer and SQL features work – Replication/binlog features don’t work yet.
  • 42. 42 “Is it stable”? ● The components are stable – (MyRocks + RocksDB) are run in production @ Facebook – RocksDB is also used elsewhere – MyRocks not much. yet. ● Connections with MariaDB – Some are stable – Some are [nearly] missing MyRocks MariaDB RocksDB
  • 43. 43 Plans ● Finish the missing pieces – Storage Engine + binlog ● Improve support for multiple SEs – MDEV-12179 ● Increase maturity – Pass the tests – More test coverage – Benchmarks ● Documentation MyRocks MariaDB RocksDB
  • 44. 44 References ● https://www.slideshare.net/profyclub_ru/making-the-case-for-writeoptimized-da tabase-algorithms-mark-callaghan-facebook ● https://code.facebook.com/posts/190251048047090/myrocks-a-space-and-write -optimized-mysql-database ● https://www.facebook.com/atscaleevents/videos/1775545312718565/ ● ... Further information ● 10.00 Real World: Deploying MyRocks in Production at Facebook, Yoshinori Matsunobu ● http://myrocks.io ● https://mariadb.com/kb/en/mariadb/myrocks-in-mariadb/