RELEASE NOTE

About this version

In V3.1.1, we have strengthened OceanBase in these fields: kernel compatibility, tools, interfaces, backup and recovery, open-source OS, usability. We will continue to enhance the open-source productization capabilities. Core enhancements and improvements are as follows.

  1. MySQL compatibility: Supported MySQL5.7 driver protocol, Common Table Expression (CTE), several compatible functions. And supported migrating data from MySQL OceanBase Database directly.
  2. High availability: Supported for physical backup and recovery, cluster-level backup, and tenant-level recovery. You can back up production data at high speed and flexibly select recovery methods according to scenarios and needs.
  3. Usability: Released administrator tool ob_admin and error code parsing tool ob_error to provide more convenient and flexible problem analysis and processing capabilities. OBD supported deployment based on system resources and multiple Benchmark testing frameworks.
  4. Interface: Released TABLE API interface, supported direct KV access, high-performance storage access. Released REDO log interface CDC, you can connect your data with third-party data easily to do data conversion, extraction, and framework synchronization.
  5. Tools: Supported Prometheus, production system operation, and maintenance monitoring. Supported Dbeaver, developer client tools, DataX, Canal, Dataworks data development governance framework, MySQL, and OceanBase data migration. Released small-size Docker. Supported almost all major Linux distributions and installation and deployment for 8+ distributions of OS and 12+ versions.

New features

  • Supported physical backup and recovery. OceanBase Database supports physical backup for clusters. Physical backup has sstable and memtable. OceanBase Database supports recovery for tenants. To recover data, you must create a new tenant.
  • Supported MySQL 5.7 driver protocol.
  • Supported Common Table Expressions (CTE). A CTE is a named temporary result set that exists within the scope of a single statement and that can be referred to later within that statement, possibly multiple times. OceanBase Database syntax is compatible with MySQL 8.0. OceanBase Database supports recursive CTE and non-recursive CTE. For information, see PR 314.
  • Supported system function CRC32(). You can calculate the cyclic redundancy check value of a given string. For example, SELECT CRC32("abc");. For information, see PR 152.
  • Supported system function CONVERT_TZ(). This function converts a datetime value dt from the time zone given by from_tz to the time zone given by to_tz and returns the resulting value. For example,SELECT CONVERT_TZ('2021-01-01 12:00:00','+00:00','+08:00');. For information, see PR 276.
  • Supported INET_ATON(), INET_NTOA(), INET6_ATON(), INET6_NTOA(), IS_IPV4(), IS_IPV6(), IS_IPV4_MAPPED(), and IS_IPV6_MAPPED(). For information, see PR 198.
  • Supported the maximum connection setting for tenants/users. Use the system variable MAX_CONNECTIONS to set the maximum connection for tenants. Use the system variable MAX_USER_CONNECTIONS to set the maximum connection for users. When you create a user, use MAX_USER_CONNECTIONS to set the maximum concurrent connection for a specified user. MAX_CONNECTIONS_PER_HOUR specifies the maximum connection per hour for a user.

Tools

  • Released Change Data Capture (CDC). CDC is an open-source interface for OceanBase Database. It gives external access to the transaction logs. As a part of the data link, CDC parses, extracts, and assembles the transaction logs. It gives data for downstream data replication. For example, together with Canal, CDC supports incremental data migration.
  • Released open-source interface TABLE API. OceanBase database supports access using the NoSQL interface. TABLE API interface is an operational interface for table model and KV model data. It defines a common set of interaction protocols between the client and the database server. The row operation interface supports execute() for single-row operations and batch_execute() for multi-row batch operations. TABLE API supports retrieve/get, insert_or_update/put, delete, insert, update, replace, increment, and append operations.
  • Supported data replication tools Canal and DataX. You can replicate data from MySQL to OceanBase Database. You can use DataX to do full data migration to OceanBase Database.
  • OBD supported auto test. We integrated mysql_test, TPCH, and Sysbench test frames to OBD. For more information, see OBD test commands.
  • OBD supported auto OceanBase Database configuration based on your system resource. Use obd cluster autodeploy to auto deploy OceanBase Database with your maximum available resource. Use obd cluster tenant create/drop to create or drop a tenant. For more information, see OBD cluster tenant create.
  • Supports deploying OceanBase Database by using Docker. For more information, see OceanBase Docker Hub.
  • Supported DBeaver client. For more information, see PR 13596.
  • Supported Prometheus to monitor clusters for the community version. For example, you can monitor your resource (CPU, memory, IO, and net), your system pressure (SQL latency, live session, and cache hit ratio), and cluster usage limits (NTP).
  • Supported multiple x86 operation systems. For more information, see Compatibility list.
  • Released error code tool ob_error. By using ob_error, you can locate the help information based on the error code returned by OceanBase Database. For more information, see ob_error.
  • Released admin tool ob_admin. ob_admin supports parsing transaction logs and transforming transaction ID. The output format is ob_admin clog_tool/usec_tools <args>. For more information, seeclog_tool.

Compatibility changes

Parameter name Original default value Modification type New default value Description
minor_freeze_times 5 Modification 100 Avoid triggering frequent merges
freeze_trigger_percentage 70 Modification 30 Reduce the risk of excessive cluster memory consumption. Decreasing this value dumps earlier to release memory, but dumping becomes more frequent.
enable_merge_by_turn TRUE Modification FALSE By default, we recommend that you merge multiple zones at the same time. Merging by turn needs different zones to avoid response time increase during merges.
trace_log_slow_query_watermark 100ms Modification 1s The original default value 100ms is not reasonable. The performance decreases in high pressure.
clog_sync_time_warn_threshold 100ms Modification 1s The original default value 100ms is not reasonable. The performance decreases in high pressure because too many log files are produced.
enable_one_phase_commit TRUE Modification FALSE Deprecated in the new version.
enable_pg FALSE Deletion -- Deprecated in the new version.
_enable_split_partition FALSE Deletion -- Deprecated in the new version.

Bug fixes

  • Fixed the problem of using the aggregation function and the same alias. When you use an aggregation function for a string, and you set the result alias the same as the function name, the aggregation function throws an error. For more information, see Issue 173.
  • Fixed the problem of timediff precision. When your data has more than 2 digits, the calculation result is NULL. For more information, see Issue 298.

发布说明

版本新特性

本次迭代版本(v3.1.1),OceanBase 全面提升内核兼容、工具生态、接口开放、备份恢复、开源 OS 支持和易用性能力,持续增强开源产品化应用能力。您可以获得以下关键特性:

  • 支持 MySQL 5.7 驱动协议,支持 5.7 新增的会话变量。可以推高 OceanBase 的 MySQL 兼容版本,避免企业内部安全审计问题。
  • 新增 MySQL 8.0 的通用表表达式(Common Table Expressions),丰富了 SQL 的能力,满足复杂业务查询需求实现。
  • 新增校验函数(CRC32()),完善 MySQL 数据迁移到 OceanBase 的数据校验环节。
  • 新增物理备份和恢复功能,支持近实时的数据备份和恢复到历史任意时间点功能,提升社区版的容灾能力。
  • 新增 TABLE API 接口,支持 KV 接口读写数据,提升高性能存储访问能力。
  • 新增 REDO 日志接口 CDC 能力,方便用户抽取 OceanBase 增量数据和跟第三方数据同步产品对接,解决了数据实时流出 OceanBase 难题。
  • 支持对接 Prometheus ,提升性能监控和诊断能力。
  • 新增管理员工具 ob_admin 和 ERROR CODE 解释工具 ob_error,提升问题排查分析和故障应急处理能力。
  • OBD 新增命令参数,支持自动配置相关参数;新增租户管理命令;新增常用数据库性能测试框架,方便初次使用 OceanBase 。

新增功能

MySQL兼容:

  • 适配支持 MySQL 5.7 驱动协议,支持 5.7 新增的会话变量。可以推高 OceanBase 的 MySQL 兼容版本,避免企业内部安全审计问题。
  • 支持通用表表达式(Common Table Expressions)。语法兼容 MySQL 8.0,支持非递归 CTE 和递归 CTE。CTE 相当于一个临时表但没有实际存储,仅在查询执行期间被使用,丰富了 SQL 的功能。详细信息,参考 PR 314
  • 支持系统函数 CRC32()。您可以通过计算字符串的 CRC32 校验和来校验数据。例如 SELECT CRC32("abc");。详细信息,参考 PR 152
  • 支持系统函数 CONVERT_TZ()。此函数可以实现时区转换查询。例如 SELECT CONVERT_TZ('2021-01-01 12:00:00','+00:00','+08:00');。详细信息,参考 PR 276
  • 支持网络地址相关函数 INET_ATON()INET_NTOA()INET6_ATON()INET6_NTOA()IS_IPV4()IS_IPV6()IS_IPV4_MAPPED()IS_IPV6_MAPPED()。详细信息,参考 PR 198
  • 支持租户/用户最大连接数设置。系统变量 MAX_CONNECTIONS 设置租户最大连接数。系统变量 MAX_USER_CONNECTIONS 设置用户最大并发连接数。创建用户时,可以通过参数 MAX_USER_CONNECTIONS 指定用户的最大并发连接数。参数 MAX_CONNECTIONS_PER_HOUR 指定用户的每小时最大连接数。

高可用性:

  • 支持物理备份与恢复。物理备份是集群级别的,包括数据全量和增量备份、事务日志近实时备份(秒级别触发);物理恢复是租户级别的,能恢复到历史任意时间点(几秒之前)。详细信息,参考 物理备份与恢复

易用性:

  • OBD 支持根据系统资源情况自动配置 OceanBase 参数。新增 obd cluster autodeploy 命令,支持自动使用最高规格启动 OceanBase 数据库。新增 obd cluster tenant create/drop 命令支持创建/删除租户。详细信息,参考 OBD 创建租户
  • OBD 支持自动化测试。OBD 支持集成运行 mysql_testTPCHSysbench 测试框架。详细参考帮助命令。详细信息,参考 OBD 测试命令
  • 新增错误码解析工具 ob_errorob_error 可以帮助您根据 OceanBase 数据库返回的错误码快速找到帮助信息,输入形式为 ob_error [option] errorcode。详细信息,参考 错误码工具
  • 新增管理员工具 ob_admin。ob_admin 支持解析事务日志和转换事务 ID ,提升疑难问题分析诊断能力。输入形式为ob_admin clog_tool/usec_tools <args>。详细信息,参考 clog_tool

接口开放:

  • 开源 TABLE API 接口。OceanBase 数据库支持使用 NoSQL 接口访问。TABLE API 接口是表模型和 KV 模型数据的操作接口,定义了客户端和数据库服务端之间的一组通用的交互协议。行操作接口支持 execute() 执行单行操作和 batch_execute() 执行多行批量操作。支持 retrieve/getinsert_or_update/putdeleteinsertupdatereplaceincrementappend 操作。
  • 开源 Change data capture(CDC)。CDC 是 OceanBase 数据库对外提供事务日志访问的接口。作为数据链路的一环,CDC 支持解析、抽取和组装事务日志,为下游数据同步提供消费数据。例如,CDC 与 Canal 对接可以实现数据增量迁移。

社区生态

兼容性变化

配置项 原默认值 修改类型 新默认值 描述
minor_freeze_times 5 修改 100 增加内存转储次数,避免内存合并被触发,提升大批量写时性能稳定性
freeze_trigger_percentage 70 修改 50 降低内存转储触发阈值,增加内存转储频率,避免内存写不足报错
enable_merge_by_turn TRUE 修改 FALSE 关闭按 ZONE 逐个合并机制,避免不必要的主备切换带给业务的影响
trace_log_slow_query_watermark 100ms 修改 1s 增加慢查询 SQL 的时间阈值,减少慢查询日志,降低对磁盘的 IO 影响
clog_sync_time_warn_threshold 100ms 修改 1s 增加 clog 同步告警时间阈值,减少同步日志
enable_one_phase_commit TRUE 修改 FALSE 新版本已废弃使用
enable_pg FALSE 删除 -- 已废弃的功能
_enable_split_partition FALSE 删除 -- 已废弃的功能

Bug 修复

  • 修复聚合函数与别名相同使用报错的问题。对某字段使用聚合函数后,对结果设置成相同字段别名后,使用聚合结果排序必须使用别名,不能使用原来的聚合函数排序。详细信息,参考 Issue 173
  • 修复 timediff 精度的问题。当数据的小数点超过 2 位时,计算结果为 NULL。详细信息,参考 Issue 177
  • 修复跨图查询视图报错的问题。详细信息,参考 Issue 298

项目简介

OceanBase is an enterprise distributed relational database with high availability, high performance, horizontal scalability, and compatibility with SQL standards.

🚀 Github 镜像仓库 🚀

源项目地址

https://github.com/oceanbase/oceanbase

发行版本 26

v4.1.0_BP3_HF1

全部发行版

贡献者 116

全部贡献者

开发语言

  • C++ 96.9 %
  • Python 2.0 %
  • Yacc 0.5 %
  • C 0.2 %
  • CMake 0.2 %