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 exponential backoff when status returns 503 #1851

Merged
merged 2 commits into from
Jul 6, 2018
Merged

Add exponential backoff when status returns 503 #1851

merged 2 commits into from
Jul 6, 2018

Conversation

masci
Copy link
Contributor

@masci masci commented Jul 5, 2018

What does this PR do?

When retrieving the /status endpoint from php_fpm, retry according to an exponential backoff policy but only in case the response is 503 since it's expected (see https://github.com/php/php-src/blob/d84ef967424343abcc48b8f945d5e7807f1c1e09/sapi/fpm/fpm/fpm_status.c#L96).

Motivation

Fixing #1843

Review checklist

  • PR has a meaningful title or PR has the no-changelog label attached
  • Feature or bugfix has tests
  • Git history is clean
  • If PR impacts documentation, docs team has been notified or an issue has been opened on the documentation repo

zippolyte
zippolyte previously approved these changes Jul 5, 2018
Copy link
Contributor

@zippolyte zippolyte left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, but can we really call that exponential ? 🙂

@masci
Copy link
Contributor Author

masci commented Jul 5, 2018

Fair enough, I though that 1,2,3 + c was more than enough, let me do 1,2,4 and make it actually exponential 😛

Copy link
Contributor

@zippolyte zippolyte left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@masci masci merged commit 100daf4 into master Jul 6, 2018
@masci masci deleted the massi/php branch July 6, 2018 08:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants