rateLimitRetryCallback
Optional callback invoked when an HTTP 429 rate-limit response is received.
The callback receives the current retryCount (0-based: 0 on first retry opportunity) and returns a RateLimitRetryConfig to retry, or null to stop retrying and surface the failure to the caller. When this callback is null (the default), 429 responses are never retried and are surfaced as com.okta.authfoundation.client.OAuth2ClientResult.Error immediately.
If the callback throws, the exception propagates to the caller without retrying.
rateLimitRetryCallback = { retryCount ->
if (retryCount < 3) RateLimitRetryConfig(MaxRetries(3), MinDelaySeconds(1L))
else null
}Content copied to clipboard