Skip to content

Commit

Permalink
Docs: throttler uses gRPC for inter-tablet communication (#1550)
Browse files Browse the repository at this point in the history
* Docs: throttler uses gRPC for inter-tablet communication

Signed-off-by: Shlomi Noach <[email protected]>

* document --throttle_tablet_types

Signed-off-by: Shlomi Noach <[email protected]>

---------

Signed-off-by: Shlomi Noach <[email protected]>
  • Loading branch information
shlomi-noach authored Aug 2, 2023
1 parent e12c8a5 commit b3b5af0
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion content/en/docs/18.0/reference/features/tablet-throttler.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ In addition, the primary tablet is responsible for the overall health of the clu

- The throttler confirms it is still the primary tablet for its shard.
- Every `10sec`, the throttler uses the topology server to refresh the shard's tablets list.
- The throttler probes all `REPLICA` tablets for their replication lag. This is done by querying the `_vt.heartbeat` table.
- The throttler probes all `REPLICA` tablets (or other types of tablets, see [Configuration](#configuration)) for their own throttler metrics. This is done via gRPC.
- The throttler begins in dormant probe mode. As long as no application or client is actually looking for metrics, it probes the servers at multi-second intervals.
- When applications check for throttle advice, the throttler begins probing servers in subsecond intervals. It reverts to dormant probe mode if no requests are made in the duration of `1min`.
- The throttler aggregates the last probed values from all relevant tablets. This is _the cluster's metric_.
Expand Down Expand Up @@ -135,6 +135,8 @@ See [vtctl UpdateThrottlerConfig](../../programs/vtctl/throttler#updatethrottler

If you are still using the `v15` flags, you will have to transition to the new throttler configuration scheme: first populate topo with a new throttler configuration via `UpdateThrottlerConfig`. At the very least, set a `--threshold`. You likely also want to `--enable`. Then, reconfigure `vttablet`s with `--throttler-config-via-topo`, and restart them.

The list of tablet types included in the throttler's logic is dictated by `vttablet --throttle_tablet_types`. The value is a comma delimited list of tablet types. The default value is `"replica"`. You may, for example, set it to be `"replica,rdonly"`.

## Heartbeat configuration

Enabling the lag throttler also automatically enables heartbeat injection. The follwing `vttablet` flags further control heartbeat behavior:
Expand Down

0 comments on commit b3b5af0

Please sign in to comment.