OceanBase Database Proxy (ODP), also called OBProxy, is a dedicated proxy service for OceanBase Database. Data of a OceanBase Database user is stored as multiple replicas in OBServers. ODP receives an SQL request from the user, forwards the SQL request to the optimal OBServer, and then returns the execution result to the user.
Terms
This section describes the terms that you need to familiarize yourself with before using ODP.
OceanBase Database
OceanBase Database is a financial-grade distributed relational database developed by Ant Group. OceanBase Database features high availability, scalability, high compatibility, cost efficiency, strong consistency, and high performance. For more information, see the OceanBase Database documentation.
ODP
ODP, also called OBProxy, is a dedicated proxy service for OceanBase Database. ODP provides various core features. For example, ODP selects the best route to prevent distributed transactions and provides high availability to ensure that applications are not affected by single points of failure (SPOFs).
Features
As a key component of OceanBase Database, ODP has the following features:
Connection management
For the physical connections of a client, ODP maintains its connections to multiple OBServers at the backend. ODP also adopts the incremental data synchronization solution based on version numbers to maintain the session status of each OBServer connection. This ensures efficient client access to each OBServer.
Optimal routing
ODP routes the user requests to the optimal OBServer based on the locality of the replica involved in the user request, the read/write split routing policy configured by the user, the optimal link for multi-region deployment of OceanBase Database, and the status and load of each OBServer. This ensures the high-performance operation of OceanBase Database.
High-performance forwarding
ODP is fully compatible with the MySQL protocol and supports the protocol developed by OceanBase. ODP adopts the multi-threading asynchronous framework and supports transparent streaming forwarding to ensure high-performance data forwarding and minimize resource consumption of ODP.
Easy O&M
ODP is stateless and can be scaled out without limits. ODP allows you to access multiple OceanBase clusters at the same time. You can perform real-time monitoring of ODP status by using various internal commands to facilitate O&M.
High availability
The high availability feature of ODP is twofold. On the one hand, ODP is highly available to provide the proxy service in a continuous way. On the other hand, ODP serves as the main component of the high availability system provided by OceanBase. To be specific, ODP makes situations such as breakdowns and upgrades imperceptible to users and ensures the stability and fast recovery of OceanBase Database.
Proprietary protocols
By default, ODP and OBServers use proprietary protocols of OceanBase Database. For example, ODP performs cyclic redundancy checks (CRCs) on messages to ensure the correctness of OBServer connections. ODP also enhances the transmission protocol to support the Oracle-compatible data types and interaction models.