diff options
author | Jason M. Bills <jason.m.bills@linux.intel.com> | 2019-11-27 02:04:29 +0300 |
---|---|---|
committer | Jason Bills <jason.m.bills@linux.intel.com> | 2019-12-02 19:53:55 +0300 |
commit | 4363d3b256d469c5c133e5714f3e3be2f29b5e65 (patch) | |
tree | 5e3681cdf9c2eb2347f490c4808a41035bec98e8 | |
parent | 1ddcf01a159779cb5af2992b8f1e8ba9ab7484a5 (diff) | |
download | bmcweb-4363d3b256d469c5c133e5714f3e3be2f29b5e65.tar.xz |
Return 503 instead of 500 when Crashdump is busy
Tested:
Used Postman to send the OnDemand action twice and got a 503 with
a retry message on the second attempt.
Change-Id: I319a6318ee57e504a54b3fdb6894a5aeb43af203
Signed-off-by: Jason M. Bills <jason.m.bills@linux.intel.com>
-rw-r--r-- | redfish-core/lib/log_services.hpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/redfish-core/lib/log_services.hpp b/redfish-core/lib/log_services.hpp index 3eb4097bf9..1447f21549 100644 --- a/redfish-core/lib/log_services.hpp +++ b/redfish-core/lib/log_services.hpp @@ -1970,6 +1970,12 @@ class OnDemandCrashdump : public Node { messages::resourceInStandby(asyncResp->res); } + else if (ec.value() == + boost::system::errc::device_or_resource_busy) + { + messages::serviceTemporarilyUnavailable(asyncResp->res, + "60"); + } else { messages::internalError(asyncResp->res); |