Skip to main content

Module concurrency

Module concurrency 

Source
Available on crate feature cloud only.
Expand description

Adaptive in-flight concurrency controller for cloud IO (Input only).

Admission control for concurrency uses two budgets:

  • A (primary) bytes-based budget to model the bandwidth-delay product (BDP)
  • A (secondary) count-based budget to limit the number of in-flight requests

Two models set the bytes-based budget (POLARS_INFLIGHT_BYTE_BUDGET_MODEL):

  • Knee (default, knee.rs): measures the smallest budget at which the delivered bandwidth stops growing with the budget.
  • TTFB: models the BDP as BW_max * TTFB_est, with Model (records IO observations and models the network: BW_max, TTFB_est, BDP) and Regime (state machine: Init / RampUp / Stable / ProbeUp).

Admission enforces the byte-based and request-based budgets.

Structs§

ConcurrencyController
ControllerConfig
HeadRttChannel
Windowed round-trip time of 0-byte metadata (HEAD) requests. Diagnostic only, not to be used for BDP estimation.
HeadRttWindow
One control tick’s worth of HeadRttChannel observations.
InFlightBudget
InFlightPermit
InFlightStats
IoSample
Model
Regime

Enums§

RegimeState

Functions§

get_inflight_floor_request_budget
Minimum number of requests concurrently in flight, if demand is there.
get_inflight_request_budget
Maximum number of requests concurrently in flight.