Commit graph

23 commits

Author SHA1 Message Date
Hazelnoot
3e90b211ba fix "duplicate cache" errors in SkRateLimiterServiceTests 2025-11-05 22:33:57 -05:00
Hazelnoot
effdea5658 update unit tests and mocks 2025-11-05 19:42:30 -05:00
Hazelnoot
6e36462c80 update SkRateLimiterServiceTests.ts to use standard mocks and fakes 2025-11-05 19:42:30 -05:00
Hazelnoot
a55649e89a move global services to "global" directory 2025-11-05 19:42:28 -05:00
Hazelnoot
8e000ae313 implement MockEnvService and fix tests 2025-11-05 19:41:09 -05:00
Hazelnoot
b32f3b5019 manage caches in SkRateLimiterService 2025-11-05 19:20:05 -05:00
Hazelnoot
d2ec40fb87 scale rate limit dripRate with factor 2025-07-21 15:57:30 -04:00
Hazelnoot
f92fb3bb8c move SkRateLimiterService to correct directory 2025-02-05 11:20:26 -05:00
Hazelnoot
09669d72e7 lookup and cache rate limit factors directly within SkRateLimiterService 2025-02-05 11:20:25 -05:00
Hazelnoot
72d18602d8 fix SkRateLimiterService tests 2024-12-11 14:07:14 -05:00
Hazelnoot
0ea9d6ec5d use atomic variant of Leaky Bucket for safe concurrent rate limits 2024-12-11 09:10:11 -05:00
Hazelnoot
407b2423af fix redis transaction implementation 2024-12-10 19:01:35 -05:00
Hazelnoot
ead781900d enable rate limits for dev environment 2024-12-09 19:04:59 -05:00
Hazelnoot
9daafca155 fix rate limits under multi-node environments 2024-12-09 19:04:06 -05:00
Hazelnoot
2946f85592 fix type errors from new rate limit definitions 2024-12-08 13:22:07 -05:00
Hazelnoot
fc4599ec07 fix rate limit scaling (it's no longer inverted) 2024-12-08 12:02:58 -05:00
Hazelnoot
91c9b67cb0 bypass rate limits when factor is 0 2024-12-08 11:58:57 -05:00
Hazelnoot
7c002ce56e move all Rate Limit type defs to rate-limit-utils.ts 2024-12-08 11:33:57 -05:00
Hazelnoot
8b091f77ca check for invalid rate limit inputs 2024-12-08 09:46:49 -05:00
Hazelnoot
a7a1edc92e fix NaN from extremely high rate limits 2024-12-08 09:22:38 -05:00
Hazelnoot
2781f53d6b support fractional rate limit scaling 2024-12-08 08:32:05 -05:00
Hazelnoot
32635ecc25 fix rate limit storage in redis 2024-12-07 12:15:38 -05:00
Hazelnoot
ffc2737478 implement SkRateLimiterService with Leaky Bucket rate limiting 2024-12-07 10:22:49 -05:00