long2ice / fastapi-limiter

A request rate limiter for fastapi
https://github.com/long2ice/fastapi-limiter
Apache License 2.0
506 stars 55 forks source link

HTTP SSE support? #57

Open benglewis opened 5 months ago

benglewis commented 5 months ago

Hi 👋 ,

This is more of a question rather than a request/bug.

Can the existing WebSocketRateLimiter functionality be used with HTTP Server-Side Events (SSE)?

Specifically, I am using SSE Starlette (https://github.com/sysid/sse-starlette) inside my FastAPI application to use HTTP SSE instead of WebSockets (it offers various advantages, from better browser support, to better tooling support since it is truly HTTP-based rather than WebSockets).

Thank you in advance for your help!

benglewis commented 5 months ago

@long2ice I'd really appreciate some kind of input here 🙏 This tool is really cool, and I'd like to know if I need to roll some kind of other solution for this problem