https://kotlinlang.org logo
#ktor
Title
# ktor
m

martmists

01/14/2022, 3:20 PM
Is there a library for bucket-based per-client ratelimiting? I've only found ones that have a global configuration rather than allowing specifying it per bucket (if it even had buckets)
r

Robert Jaros

01/14/2022, 3:58 PM
I have successfully implemented per-IP bucket rate limiting with Bucket4j (https://github.com/vladimir-bukhtoyarov/bucket4j). Async support works nice with coroutines (I've used it with Spring Webflux not Ktor, though).
m

martmists

01/14/2022, 4:14 PM
Any clue how I'd add this to ktor easily?