Systems and methods for API rate limiting and distribution
First Claim
1. A method, comprising:
- receiving, by an application programming interface (API) proxy system embodied on a cluster of server machines running in a multi-tenant computing environment, a client request from an API client associated with a tenant of the multi-tenant computing environment, the tenant having an application running on a website, the application limited to resources defined for the tenant, the client request referencing a resource of the resources;
calculating, by the API proxy system using an exponential distribution function, a quota of requests allowed for the API client for a current time window, the calculating performed by the API proxy system based on a resource limit with respect to a number of API clients that are currently connected to the API proxy system and that are requesting the resource in the current time window, wherein the exponential distribution function is configured for exponentially scaling the quota of requests allowed for the API client in the current time window utilizing a growth factor and a multiplier, wherein the growth factor is tunable up or down depending upon the number of API clients requesting the resource in the current window, and wherein the multiplier multiplies the growth factor such that the quota of requests thus calculated by the API proxy system for the API client for the current time window also scales exponentially up or down depending upon the number of API clients that are currently connected to the API proxy system and that are requesting the resource in the current time window; and
responsive to receiving an API request from another API client to access the resource, updating, by the API proxy system, the quota of requests calculated for the API client for the current time window.
3 Assignments
0 Petitions
Accused Products
Abstract
An API rate limiting system may receive a client request from an API client associated with a tenant, formulate a proxied request with an internal authentication specific to the tenant, and send the proxied request to API endpoints (tenant resources) at a store. The store fulfills the request, accessing and modifying local database(s) as needed, and returns a response to the system. The system returns the response to the API client along with information about the API client'"'"'s quota for the current time window. The system may calculate the quota based on a resource limit with respect to a number of clients accessing a resource. In some embodiments, the system may implement an exponential distribution function in making a determination on a quota per API client per time window.
16 Citations
20 Claims
-
1. A method, comprising:
-
receiving, by an application programming interface (API) proxy system embodied on a cluster of server machines running in a multi-tenant computing environment, a client request from an API client associated with a tenant of the multi-tenant computing environment, the tenant having an application running on a website, the application limited to resources defined for the tenant, the client request referencing a resource of the resources; calculating, by the API proxy system using an exponential distribution function, a quota of requests allowed for the API client for a current time window, the calculating performed by the API proxy system based on a resource limit with respect to a number of API clients that are currently connected to the API proxy system and that are requesting the resource in the current time window, wherein the exponential distribution function is configured for exponentially scaling the quota of requests allowed for the API client in the current time window utilizing a growth factor and a multiplier, wherein the growth factor is tunable up or down depending upon the number of API clients requesting the resource in the current window, and wherein the multiplier multiplies the growth factor such that the quota of requests thus calculated by the API proxy system for the API client for the current time window also scales exponentially up or down depending upon the number of API clients that are currently connected to the API proxy system and that are requesting the resource in the current time window; and responsive to receiving an API request from another API client to access the resource, updating, by the API proxy system, the quota of requests calculated for the API client for the current time window. - View Dependent Claims (2, 3, 4, 5, 6, 7)
-
-
8. An application programming interface (API) proxy system, comprising:
-
a processor; a non-transitory computer-readable medium; stored instructions translatable by the processor to perform; receiving a client request from an API client associated with a tenant of a multi-tenant computing environment, the tenant having an application running on a website, the application limited to resources defined for the tenant, the client request referencing a resource of the resources; calculating, using an exponential distribution function, a quota of requests allowed for the API client for a current time window, the calculating based on a resource limit with respect to a number of API clients that are currently connected to the API proxy system and that are requesting the resource in the current time window, wherein the exponential distribution function is configured for exponentially scaling the quota of requests allowed for the API client in the current time window utilizing a growth factor and a multiplier, wherein the growth factor is tunable up or down depending upon the number of API clients requesting the resource in the current window, and wherein the multiplier multiplies the growth factor such that the quota of requests thus calculated for the API client for the current time window also scales exponentially up or down depending upon the number of API clients that are currently connected to the API proxy system and that are requesting the resource in the current time window; and responsive to receiving an API request from another API client to access the resource, updating the quota of requests calculated for the API client for the current time window. - View Dependent Claims (9, 10, 11, 12, 13, 14)
-
-
15. A computer program product comprising a non-transitory computer-readable medium storing instructions translatable by a processor to perform:
-
receiving a client request from an API client associated with a tenant of a multi-tenant computing environment, the tenant having an application running on a website, the application limited to resources defined for the tenant, the client request referencing a resource of the resources; calculating, using an exponential distribution function, a quota of requests allowed for the API client for a current time window, the calculating based on a resource limit with respect to a number of API clients that are currently connected to the API proxy system and that are requesting the resource in the current time window, wherein the exponential distribution function is configured for exponentially scaling the quota of requests allowed for the API client in the current time window utilizing a growth factor and a multiplier, wherein the growth factor is tunable up or down depending upon the number of API clients requesting the resource in the current window, and wherein the multiplier multiplies the growth factor such that the quota of requests thus calculated for the API client for the current time window also scales exponentially up or down depending upon the number of API clients that are currently connected to the API proxy system and that are requesting the resource in the current time window; and responsive to receiving an API request from another API client to access the resource, updating the quota of requests calculated for the API client for the current time window. - View Dependent Claims (16, 17, 18, 19, 20)
-
Specification