-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Text Analytics] Fix rate limit reached issue #19249
[Text Analytics] Fix rate limit reached issue #19249
Conversation
API changes have been detected in API changes - export declare function throttlingRetryPolicy(): PipelinePolicy;
+ export declare function throttlingRetryPolicy(maxRetryCount?: number): PipelinePolicy; |
sdk/textanalytics/ai-text-analytics/test/public/utils/recordedClient.ts
Outdated
Show resolved
Hide resolved
…Client.ts Co-authored-by: Jeff Fisher <xirzec@xirzec.com>
sdk/textanalytics/ai-text-analytics/test/public/utils/recordedClient.ts
Outdated
Show resolved
Hide resolved
API changes have been detected in |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The core changes look great!
Co-authored-by: Jeff Fisher <xirzec@xirzec.com>
Haven't reviewed this but I know @sadasant is working in this area as well - I just wanted to make him aware so his changes do not regress anything added here (or vice-versa) ❤️ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me! The throttling test is failing due to timeout. Could be related to the DEFAULT_CLIENT_MAX_RETRY_COUNT increase.
@sadasant I updated an identity test so that it conforms to the updated number of retries. Please let me know if there is any issues there. |
Fixes #18941
Sometimes, we get rate limit reached error responses from the service that exceed the default number of retrys in the throttling retry policy.
For context, this particular API supports running multiple Text Analytics actions from one request, so the service does not like getting many successive requests for it. I also confirmed with their engineering team that the test suite is a bit too big.
To fix this, the test suite could be trimmed down but I am afraid that will affect the current coverage. Instead, I updated the retry policy for the test client to retry more.