Skip to content

Latest commit

 

History

History
13 lines (11 loc) · 846 Bytes

File metadata and controls

13 lines (11 loc) · 846 Bytes

Rate Limiting Middleware

Rate Limiting is hybrid version of Fixed Window Algorithm, works on public routes with IP Address and private routes with JWT, also has configurable limit-weight for every route. Can be configured from .env
MongoDB-Redis cache for reducing time for authenticate user.

Features

Custom Limit and Weights for different routes
Limit and Weights can be used by both ip addresses and bucket tokens
MongoDB-Redis Caching for better query performance
Cluster Mode for concurrent http requests

Authenticate User Flowchart ( With Cache )

Flowchart
Note: Caching will not work if user authentication is fails so wrong authentication will be result in slower http response time.