rebus-org / Rebus.RabbitMq

:bus: RabbitMQ transport for Rebus
https://mookid.dk/category/rebus
Other
65 stars 45 forks source link

Connection issue when run long-lived service #81

Closed volethanh closed 3 years ago

volethanh commented 3 years ago

Hi,

I've got this issue when I use Rebus.RabbitMq in WebAPI (.NET 5).

I run my WebAPI for several days and suddenly the connection between WebAPI and RabbitMq is shutdown. When I restarted, it ran again and it would stop for several days.

This is my log when the service is stop and I only know when I try call the API

Screen Shot 2021-06-17 at 11 50 51 AM
mookid8000 commented 3 years ago

Hmm that's weird. Are you using the latest Rebus.RabbitMq?

As far as I know, the RabbitMq.Client driver should be able to resolve connection issues by itself since this property is set.... 🤔

volethanh commented 3 years ago

I'm using the latest Rebus.RabbitMq and I always get error.

Screen Shot 2021-07-02 at 10 41 38 AM

The workaround is restart the web or the service but it will cause error again

mookid8000 commented 3 years ago

OK so it never recovers, when that error has shown up?

mookid8000 commented 3 years ago

Could you try Rebus.RabbitMq 7.3.1-b7 and see if it makes a difference?

mookid8000 commented 3 years ago

Hi again @volethanh , I think there has been several improvements in this area, the latest being Rebus.RabbitMq 7.3.1-b11

Could you maybe try it and see if it fixes your problem?

volethanh commented 3 years ago

Hi again @volethanh , I think there has been several improvements in this area, the latest being Rebus.RabbitMq 7.3.1-b11

Could you maybe try it and see if it fixes your problem?

sorry for late reply, ok @mookid8000 , I will try that version to see if it fixed.

Right now, I modified a bit by using Polly for retry mechanism and this work properly.