Closed dstone1983 closed 2 years ago
Hello All,
I am implementing retry logic to my system. I am attempting to only retry if the health check api comes back successful. It seems to be retrying no matter what.
doing a:
retryCondition:() => false
works
retryCondition: async () => { try { await axios.get(healthcheckurl) return true } catch(error) { return false } }
Is there a way to achievce this? I don't want it to retry if the healthcheck fails.
I appreciate the assistance
retryCondition is called if Axios return an Error
try this https://github.com/JustinBeckwith/retry-axios
Hello All,
I am implementing retry logic to my system. I am attempting to only retry if the health check api comes back successful. It seems to be retrying no matter what.
doing a:
retryCondition:() => false
works
retryCondition: async () => { try { await axios.get(healthcheckurl) return true } catch(error) { return false } }
Is there a way to achievce this? I don't want it to retry if the healthcheck fails.
I appreciate the assistance