数据系统

多主云数据库的全局事务日志

  • 卫孝贤 ,
  • 刘文欣 ,
  • 蔡鹏
展开
  • 华东师范大学 数据科学与工程学院, 上海 200062

收稿日期: 2020-08-02

  网络出版日期: 2020-09-24

基金资助

国家自然科学基金(61972149)

Global transaction log of a multi-master cloud database

  • WEI Xiaoxian ,
  • LIU Wenxin ,
  • CAI Peng
Expand
  • School of Data Science and Engineering, East China Normal University, Shanghai 200062, China

Received date: 2020-08-02

  Online published: 2020-09-24

摘要

随着云计算的盛行, 用户对云数据库的需求越发复杂, 而当下基于共享存储的一写多读的云数据库系统并不能支持写性能的动态扩展. 多个主节点同时提供写服务, 会引起跨节点的读写冲突, 进而导致多主节点缓存不一致. 对于这个问题, 基于全局有序的事务日志的乐观冲突检测可以检测出跨节点事务冲突, 并回滚冲突的事务, 维持整个系统的隔离级别与一致性. 另外, 通过广播和回放全局有序的事务日志, 可以将主节点的修改同步到其余节点, 保证每个节点的独立服务能力. 这一基于事务日志的多主缓存一致性解决方案已实现在开源数据库MySQL上,并通过实验验证了该解决方案对系统性能的影响.

本文引用格式

卫孝贤 , 刘文欣 , 蔡鹏 . 多主云数据库的全局事务日志[J]. 华东师范大学学报(自然科学版), 2020 , 2020(5) : 10 -20 . DOI: 10.3969/j.issn.1000-5641.202091002

Abstract

With the prevalence of cloud computing, users’ requirements for cloud databases are becoming increasingly complex. The current write-once-read-many cloud database system, based on shared storage, cannot support the dynamic expansion of write performance. Multiple master nodes provide write services simultaneously, which can cause cross-node read and write conflicts, eventually leading to inconsistencies in the cache of multiple master nodes. For this problem, optimistic conflict detection based on globally ordered transaction logs can detect cross-node transaction conflicts, roll back conflicting transactions, and maintain the isolation level and consistency of the overall system. By broadcasting and replaying the global orderly transaction log, moreover, the modification of the master node can be synchronized to the remaining nodes to ensure the independent service capability of each individual node. This multi-master cache consistency solution based on global transaction logs is implemented on the open source database MySQL, and the impact on system performance is verified through experiments.

参考文献

[1] VERBITSKI A, GUPTA A, SAHA D, et al. Amazon aurora: Design considerations for high throughput cloud-native relational databases [C]//Proceedings of the 2017 ACM International Conference on Management of Data. ACM, 2017: 1041-1052.
[2] VERBITSKI A, GUPTA A, SAHA D, et al. Amazon aurora: On avoiding distributed consensus for i/os, commits, and membership changes [C]//Proceedings of the 2018 International Conference on Management of Data. ACM, 2018: 789-796.
[3] CAO W, LIU Z J, WANG P, et al. PolarFS: An ultra-low latency and failure resilient distributed file system for shared storage cloud database [J]. Proceedings of the VLDB Endowment, 2018, 11(12): 1849-1862. DOI: 10.14778/3229863.3229872.
[4] HUANG G, CHENG X T, WANG J Y, et al. X-Engine: An optimized storage engine for large-scale E-commerce transaction processing [C]//Proceedings of the 2019 International Conference on Management of Data. ACM, 2019: 651-665.
[5] ANTONOPOULOS P, BUDOVSKI A, DIACONU C, et al. Socrates: The new SQL server in the cloud [C]//Proceedings of the 2019 International Conference on Management of Data. ACM, 2019: 1743-1756.
[6] DEPOUTOVITCH A, CHEN C, CHEN J, et al. Taurus database: How to be fast, available, and frugal in the cloud [C]//Proceedings of the 2020 ACM SIGMOD International Conference on Management of Data. ACM, 2020: 1463-1478.
[7] ORACLE. Oracle Real Application Clusters (RAC) [EB/OL].[2020-07-01]. https://www.oracle.com/database/technologies/rac.html.
[8] ZIKOPOULOS P, EATON C. What is DB2 pureScale? [EB/OL].(2010-01-22)[2020-07-01]. https://www.ibm.com/developerworks/data/library/dmmag/DBMag_2010_Issue1/DBMag_Issue109_pureScale/.
[9] 姜承尧. MySQL技术内幕: InnoDB存储引擎 [M]. 北京: 机械工业出版社, 2011.
[10] 阿里云RDS-数据库内核组. MySQL · 引擎特性 · InnoDB redo log漫游 [EB/OL]. (2015-05-01)[2020-07-01]. http://mysql.taobao.org/monthly/2015/05/01/.
[11] LAMPORT L. Paxos made simple [J]. ACM Sigact News, 2001, 32(4): 51-58.
[12] HERCULE K K, EUGENE M M, PAULIN B B, et al. Study of the master-slave replication in a distributed database [J]. International Journal of Computer Science Issues (IJCSI), 2011, 8(5): 319-326.
[13] BERNSTEIN P A, HADZILACOS V, GOODMAN N. Concurrency Control and Recovery in Database Systems [M]. [S.l.]: Addison-Wesley, 1987.
[14] ZHENG J J, LIN Q, XU J T, et al. PaxosStore: High-availability storage made practical in WeChat [J]. Proceedings of the VLDB Endowment, 2017, 10(12): 1730-1741. DOI: 10.14778/3137765.3137778.
[15] KOSSMANN D, KRASKA T, LOESING S. An evaluation of alternative architectures for transaction processing in the cloud [C]//Proceedings of the 2010 ACM SIGMOD International Conference on Management of data. ACM, 2010: 579-590.
[16] LARSON P Å, BLANAS S, DIACONU C, et al. High-performance concurrency control mechanisms for main-memory databases [J]. Proceedings of the VLDB Endowment, 2011, 5(4): 298-309. DOI: 10.14778/2095686.2095689.
[17] HARDING R, VAN AKEN D, PAVLO A, et al. An evaluation of distributed concurrency control [J]. Proceedings of the VLDB Endowment, 2017, 10(5): 553-564. DOI: 10.14778/3055540.3055548.
文章导航

/