Skip to content

Add waf.limitMetrics read API#42

Merged
acoshift merged 1 commit into
mainfrom
waf-limit-metrics
Jun 11, 2026
Merged

Add waf.limitMetrics read API#42
acoshift merged 1 commit into
mainfrom
waf-limit-metrics

Conversation

@acoshift

Copy link
Copy Markdown
Member

Summary

Adds the waf.limitMetrics read API: request/response types (WAFLimitMetrics, WAFLimitMetricsResult, WAFLimitMetricsSeries) + client method, mirroring waf.metrics at the (limit, result) grain over the rate-limit usage the collector now stores.

The console firewall metrics page (deploys-app/console#187) charts the limited share — limited / (allowed + limited) — from this, which is how a shadow-mode limit is sized before enforcing.

Context

This was originally written on the ratelimit-usage branch but landed after api#41 was already squash-merged, so it never made it to main. This re-lands it as a clean single-commit addition on top of #41.

Companion: apiserver PR adds the LimitMetrics handler.

🤖 Generated with Claude Code

Mirrors waf.metrics at the (limit, result) grain over ratelimit_usages,
so the console can chart the limited share — limited / (allowed +
limited) — which is how a shadow-mode limit is sized before enforcing.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@acoshift acoshift merged commit 0bb45a8 into main Jun 11, 2026
@acoshift acoshift deleted the waf-limit-metrics branch June 11, 2026 10:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant