Open foggerty opened 1 year ago
Hey @foggerty,
Thanks for reporting this.
[edit]I realise that EasyNetQ has a lazy connection/retry model, but if the user-name is incorrect, no amount of retrying will make a difference. So a fix for this depends on the errors that RMQ returns when connecting.[/edit]
In the case of incorrect login/password, we could detect such a case, stop retrying and throw an exception.
For the case of incorrect hostname specified, I am afraid we should retry, because we can`t distinguish whether it is a transient error(a host is unavailable) or a permanent one(a wrong non-existing host is specified).
Doh, good point re hostname :-)
Describe the bug When EasyNetQ is unable to connect to RMQ (because, say, the user name is incorrect) it raises an exception with the message "A task was cancelled" instead of something indicating the problem.
[edit]I realise that EasyNetQ has a lazy connection/retry model, but if the user-name is incorrect, no amount of retrying will make a difference. So a fix for this depends on the errors that RMQ returns when connecting.[/edit]
To Reproduce
Expected behavior Any exception that arises because of a connection error, should clearly state so.
Please complete the following information):
7.4.1
]3.8.6
]Additional context This is in ,NET 6.