enable_standby_read_write_split specifies whether to enable read/write splitting between the primary and standby tenants for a tenant logged in to by using a service name.
Note
This parameter was introduced in OceanBase Database Proxy (ODP) V4.3.3.
The modification takes effect only for new connections.
| Attribute | Description |
|---|---|
| Parameter type | Boolean |
| Default value | False |
| Value range |
|
| Effective only after ODP restart | No |
Examples
When you set this parameter for a tenant, specify the tenant name in the service:xxxx format and leave the cluster name empty. The following example enables read/write splitting between the primary and standby tenants for the service_name_a tenant.
Set the name of the LDC standby cluster for the
service_name_atenant tocluster_A.replace into proxy_config(cluster_name, tenant_name, name, value, config_level) values ('', 'service:service_name_a', 'rootservice_cluster_name', 'cluster_A', 'LEVEL_TENANT');Enable read/write splitting between the primary and standby tenants for the
service_name_atenant.replace into proxy_config(cluster_name, tenant_name, name, value, config_level) values ('', 'service:service_name_a', 'enable_standby_read_write_split', 'true', 'LEVEL_TENANT');
References
For more information about the
rootservice_cluster_nameparameter, see rootservice_cluster_name.For more information about service names, see Automatic routing to the primary/standby tenants.