mirror of
https://github.com/fnproject/fn.git
synced 2022-10-28 21:29:17 +03:00
Each time when MQ becomes unreachable HTTP GET /tasks returned HTTP 500 and code was not handling this case except expecting networking errors. After that it tried to unmarshal empty response body that caused another sort of an error. This patch triggers error based on http response code, explicitly checking if response code is something unexpected (not HTTP 200 OK). Response status code for /tasks for changed from 202 Accepted to 200 OK according to swagger doc.