What are the exceptions worth retrying (the one representing transient errors) when IModel.BasicPublish fails ? #1083
Replies: 1 comment
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hello,
I've already tried to ask this same question on both stackoverflow and the Google user group. An interesting discussion has started in stackoverflow, but I still have no clear plan to proceed.
To summarize, my scenario is the following:
IModel.BasicPublish
when the connection is down will result in errors and the driver leaves the handling of this scenario to the developer (re delivery of messages is not automatically attempted by the driver itself)We are struggling with identifying the exceptions thrown by
IModel.BasicPublish
which represent transient errors and so are worth retrying. We know that all the exceptions thrown by the driver derive from RabbitMQClientException and are defined in theRabbitMQ.Client.Exceptions
namespace.It seems to us that, among all the client defined exceptions, only
BrokerUnreachableException
,ConnectFailureException
andOperationInterruptedException
are worth retrying. All the others seem to be related with errors which are not transient in nature.As an interesting sidenote the Microsoft microservice architecture sample application has a retry policy similar to the one we would like to define. They retry on both
BrokerUnreachableException
andSocketException
. See here.Can you please provide some guidance on this topic ?
Many thanks for helping.
Beta Was this translation helpful? Give feedback.
All reactions