---
slug: "Throttle"
name: "Throttle"
type: "Primitives"
layer: "Infrastructure"
ref: "Throttle#dd62"
sema_id: "sema:Throttle#mh:SHA-256:dd626ad2479e5377339f44e77b61a0264591ed21a906556f020fccb98450fe55"
tags: ["Infrastructure","Primitives"]
updated: 2026-11-11
mindscape: "bootstrap"
index_url: https://mindscape.world/scapes/bootstrap.json
url: https://mindscape.world/bootstrap/Throttle/
related: ["Task","Backoff","Cooldown","Warmup"]
---

# Throttle

Rate-limiting to prevent resource exhaustion

Layer: Infrastructure · Category: Primitives

## Mechanism

Rate Limiting: Maximum N [Task](https://mindscape.world/scapes/bootstrap/Task.md)s per time window W. Excess requests rejected, queued, or delayed. Window can be sliding or fixed. Separate limits per action type or global. Utilizes [Backoff](https://mindscape.world/scapes/bootstrap/Backoff.md).

## Invariants

- Rate limit: output rate ≤ `rate_limit` within any `window`, sliding or fixed.
- Excess is handled by the declared `excess_policy` — rejected, queued, or delayed. Only rejection drops.

## Preconditions

- Token bucket or Leaky bucket state initialized

## Failure modes

- Unbounded queue: `excess_policy` is queue or delay and arrivals stay above the limit, so latency grows without anything being dropped or refused.

## Parameters

- `rate_limit` (Integer, [1, 10000]): Max requests per window
- `window` (Duration, [1s, 1h]): Time window for rate calculation
- `burst_size` (Integer, [1, 100]): Temporary overflow allowance
- `excess_policy` (Enum, {reject, queue, delay}): What happens above the limit. Named in the intersection and previously expressible nowhere.

## Builds on

- [Task](https://mindscape.world/scapes/bootstrap/Task.md) (Infrastructure; Accepts)
- [Backoff](https://mindscape.world/scapes/bootstrap/Backoff.md) (Infrastructure; Composes with)

## Used by

- [Cooldown](https://mindscape.world/scapes/bootstrap/Cooldown.md) (Infrastructure; References)
- [Warmup](https://mindscape.world/scapes/bootstrap/Warmup.md) (Infrastructure; References)

## Identity

- Sema ID: `sema:Throttle#mh:SHA-256:dd626ad2479e5377339f44e77b61a0264591ed21a906556f020fccb98450fe55`
- Ref: `Throttle#dd62`
- Supersedes:
  - `sema:Throttle#mh:SHA-256:3b435aa8eded864eadf7d8eec80d395fd7f4e6c2749d33880cbf8c4593f926af`
  - `sema:Throttle#mh:SHA-256:24860a38fb19f46f0cd620ada5ec2abadef4377dc6c0459f14180e4ce7aed7c8`
  - `sema:Throttle#mh:SHA-256:dc1439d0fbf64ac81ebea3d7570e55d7b94802d028061470a2e5681bc3c1d5f6`

## Links

- [Pattern page](https://mindscape.world/bootstrap/Throttle/)
- [View in the interactive graph](https://mindscape.world/bootstrap/#Throttle)
- [JSON](https://mindscape.world/scapes/bootstrap/Throttle.json)
- [Index of all patterns](https://mindscape.world/scapes/bootstrap.json)
