Closed mrichards42 closed 3 years ago
Good catch. I don't remember the reason to specify this default. As in latest failsafe, the default max retry is set to 2.
I think it's ok to remove this default value.
hmmm.. I was wrong. In order to maintain backward-compatibility, I should keep -1 as default value of max-retries
.
Fixed in https://github.com/sunng87/diehard/commit/0db1e95040f2bab761701661abf091c4e97dda7d and released in 0.10.2
With the changes in #42,
retry-policy-from-config
with just a policy and no overrides ends up overwriting:max-retries
with-1
. A minimal reproduction, based on an existing testIt looks like
:max-retries
is the only option with a default. Removing the default would fix this issue, but I'm not sure if it's safe to remove: https://github.com/sunng87/diehard/blob/871137cc3530cd873597e536c9b581cd8a1b3924/src/diehard/core.clj#L83-L84