The high availability of OBKV-Table depends on the high availability of the entire data link. In addition to the high availability of OBServer nodes, it also relies on the high availability of proxies and clients along the link. On the database server side, OBKV-Table inherits the high availability capabilities of OceanBase AI Database and supports both direct connection mode and proxy mode in deployment.
High availability of OBServer nodes
OceanBase AI Database provides a variety of high availability technologies for services, including multi-replica disaster recovery within a cluster, arbitration-based disaster recovery, and physical standby database disaster recovery between clusters.
High availability of the link
High availability in proxy mode
OceanBase Database Proxy (ODP) is a dedicated proxy server for OceanBase AI Database. The high availability of ODP has two dimensions:
- Implement high availability for ODP services. The ODP service can be quickly restored after a failure occurs.
- Ensure the high availability of OceanBase AI Database.
For example, it detects and identifies failures of OceanBase AI Database nodes and adds them to a blocklist, shielding applications from database failures through proper routing. When a database node recovers from a failure, the OBServer node is promptly removed from the blocklist, fully utilizing the resources of each machine.
High availability in direct connection mode
The direct connection mode of OBKV-Table means that client requests are directly delivered to the corresponding OBServer node on the server side without ODP forwarding. In a distributed system, to ultimately deliver messages to the correct processing node, the message addressing problem must be solved. The most general approach to addressing is to cache the routing table of the distributed system and query this table before delivering a message.
In ODP mode, ODP is deployed as an independent component. Clients do not need to worry about routing; messages are delivered to ODP according to a load balancing algorithm or component, and ODP then routes the messages based on the routing table. The advantage is that it relies less on clients; as long as the message protocol is followed, ODP can handle the routing. The disadvantage is that since it needs to be deployed separately, it is generally not on the same physical node as the clients or the database server, resulting in message forwarding and network overhead.
The idea behind the direct connection mode is to directly incorporate routing capabilities into the client itself. This way, message routing is completed within the client process, and messages are delivered directly to the corresponding database processing node, avoiding message forwarding and network overhead. However, because routing capabilities are implemented directly within the client, it has a strong dependency on the client.
The client of OBKV-Table also has high availability capabilities similar to ODP:
- The OBKV-Table client caches routing information. When OBServer nodes are scaled, fail, or are balanced, or in other scenarios that cause routing changes, the OBKV-Table client uses mechanisms such as refreshing the routing table and retrying messages to prevent the business from perceiving these changes on the database server, ensuring uninterrupted business operations.
- The OBKV-Table client is configured with the URL of the Config Server. OBKV-Table pulls the Rslist from the Config Server and caches it, and then retrieves routing information from the nodes in the Rslist. When the Rslist changes, OBServer pushes the updated Rslist to the Config Server.