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

Question: Exponential Backoff execution times #197

Open
jarenal opened this issue Sep 7, 2022 · 1 comment
Open

Question: Exponential Backoff execution times #197

jarenal opened this issue Sep 7, 2022 · 1 comment

Comments

@jarenal
Copy link

jarenal commented Sep 7, 2022

Hi guys,

a question about how works the Exponential Backoff algorith...

If I use these settings:

raxConfig: {
  retryDelay: 3000, // Milliseconds
  backoffType: 'exponential',
  retry: 3
}

When will be executed the last try?

If I'm not wrong the first try will be executed 3 seconds after the original request, right?

  • ORIGINAL REQUEST: 0 seconds
  • FIRST TRY: After 3 seconds
  • SECOND TRY: No idea
  • THIRD TRY: No idea

How can I calculated when the second and third try will be executed?

Thanks a lot!

@jarenal
Copy link
Author

jarenal commented Sep 8, 2022

Maybe someone find this is useful...

17:11:23 First request...
17:11:25 Retry attempt 1
17:11:27 Retry attempt 2
17:11:30 Retry attempt 3
17:11:35 Retry attempt 4
17:11:44 Retry attempt 5
17:12:01 Retry attempt 6
17:12:34 Retry attempt 7
17:13:39 Retry attempt 8
17:15:48 Retry attempt 9
17:20:05 Retry attempt 10

FYI the parameter retryDelay has not effect when backoffType is exponential.

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

No branches or pull requests

1 participant