ThreeMammals / Ocelot

.NET API Gateway
https://www.nuget.org/packages/Ocelot
MIT License
8.24k stars 1.62k forks source link

Is ocelot support sharing routes and rate limit configuration between it's instances if we publish more than one ocelot instance ? #2097

Closed MMoussaSURE closed 1 month ago

MMoussaSURE commented 1 month ago

Expected Behavior / New Feature

i want to publish two instance of ocelot at different servers but the under the same domain and if the user called my domain/{upstreamRoute} one of ocelot instances should achieve the request but also the two instances should achieve the rate limit of any one of them called for example "Routes": [ { "DownstreamPathTemplate": "/product", "DownstreamScheme": "https", "DownstreamHostAndPorts": [ { "Host": "products.com", "Port": 44322 } ], "UpstreamPathTemplate": "/api/product", "UpstreamHttpMethod": [ "POST" ], "RouteIsCaseSensitive": true, "RateLimitOptions": { "ClientWhitelist": [], "EnableRateLimiting": true, "Period": "60s", "PeriodTimespan": 60, "Limit": 1 } } ] "GlobalConfiguration": { "BaseUrl": "https://api.products", "RateLimitOptions": { "DisableRateLimitHeaders": false, "QuotaExceededMessage": "Too Many Requests At Short Duration!", "HttpStatusCode": 429 } }

what should happen is