Metrics
The global occupancy controller updates all four gauges when a request is admitted, released, adjusted to exact input usage, or grown by streamed output. The healthy-replica count is recomputed for each admission and floored at
1, so the budget and backstop gauges follow the live serving pool.
Per-tenant RPM rejects also increment hivenet_router_tenant_rate_limited_total in addition to the unified b4_rpm reason below.
Rejection reasons
PromQL examples
Occupancy utilization
In-flight concurrency utilization
Rejections by gate
Front-door shed rate
Serverless per-key gate pressure
tenant_id or key_id label, so it can show that a per-key gate is firing but cannot identify the individual key. Correlate the time window with tenant failure and token-limit metrics or audit records.
Interpret the signals
- Occupancy near budget with rising
b2means the model is at its global KV-occupancy limit. b3rising while occupancy remains below budget means live engine pressure is worse than the token estimate suggests, or the configured shed threshold is deliberately more conservative.- Sustained
b4_itpm,b4_otpm, orb4_occupancycan indicate abusive traffic or undersized serverless key limits. - A nonzero
max_inflightwith high concurrency utilization can bind before the token budget does when requests are small.

