High availability is an important feature of a distributed system. This chapter describes the high availability mechanism of OceanBase Database Proxy (ODP).
The high availability design of a system reduces service downtime. If a system can provide services without stop, the availability of the system is 100%. If a system fails to provide services in one time unit out of every 100 time units for which it runs, the availability is 99%.
The single-point design of a system is usually the greatest risk to system availability, and should be avoided as much as possible in system design. The underlying method to ensure high availability is to adopt the "clustering" or "redundancy" design. Services are interrupted when a single point fails. With redundant backups, services can be switched to a backup when a server fails.
To ensure high availability of a system, the core principle of architecture design is redundancy. However, redundancy alone is not enough. The need for manual intervention and recovery upon each fault also increases service downtime of the system. Therefore, the "automatic failover" mechanism is usually used to achieve high availability.
The high availability feature of ODP covers the following two aspects:
High availability of ODP services
ODP services can be recovered in a timely manner after a failure occurs.
High availability of OceanBase Database
For example, ODP can detect and identify faulty OceanBase Database nodes and add them to the blacklist. It can also shield applications from database faults through proper routing. When a database node is recovered, ODP adds the OBServer node back to the whitelist to ensure that resources of each server are fully utilized.