- 快召唤伙伴们来围观吧
- 微博 QQ QQ空间 贴吧
- 文档嵌入链接
- 复制
- 微信扫一扫分享
- 已成功复制到剪贴板
TiDB Distributed, horizontally scalable, MySQL compatible
TIDB是由PingCap构建的开放源码分布式可扩展混合事务和分析处理(HTAP)数据库。它还使用mysql协议,并使用rocksdb作为底层存储引擎!
本文介绍和概述了tidb,它是为那些在mysql中有很强背景的用户量身定做的。我将以mysql为例来解释tidb的各种实现细节,并将术语翻译为mysql/innodb术语。
展开查看详情
1 .Introducing TiDB For those coming from MySQL...
2 .Agenda ● History and Community ● Technical Walkthrough ● Use Case with Mobike ● MySQL Compatibility
3 .A little about me ● Senior Product / Community Manager ● ~15 years MySQL Experience ○ MySQL AB, Sun, Percona, Oracle ● Previously Product Manager for MySQL Server
4 .A little about PingCAP ● Founded in April 2015 by 3 infrastructure engineers ● Offices in China and North America ● Remote Friendly! ○ I work from here ➡
5 .Recent News PingCAP.com
6 .Our Product is the TiDB Platform ● TiDB Platform (Ti = Titanium) ○ TiDB (SQL Layer) ○ TiKV (Storage) ○ TiSpark (Apache Spark plugin to TiKV) ● Open source from Day 1 ○ GA 1.0: October 2017 ○ GA 2.0: April 2018 PingCAP.com
7 .TiDB is a NewSQL Database RDBMS NoSQL NewSQL 1970s 2010 2015 Present MySQL Redis Google PostgreSQL HBase Spanner Oracle Cassandra Google F1 DB2... MongoDB TiDB PingCAP.com
8 .Common Use Cases 1. MySQL Scalability 2. Hybrid OLTP/OLAP Architecture 3. Unifying Data Storage/Management
9 .Architecture (Simplified) PD PD PD TSO / Data Location PD Cluster Metadata TiDB TiKV TiKV MySQL Protocol DistSQL Application via API TiDB TiKV TiKV KV API TiDB TiKV TiKV ... ... PingCAP.com
10 .Community Stars ● TiDB: 15,000+ ● TiKV: 3700+ Contributors ● TiDB: 200+ ● TiKV: 100+ PingCAP.com
11 .Sneak Peek! Early Sign-up: https://www.pingcap.com/tidb-academy/ PingCAP.com
12 .TiDB Platform Architecture
13 .Platform Architecture PD Data Location PD PD TSO / Data Location PD Cluster Spark Driver Metadata Worker TiDB TiKV TiKV MySQL Protocol DistSQL DistSQL Application via API Worker Spark SQL API TiDB TiKV TiKV KV API Worker TiDB TiKV TiKV ... ... ... Spark Cluster PingCAP.com
14 .TiKV: The Storage Foundation Client PD Cluster gRPC gRPC gRPC Coprocessor Coprocessor Coprocessor Txn KV API Txn KV API Txn KV API API API API Transaction Transaction Transaction Raft Raft Raft Raft Group RocksDB RocksDB RocksDB TiKV Instance TiKV Instance TiKV Instance PingCAP.com
15 .TiDB: The SQL Layer Any ORM which ODBC/JDBC MySQL Client supports MySQL MySQL Network Protocol SQL Parser TiDB Cost-based Optimizer Distributed Executor (Coprocessor) TiKV Node1 Node2 Node3 Node4 PingCAP.com
16 .Who’s Using TiDB?
17 .Who’s using TiDB? 300+ Companies PingCAP.com
18 .Common Use Cases 1. MySQL Scalability 2. Hybrid OLTP/OLAP Architecture 3. Unifying Data Storage/Management
19 .Mobike + TiDB ● 200 million users ● 200 cities ● 9 million smart bikes ● ~30 TB / day PingCAP.com
20 .MySQL Compatibility
21 .Summary ● Compatibility with MySQL 5.7 ○ Joins, subqueries, DML, DDL etc. ● On the roadmap: ○ Views, CTEs, Window Functions, GIS ● Missing: ○ Stored Procedures, Triggers, Events, Fulltext pingcap.com /docs/sql/mysql-compatibility/ PingCAP.com
22 .Nuanced ● Some features work differently ○ Auto Increment ○ Optimistic Locking ● TiDB works better with smaller transactions ○ Recommended to batch updates, deletes, inserts to 5000 rows pingcap.com /docs/sql/mysql-compatibility/ PingCAP.com
23 .Thank You ! Sign-up: www.pingcap.com/tidb-academy/ PingCAP.com