boinkor-net / governor

A rate-limiting library for Rust (f.k.a. ratelimit_meter)
https://github.com/boinkor-net/governor
MIT License
550 stars 43 forks source link

Support huge (>1e9 element/sec) quotas #207

Closed antifuchs closed 11 months ago

antifuchs commented 11 months ago

This should address #203: When given large quota values, some parallel usages seem to fail. Ideally, we'd have a way to construct a quota that always passes and doesn't exhibit weird parallel usage patterns...

codecov[bot] commented 11 months ago

Codecov Report

Patch coverage: 100.00% and project coverage change: -0.03% :warning:

Comparison is base (b7242de) 98.18% compared to head (29c27d7) 98.15%. Report is 10 commits behind head on master.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## master #207 +/- ## ========================================== - Coverage 98.18% 98.15% -0.03% ========================================== Files 31 31 Lines 2208 2227 +19 ========================================== + Hits 2168 2186 +18 - Misses 40 41 +1 ``` | [Files Changed](https://app.codecov.io/gh/antifuchs/governor/pull/207?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Andreas+Fuchs) | Coverage Δ | | |---|---|---| | [governor/src/gcra.rs](https://app.codecov.io/gh/antifuchs/governor/pull/207?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Andreas+Fuchs#diff-Z292ZXJub3Ivc3JjL2djcmEucnM=) | `100.00% <100.00%> (ø)` | | | [governor/tests/direct.rs](https://app.codecov.io/gh/antifuchs/governor/pull/207?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Andreas+Fuchs#diff-Z292ZXJub3IvdGVzdHMvZGlyZWN0LnJz) | `100.00% <100.00%> (ø)` | | ... and [4 files with indirect coverage changes](https://app.codecov.io/gh/antifuchs/governor/pull/207/indirect-changes?src=pr&el=tree-more&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Andreas+Fuchs)

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

antifuchs commented 11 months ago

bors merge

bors[bot] commented 11 months ago

Build succeeded!

The publicly hosted instance of bors-ng is deprecated and will go away soon.

If you want to self-host your own instance, instructions are here. For more help, visit the forum.

If you want to switch to GitHub's built-in merge queue, visit their help page.