Skip to content
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

add retry for luis rate limiting issue #830

Merged
merged 9 commits into from
Jun 12, 2020
Merged

Conversation

feich-ms
Copy link
Contributor

@feich-ms feich-ms commented May 28, 2020

fixes #819.
For bf-lu, exposed multiple parameters for composer or other client to consume to configure the luis api call rate:

  1. Luis api tps(concurrent number): default to 5 and can switch to 50 when using a paid key
  2. time bucket of concurrent api calls: default to 1100 ms and can switch to higher value to reduce rate limit exception frequency
  3. retry count: default to 1 and can switch to higher value to reduce rate limit exception frequency
  4. retry delay time: default to 1000ms and can switch to higher value to redeuce rate limit exception frequency

For bf-luis-cli, all values of above parameters are default ones which means adding once retry after 1 second for any rate limiting error when calling luis api. If still running into this issue after retry, will let it throw out. Tested it manually from luis:build command, and it can mitigate the error rate limiting frequency effectively but cannot guarantee 100% resolving.

Composer can configure the paramters based on user feedbacks.

@boydc2014
Copy link
Contributor

can we make the parameters in the scheduler configrable like

  • retry count
  • delay time
  • time bucket per request

@feich-ms
Copy link
Contributor Author

feich-ms commented Jun 3, 2020

resolved Dong's suggestions.

@feich-ms feich-ms merged commit 5d7dd80 into master Jun 12, 2020
@feich-ms feich-ms deleted the feich/addRetryForLUISLimit branch June 12, 2020 04:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add retry mechanism if luis build run into rate limiting issue
3 participants