-
Notifications
You must be signed in to change notification settings - Fork 16.4k
Add retry on error 502 and 504 #42994
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 on error 502 and 504 #42994
Conversation
jscheffl
left a comment
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.
CI fails - otherwise some minor comments. Otherwise looking good.
jscheffl
left a comment
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.
Thanks for the contribution and the re-work. Looks good for me as well as the tests added.
I'd classify this as a bug and propose to back-port this also to v2-line
* Add retry on error 502 and 504 * fix mypy findings * Add pytest * Convert response code to HTTPStatus * Add docs to retriable exception * extend docs for AirflowHttpException * Fix syntax and typos * fix pytest * fix static checks * fix some static checks * Fix ruff * fix pre-commit --------- Co-authored-by: Majoros Donat (XC-DX/EET2-Bp) <donat.majoros2@hu.bosch.com> (cherry picked from commit 477d747)
* Add retry on error 502 and 504 * fix mypy findings * Add pytest * Convert response code to HTTPStatus * Add docs to retriable exception * extend docs for AirflowHttpException * Fix syntax and typos * fix pytest * fix static checks * fix some static checks * Fix ruff * fix pre-commit --------- Co-authored-by: Majoros Donat (XC-DX/EET2-Bp) <donat.majoros2@hu.bosch.com> (cherry picked from commit 477d747) Co-authored-by: majorosdonat <mjd2bp@bosch.com>
* Add retry on error 502 and 504 * fix mypy findings * Add pytest * Convert response code to HTTPStatus * Add docs to retriable exception * extend docs for AirflowHttpException * Fix syntax and typos * fix pytest * fix static checks * fix some static checks * Fix ruff * fix pre-commit --------- Co-authored-by: Majoros Donat (XC-DX/EET2-Bp) <donat.majoros2@hu.bosch.com>
* Add retry on error 502 and 504 * fix mypy findings * Add pytest * Convert response code to HTTPStatus * Add docs to retriable exception * extend docs for AirflowHttpException * Fix syntax and typos * fix pytest * fix static checks * fix some static checks * Fix ruff * fix pre-commit --------- Co-authored-by: Majoros Donat (XC-DX/EET2-Bp) <donat.majoros2@hu.bosch.com> (cherry picked from commit 477d747) Co-authored-by: majorosdonat <mjd2bp@bosch.com>
* Add retry on error 502 and 504 * fix mypy findings * Add pytest * Convert response code to HTTPStatus * Add docs to retriable exception * extend docs for AirflowHttpException * Fix syntax and typos * fix pytest * fix static checks * fix some static checks * Fix ruff * fix pre-commit --------- Co-authored-by: Majoros Donat (XC-DX/EET2-Bp) <donat.majoros2@hu.bosch.com>
* Add retry on error 502 and 504 * fix mypy findings * Add pytest * Convert response code to HTTPStatus * Add docs to retriable exception * extend docs for AirflowHttpException * Fix syntax and typos * fix pytest * fix static checks * fix some static checks * Fix ruff * fix pre-commit --------- Co-authored-by: Majoros Donat (XC-DX/EET2-Bp) <donat.majoros2@hu.bosch.com>
* Add retry on error 502 and 504 * fix mypy findings * Add pytest * Convert response code to HTTPStatus * Add docs to retriable exception * extend docs for AirflowHttpException * Fix syntax and typos * fix pytest * fix static checks * fix some static checks * Fix ruff * fix pre-commit --------- Co-authored-by: Majoros Donat (XC-DX/EET2-Bp) <donat.majoros2@hu.bosch.com> (cherry picked from commit 477d747) Co-authored-by: majorosdonat <mjd2bp@bosch.com>
* Add retry on error 502 and 504 * fix mypy findings * Add pytest * Convert response code to HTTPStatus * Add docs to retriable exception * extend docs for AirflowHttpException * Fix syntax and typos * fix pytest * fix static checks * fix some static checks * Fix ruff * fix pre-commit --------- Co-authored-by: Majoros Donat (XC-DX/EET2-Bp) <donat.majoros2@hu.bosch.com>
When an application gateway or a Kubernetes ingress cannot find a running instance of a webserver hosting the API
The edge worker crashes and restarts due to HTTP error 502 and 504 (during webserver startup). To prevent this, the retried errors are extended with "bad gateway" and "gateway timeout" in the internal api call.
^ Add meaningful description above
Read the Pull Request Guidelines for more information.
In case of fundamental code changes, an Airflow Improvement Proposal (AIP) is needed.
In case of a new dependency, check compliance with the ASF 3rd Party License Policy.
In case of backwards incompatible changes please leave a note in a newsfragment file, named
{pr_number}.significant.rstor{issue_number}.significant.rst, in newsfragments.