This topic describes the new features and changes of OceanBase Database Community Edition V3.1.3 based on the previous version.
Overview
OceanBase Database Community Edition V3.1.3 provides more features to support the ecosystem and improve user experience.
Multi-model applications: JSON data types and the OBKV HBase client are provided to support semi-structured data and NoSQL applications.
Enhanced ecosystem: Native Python, Go, or ODBC driver for MySQL can be used to connect to an OceanBase database. ob-operator is released to support the orchestration of containers on Kubernetes. Compilation on ARM platforms is supported.
Better product features: Smaller resource specifications (2C8GB) are supported. The reliability of data synchronization by using Change Data Capture (CDC) is improved.
New features
JSON data types
JSON data types are supported in basic operations such as DDL operations, index creation, SQL query, and data type conversion. All JSON functions in MySQL 5.7 and some JSON functions in MySQL 8.0 are supported.
Supports four basic types (strings, numbers, Boolean values, and NULL values) and two structured types (objects and arrays).
Allows you to create JSON columns when creating tables or adding columns.
Allows you to create indexes on columns generated based on JSON columns.
Allows you to reference JSON objects by using the
->or->>operator.Supports JSON text in SQL statements such as SELECT, INSERT, UPDATE, and DELETE.
Supports all JSON functions of MySQL 5.7 and some JSON functions of MySQL 8.0 such as JSON_OVERLAPS() and JSON_VALUE().
Open source OBKV HBase client
Applications can connect to the OBKV HBase client and use APIs that are compatible with the syntax of HBase 0.94 to communicate with OceanBase Database by calling the Table API. The wide-column model is provided. The filter logic is optimized. KEY, RANGE, and prefixed index partitioning are supported.
Native MySQL drivers
You can connect to OceanBase Database by using more native MySQL drivers:
PyMySQL is supported in a Python 3.x environment and MySQL-python is supported in a Python 2.x environment.
Go MySQL Driver is supported.
Unix ODBC driver is supported.
ob-operator
ob-operator is provided to run OceanBase Database in a container in a Kubernetes cluster that is deployed on a public or private cloud. You can deploy ob-operator using YAML or Kustomize and use the following services:
Deploy an OceanBase cluster on the Kubernetes platform.
Create, delete, and scale clusters, and manage a cluster over its entire lifecycle.
Create and delete zones.
Create, delete, restart, and fail over OBServers.
Run the kubectl commands to view the status of clusters, zones, and OBServers.
Call HTTP APIs to manage Kubernetes resources.
ARM platforms
The compatibility of OceanBase Database and ODP with ARM platforms is verified. An ARM-based version is provided for community users to develop, compile, test, and deploy applications on ARM platforms.
For more information about compatible platforms and operating systems, see OS compatibility list.
Smaller specifications
OceanBase Database image for Docker that supports 2 CPU cores and 8 GB of memory (2C8GB) is released. This small-specification image allows community developers to learn and use OceanBase Database at lower costs.
Data synchronization reliability
CDC pulls data from OceanBase Database and provides the data in memory for downstream consumers to use. This requires high specifications of server resources, and the data synchronization may fail in critical business scenarios, such as massive data writes to the database. Therefore, we have enhanced the data synchronization of the CDC link:
Persistence mode
Transaction data is stored in the local storage and then synchronized to downstream consumers by using the CDC link. After the consumption process is completed, the local transaction data is cleared to reduce memory usage during data synchronization.
Large transactions
The memory usage during the synchronization of large transactions is optimized.
Enhanced product operation easiness
Storage and memory parameters can be set to decimals. Example:
alter system set datafile_size ='11.5G';.OceanBase Deployer (OBD) provides a URL for help documentation in the error message.
ob_admin supports user data filtering during clog parsing.
The ENGINE option is added to the information_schema.TABLES view.
Open source documentation is provided. You can submit issues and pull requests about the documents on GitHub. The documentation includes many topics, such as architecture design principles, performance tuning, fault handling, and routine maintenance guide.
Behavior changes
By default, a local index is created for a partitioned table.
We found that customers often perform performance tuning on the indexes of partitioned tables. Research results indicate that local indexes better fit the business of most customers. Therefore, we changed the default indexes of partitioned tables to local indexes.
The following sample statement shows how to create a global index:
create table ad1(c1 int primary key, c2 int, index(c2) global)partition by key(c1) partitions 2The non-strict mode is used for table creation.
When you create a table in OceanBase Database, the table creation succeeds when the table is created in the majority of replicas. To enable strict mode, set the system variable
ob_create_table_strict_modetoTrue.
Fixed issues
Deleted tables are stored in the recycle bin of OceanBase Database. You can run the FLASHBACK TABLE command to recover the tables and data.
Incorrect result is displayed due to the change of the value range of the TIMESTAMP data type. For example, if you change the column type from TIMESTAMP(0) to TIMESTAMP(6), the results are the same time now.
When you reduce the size of a data file by running the
ALTER SYSTEM SET DATAFILE_SIZEcommand, an error is returned.The incremental backup fails because the __all_virtual_trans_stat table is not empty.