Differentiate between error codes in microservices/dead-letters
It would be nice to have the possibility to be able to differentiate between different errors in microservices and have different strategies for retrying based on the response. For example if an api is unreachable it would make sense to retry the entities for a longer time period than if there's an error in the entity which could be immediately marked as dead.
What I would like to is to configure different write_retry_delay and max_retries_per_entity for different http status codes like this:
400-428,431-499: 0 delay, 0 retries // error in entity
429: 30sec delay, 100 retries // try again later
500-599: 60 sec delay 100 retries // system unreachable, try until it works but wait longer
default: 30 sec delay, 3 retries
This way I could control the retry strategy based on knowledge I have in the microservice.
Please sign in to leave a comment.
Comments
0 comments