Skip to content

Commit

Permalink
follower read: add new option for tidb_replica_read (#2252) (#2283)
Browse files Browse the repository at this point in the history
Signed-off-by: qupeng <qupeng@pingcap.com>

Co-authored-by: qupeng <qupeng@pingcap.com>
Co-authored-by: Shen Li <shenli3514@gmail.com>
  • Loading branch information
3 people authored Apr 23, 2020
1 parent ff53642 commit fb35027
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion reference/performance/follower-read.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ The Follower Read feature refers to using any follower replica of a Region to se
## Usage

To enable TiDB's Follower Read feature, set the value of the `tidb_replica_read` session variable to `follower`:
To enable TiDB's Follower Read feature, set the value of the `tidb_replica_read` session variable to `follower` or `leader-and-follower`:

{{<copyable "sql">}}

Expand All @@ -34,6 +34,7 @@ This variable is used to set the data read mode expected by the current session.

- When the value of `tidb_replica_read` is set to `leader` or an empty string, TiDB maintains its original behavior and sends all read operations to the leader replica to perform.
- When the value of `tidb_replica_read` is set to `follower`, TiDB selects a follower replica of the Region to perform all read operations.
- When the value of `tidb_replica_read` is set to `leader-and-follower`, TiDB can select any replicas to perform read operations.

## Implementation mechanism

Expand Down

0 comments on commit fb35027

Please sign in to comment.