You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
There is something funky going on on .net framework when receiving messages, when there is nothing buffered in the queue. From my testing there seems to be about 1 second delay between the message being send from service A, to it being received in service B, provided service B is a .net framework application. I have not observed the same behavior on .net core.
Looking at the code in this library, the transport has a timeout of 2 seconds when receiving messages, which i what i suspect .net framework always waits, worst case scenario. I suspect it's the SharedQueue that doesn't notify the callling code that a new message has been received, causing the delay.
I have not done any carefull measures, but looking at the traces emitted from Rebus.OpenTelemetry, it certainly seems to be the case. I have tested everything on the same host, including Rabbit, so it really shouldn't be a network issue.
The text was updated successfully, but these errors were encountered:
The SharedQueue implementation found in the codebase of Rebus.RabbitMq comes from an older version of RabbitMq.Client, so it's basically something that was ported forward when it was removed from the official driver NuGet package.
I can see it's using DateTime.Now in its implementation of the timeout..... I would not believe that that could cause the behavior you're experiencing, but just for kicks I've changed it to use a Stopwatch instead. I've released it as Rebus.RabbitMq 7.3.1-b3 – could you try it and see if that makes a difference?
There is something funky going on on .net framework when receiving messages, when there is nothing buffered in the queue. From my testing there seems to be about 1 second delay between the message being send from service A, to it being received in service B, provided service B is a .net framework application. I have not observed the same behavior on .net core.
Looking at the code in this library, the transport has a timeout of 2 seconds when receiving messages, which i what i suspect .net framework always waits, worst case scenario. I suspect it's the
SharedQueue
that doesn't notify the callling code that a new message has been received, causing the delay.I have not done any carefull measures, but looking at the traces emitted from Rebus.OpenTelemetry, it certainly seems to be the case. I have tested everything on the same host, including Rabbit, so it really shouldn't be a network issue.
The text was updated successfully, but these errors were encountered: