Skip to content

feat: bundle the rate limiter HTTP middleware - #2389

Merged
rustatian merged 1 commit into
masterfrom
feat/bundle-rate-limiter
Sep 9, 2026
Merged

rustatian merged 1 commit into
masterfrom
feat/bundle-rate-limiter

Conversation

@rustatian

@rustatian rustatian commented Sep 8, 2026

Copy link
Copy Markdown
Member

Bundle github.com/roadrunner-server/rate-limiter/v6 at v6.0.0-beta.1.

  • Register rate_limiter in the default HTTP plugin set.
  • Add reference settings and the v3 configuration schema.
  • Add an HTTP smoke test that uses the default bundle.

Documentation: roadrunner-server/docs#80.

closes: #934

Copilot AI lite review requested due to automatic review settings September 8, 2026 20:34
@codecov

codecov Bot commented Sep 8, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 0% with 1 line in your changes missing coverage. Please review.
✅ Project coverage is 34.51%. Comparing base (7ff3883) to head (444e4bf).

Files with missing lines Patch % Lines
container/plugins.go 0.00% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #2389      +/-   ##
==========================================
- Coverage   34.56%   34.51%   -0.05%     
==========================================
  Files          18       18              
  Lines         758      759       +1     
==========================================
  Hits          262      262              
- Misses        496      497       +1     

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

The newly added e2e test’s handling of the cont.Serve() results channel can mask real plugin errors and unexpected shutdowns, so it should be corrected before merging.

Once you've addressed the issues Copilot identified, you can request another Copilot review.

Pull request overview

This PR bundles the github.com/roadrunner-server/rate-limiter/v6 plugin into RoadRunner’s default HTTP middleware set, adds reference configuration and schema support, and introduces an e2e smoke test validating the bundled middleware behavior.

Changes:

  • Register the rate limiter plugin in the default container plugin set and add the new dependency to go.mod/go.sum.
  • Extend the v3 configuration schema and .rr.yaml reference config with http.rate_limiter settings and a new rate_limiter middleware option.
  • Add an e2e HTTP smoke test and fixture config to verify 429 Too Many Requests behavior (including Retry-After and caching headers).
File summaries
File Description
tests/e2e_http_test.go Adds an e2e smoke test covering bundled rate_limiter middleware behavior.
tests/configs/.rr-http-rate-limiter.yaml New e2e fixture config enabling rate_limiter middleware and settings.
schemas/config/3.0.schema.json Adds rate_limiter middleware enum value and http.rate_limiter configuration schema.
go.mod Adds the rate-limiter/v6 dependency.
go.sum Adds checksum entries for rate-limiter/v6 v6.0.0-beta.1.
container/plugins.go Bundles rate-limiter into the default plugin list.
CHANGELOG.md Documents the new bundled rate_limiter HTTP middleware.
.rr.yaml Adds reference settings and documentation for http.rate_limiter.
Review details
  • Files reviewed: 7/8 changed files
  • Comments generated: 1
  • Review effort level: Lite

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread tests/e2e_http_test.go
@rustatian rustatian self-assigned this Sep 9, 2026
@rustatian
rustatian merged commit 45be6a0 into master Sep 9, 2026
15 checks passed
@rustatian
rustatian deleted the feat/bundle-rate-limiter branch September 9, 2026 08:06
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.

[💡FEATURE REQUEST]: Rate-limit plugin

2 participants