Comment 4 for bug 2059032

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to neutron (stable/2024.1)

Reviewed: https://review.opendev.org/c/openstack/neutron/+/914260
Committed: https://opendev.org/openstack/neutron/commit/646270de5b740e6bc35f070ababf3e4f14e47f38
Submitter: "Zuul (22348)"
Branch: stable/2024.1

commit 646270de5b740e6bc35f070ababf3e4f14e47f38
Author: Anton Kurbatov <email address hidden>
Date: Mon Mar 25 18:49:52 2024 +0000

    Fixing the 500 HTTP code in the metadata service if Nova is down

    If the Nova metadata service is unavailable, the requests.request()
    function may raise a ConnectionError. This results in the upper code
    returning a 500 HTTP status code to the user along with a traceback.
    Let's handle this scenario and instead return a 503 HTTP status code
    (service unavailable).

    If the Nova service is down and is behind another proxy (such as
    Nginx), then instead of a ConnectionError, the request may result in
    receiving a 502 or 503 HTTP status code. Let's also consider this
    situation and add support for an additional 504 code.

    Closes-Bug: #2059032
    Change-Id: I16be18c46a6796224b0793dc385b0ddec01739c4
    (cherry picked from commit 6395b4fe8ed99855853587fa93cb59fd2691aed5)