Overview
max_stale_time_for_weak_consistency specifies the maximum age of stale data allowed for weak-consistency reads.
Privilege requirements
Query parameters
Both the
systenant and all user tenants can query this parameter using theSHOW PARAMETERSstatement or theGV$OB_PARAMETERSview.Modify parameters
Both the
systenant and user tenants can modify this parameter.
Attributes
Attribute |
Description |
|---|---|
| Parameter type | Time |
| Default Value | 5s |
| Value range | [5s, +∞) |
| Modifiable | Yes, you can use the following methods:ALTER SYSTEM SETStatement modification. |
| Whether to restart the OBServer node for the change to take effect | No, the setting takes effect immediately. |
Configuration example
The maximum allowed time lag between the data read in weak-consistency read mode and that of the leader replica is set to 5 seconds.
obclient> ALTER SYSTEM SET max_stale_time_for_weak_consistency= '5s';