Revert commit 20d9d48
For `node_is_alive`, it seemed to be a good idea to exit with a `CRITICAL` when the target doesn't exist. But for all the rest, UNKNOWN (which corresponds to a configuration error) seems better.
This commit is contained in:
parent
94a1388d06
commit
b69c2501fd
|
@ -73,7 +73,7 @@ class PatroniResource(nagiosplugin.Resource):
|
|||
return r.json()
|
||||
except requests.exceptions.JSONDecodeError:
|
||||
return None
|
||||
raise APIError("Connection failed for all provided endpoints")
|
||||
raise nagiosplugin.CheckError("Connection failed for all provided endpoints")
|
||||
|
||||
|
||||
HandleUnknown = Callable[[nagiosplugin.Summary, nagiosplugin.Results], Any]
|
||||
|
|
Loading…
Reference in a new issue