您的位置:首页 > 数据库 > MySQL

MySQL 8.0即将GA

2018-05-09 14:30 225 查看

作者:洪斌
文章来源:爱可生数据库

MySQL 5.x版本在时间跨度之长,仅次于Linux kernel 2.x的发布了,中间经历了两次收购,并没有影响让他它的发展势头。这个有着20多年历史的数据库产品,正重焕新生,变得越来越强大,越来越现代,依然稳坐最流行的开源数据库的宝座。MySQL 8.0 GA的脚步已经离我们越来越近。


MySQL 版本号一下子从5.x系列跳到了8.0,有人可能会疑惑 6.0和7.0 去哪了。现实情况是6.x没正式发布,它一部分特性合并进了5.6 5.7,而MySQL 7.x是MySQL cluster一直沿用的版本号,所以这次主版本号直接跳到了8.0。

MySQL 8.0重要改进

------------------------------1. MySQL Document Store

2. Default to utf8mb43. JSON enhancements4. CTEs5. Window Functions6. Descending Indexes7. Better Optimizer Cost Model8. MySQL Server Components9. Improvement in GIS10. InnoDB NO WAIT & SKIP LOCKED11. Temporary Tables Improvements12. Persistent global variables13. No more MyISAM System Tables14. Reclaim UNDO space from large transactions15. UTF8 performance16. Removing Query Cache17. Atomic DDLs18. Faster & More Complete Performance Schema (Histograms, Indexes, …) and Information Schema19. ROLES20. REDO & UNDO logs encrypted if tablespace is encrypted

-------------------------------


C++11

8.0更多的使用C++11标准库数据结构和函数改进代码质量和效率。

* std::atomic — fixed lots of bugs for us over the old use of volatile, replaced home-grown compiler-specific atomic* thread_local — gave us nice speedups over our old code* Initializers in structs/classes — simplified construction/destruction* std::snprintf — replaced the old my_snprintf* std::unordered_map/std::unordered_set — much faster than the old HASH* std::call_once — replaced our home-grown my_thread_once* std::unique_ptr — makes cleanup significantly safer (RAII pattern)

* constexpr functions — enabled some speedups in InnoDB


编译选项优化

利用现代编译器的特性提高代码质量,增加warning-free编译选项,使用AddressSanitizer和UndefinedBehaviorSanitizer减少代码bug风险。

* C: -Wall -Wextra -Wformat-security -Wvla -Wundef -Wmissing-format-attribute -Wwrite-strings -Werror

* CC+: -Wall -Wextra -Wformat-security -Wvla -Wundef -Wmissing-format-attribute -Woverloaded-virtual -Wno-missing-field-initializers -Wimplicit-fallthrough=2 -Wlogical-op -Werror


Google C++编码风格

8.0中抛弃了MySQL Server和InnoDB原有的代码风格,采用Google C++编码风格,更便于阅读和贡献代码。

源码文档管理

从8.0开始使用Doxygen管理源码文档,这样能保证代码更新和文档保持同步。 MySQL Source Code Documentation(https://dev.mysql.com/doc/dev/mysql-server/latest
MySQL 代码历史悠久,官方愿意花这么大力气的重构代码,为MySQL注入新的活力,也预示着MySQL未来会越来越好。
不知道小伙伴们是否留意之前GA的版本号和发布间隔,MySQL 5.6.9(GA),MySQL 5.7.10(GA),MySQL 8.0.11,GA即将到来。
引用https://mysqlserverteam.com/mysql-8-0-source-code-improvements/http://lefred.be/content/top-10-mysql-8-0-features-for-developers/http://lefred.be/content/top-10-mysql-8-0-features-for-dbas-ops/

阅读更多
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: