V4.3.4
Version information
Release date: April 18, 2025
Version: V4.3.4
RPM version: obproxy-4.3.4.0-262025041714
Overview
OceanBase Database Proxy (ODP) V4.3.4 is the latest version of the ODP V4.3.x series and is recommended for on-cloud and on-premises business in a proof of concept (POC) test or production environment. When serving as an SQL proxy, ODP of the new version supports routing for Asian character sets and their collations, as well as function partitioning key-based routing to enhance its core routing capabilities. It optimizes the routing strategies for replicated tables and requests sized more than 4 KB to reduce remote routing and improve the routing performance. It also provides a global parameter for determining the communication protocol used between ODP and OceanBase Database, which simplifies protocol configuration. When serving as a remote procedure call (RPC) proxy, ODP of the new version supports accurate routing for single-partition tables and obtaining partition information in an atomic manner, enhancing the routing capabilities. It also improves the congestion handling process and asynchronously obtains ls_id information to further improve system stability.
Key features
SQL proxy
Routing capability improvement
Support for more character sets
ODP V4.3.4 is fully compatible with Asian character sets, including ujis, euckr, cp932, and eucjpms, as well as the corresponding collations.
Routing optimization for replicated tables involved in joins
For a request initiated to a replicated table, ODP randomly routes the request to any OBServer node. If the replicated table is the first table in a join, ODP may route the request to a non-leader node of a non-replicated table based on the random routing strategy. This results in remote routing, which compromises the overall performance of the request. ODP V4.3.4 optimizes routing for replicated tables involved in joins. Based on the new routing strategy, if ODP finds that the first table in a join is a replicated table, ODP will not perform random routing but use the resulting table of the join for routing. This avoids performance issues caused by remote routing.
Support for function partitioning key-based routing
ODP partition calculation does not support scenarios where a function expression is used in the partitioning key during table creation, which can result in partition calculation failure and inaccurate routing. ODP V4.3.4 identifies the table creation information in the metadata of partitioned tables, and parses and converts partitioning keys that contain a function expression, to ensure the accuracy of partition calculation.
Support for routing of requests sized more than 4 KB
In ODP of versions earlier than V4.3.4, the default value of the
request_buffer_lengthparameter is4KB. For a request that is sized more than 4 KB and whose routing information has not been parsed, ODP will choose random routing due to a parsing failure. This may lead to remote routing, significantly compromising the performance. This issue frequently occurs in actual business scenarios. In ODP V4.3.4, the default value of therequest_buffer_lengthparameter is changed from4KBto8KBto ensure that requests sized more than 4 KB can also be accurately routed.
Simplified protocol configuration
ODP provides two parameters enable_ob_protocol_v2 and enable_compression_protocol for controlling the protocol used between ODP and OceanBase Database. After ODP supports performance optimization for the standalone mode in V4.3.1, the protocol to be used between ODP and OceanBase Database is automatically selected and no longer controlled by parameters. As a result, the protocol in use can be different from that specified by parameters, making it difficult for O&M engineers to identify the protocol during troubleshooting, thereby complicating the troubleshooting process. ODP V4.3.4 provides a new global parameter server_protocol for determining the protocol used between ODP and OceanBase Database, simplifying protocol configuration.
RPC proxy
Routing capability improvement
Accurate routing supported for single-partition tables
ODP cannot accurately determine whether a table is partitioned or non-partitioned. When RPC proxy routing is used for a single-partition table, an error may be returned during routing. ODP V4.3.4 optimizes the routing logic. It performs routing retries based on the error information provided by the OBServer node, so as to implement accurate routing for single-partition tables.
Partition information obtained in an atomic manner
ODP obtains table information through multiple internal requests without atomicity. This cannot ensure consistency between the obtained table information. If any inconsistency occurs, partition calculation will fail. ODP V4.3.4 optimizes the table information acquisition logic. It verifies the obtained table information in real time and performs a retry when necessary to ensure routing accuracy.
Improved congestion handling process
When serving as an RPC proxy, ODP can asynchronously process RPC requests. During processing, it maintains network isolation between the network of the request processing state machine and the OBServer nodes, ensuring that the status changes of the OBServer nodes are independent of the congestion handling process. RPC requests are forwarded and processed strictly based on the calculated partition information and corresponding routing information, which results in incomplete high availability (HA) capabilities. To address this issue, ODP references its SQL proxy strategies for the congestion handling process, to ensure that the requests are never forwarded to abnormal OBServer nodes under any circumstances.
ls_id information obtained asynchronously
ODP can obtain ls_id information since V4.3.1, which depends on retrieving tablet_id, making SQL processing complex. In addition, ODP needs to query internal tables of the cluster, increasing the load on the sys tenant of the cluster. To address this issue, ODP V4.3.4 splits the ls_id acquisition process into asynchronous steps. For ObTableLSOpRequest requests, ODP V4.3.4 adds the step of asynchronously obtaining tablet_id.
Compatibility changes
| Parameter | Change type | Description |
|---|---|---|
| server_protocol | New | The type of the protocol used between ODP and OceanBase Database. |
| rpc_client_net_read_timeout | New | The timeout threshold for an RPC client when it reads data from the network. |
| rpc_client_net_write_timeout | New | The timeout threshold for an RPC client when it writes data to the network. |
| request_buffer_length | Modified | The default value is changed from 4KB to 8KB. In addition, when the size of a client request exceeds the specified threshold, ODP directly forwards the request over a tunnel. |
| tunnel_request_size_threshold | Deprecated | This parameter is deprecated and replaced by request_buffer_length since ODP V4.3.4. |
Supported OceanBase Database versions
ODP supports OceanBase Database V4.x and OceanBase Database V3.x and earlier. The recommended ODP version varies based on the OceanBase Database version.
For OceanBase Database V3.x and earlier, ODP V3.2.11 is recommended.
For OceanBase Database V4.x, ODP V4.3.1, which is an LTS version, is recommended.
ODP V4.3.4 provides multiple new features. We recommend that you use ODP V4.3.4 if your environment relies on the new features, or the LTS version V4.3.1 if otherwise.
Bug fixes
Fixed the issue where ODP connects to an incorrect read-only address on AWS, or the client connections to OceanBase Database through ODP on AWS are interrupted.
Fixed the issue where ODP fails to parse an SQL statement following a "--" comment when the comment contains a line break.
Fixed the issue where the error
write clob erroris returned when DBMS_LOB.READ times out.Fixed the issue where ODP fails to be started by using an IPv6 address in the Arm architecture.
Fixed the issue where, when a partitioned table has no partitioning key, SQL requests are not randomly scattered as expected if a default partition exists.
Fixed the issue where, when ODP is used to connect to the cluster during direct load, the error code
4016is returned if an incorrect cluster name is specified.Fixed the issue where prepared statement (PS) routing is inaccurate when a user variable contains keywords such as
value.Fixed the issue where disconnection occurs when a request sized more than 4 KB is parsed again in a transaction.
Fixed the issue where no result is returned under the PreparedStatement protocol when OceanBase Protocol 2.0 and the compression protocol are disabled.
Fixed the issue where you cannot run the
kill query sessionidcommand in the sys tenant to terminate the execution of an SQL statement in a business tenant.Fixed the issue where inaccurate routing occurs due to a partition information parsing error when the string in the WHERE condition contains the
joinkeyword.Fixed the issue where the error code
4016is returned during data insertion into a single-partition table when ODP serves as an RPC proxy.Fixed the issue where ODP returns the error code
-5627in manual partition splitting scenarios.Fixed the issue where the error
routed to the wrong serveris repeatedly returned in the initial phase of a batch INSERT stress test.Fixed the issue where, after the OBServer node is restarted, the client is disconnected and returns an error.
Fixed the issue where the error
unknown errcode: -10652is returned when the batch checkAndInsUp operation is performed on the client by using YCSB.Fixed the issue where the error
OB_ERR_KV_GLOBAL_INDEX_ROUTEis returned when a global index is used for queries.Fixed the issue where, if ODP returns the error code
-5150for global indexes after migration, the client keeps reconnecting and returning errors.