You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently the rate-limit handling code interprets the contents of the x-ratelimit-reset header as a number of milliseconds from the current time to wait. (see:
However, the x-ratelimit-reset value being returned by Okta FGA is a Unix timestamp rather than an offset from the current time, meaning hitting the rate limit will theoretically cause the code to hang for ~20 days. Further down it also seems to interpret it as either a number of seconds or minutes from the current time, though this property doesn't seem to be used in the delay. An example of the headers I am receiving are:
Checklist
Description
Currently the rate-limit handling code interprets the contents of the
x-ratelimit-reset
header as a number of milliseconds from the current time to wait. (see:dotnet-sdk/src/OpenFga.Sdk/Exceptions/Parsers/RateLimitParser.cs
Line 96 in 02bbc98
Expectation
The SDK interprets the rate limit reset header as a Unix timestamp, or provides an option to do so.
Reproduction
OpenFGA SDK version
0.5.0
OpenFGA version
N/A
SDK Configuration
ApiUrl, StoreId, AuthorizationModelId and Credentials are provided. No other configuration.
Logs
No response
References
The header is interpreted as a number of milliseconds from the current time here:
dotnet-sdk/src/OpenFga.Sdk/Exceptions/Parsers/RateLimitParser.cs
Line 96 in 02bbc98
And the delay happens here:
dotnet-sdk/src/OpenFga.Sdk/ApiClient/ApiClient.cs
Line 129 in 02bbc98
The text was updated successfully, but these errors were encountered: