Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update Rack Attack to reduce Redis calls #10000

Merged
merged 1 commit into from
Jan 30, 2024

Conversation

mitchellhenke
Copy link
Contributor

🛠 Summary of changes

This PR is mostly for performance reasons. In rack/rack-attack#597, an improvement was made to reduce the number of Redis calls in rack-attack.

For us, the improvement is pretty significant:

❤️ ❤️ ❤️  (Statistically Significant) ❤️ ❤️ ❤️

(0.2698 seconds) "rack attack update"
  FASTER 🚀🚀🚀 by:
    1.0643x [older/newer]
    6.0431% [(older - newer) / older * 100]
(0.2872 seconds) "main"

Iterations per sample: 200
Samples: 200

Test type: Kolmogorov Smirnov
Confidence level: 99.0 %
Is significant? (max > critical): true
D critical: 0.15174271293851463
D max: 0.66

I had been planning on waiting for a full release, but it's been a bit over 6 months since the last one. We should revert back to the RubyGems releases once there has been a release that includes this change.

changelog: Internal, Rate Limiting, Update Rack Attack
@mitchellhenke mitchellhenke merged commit c3c086a into main Jan 30, 2024
2 checks passed
@mitchellhenke mitchellhenke deleted the mitchellhenke/update-rack-attack branch January 30, 2024 15:33
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.

2 participants