Underlying IOException in Azure Service Bus Topics

456 Views Asked by At

We're actively using Azure Service Bus topics in our application. Recently we started to get strange IOExceptions for some of our topics:

Microsoft.ServiceBus.Messaging.MessagingException The underlying connection was closed: An       unexpected error occurred on a send. TAsyncResult End[TAsyncResult](System.IAsyncResult) 
Server stack trace: 


Exception rethrown at [0]: 
   at Microsoft.ServiceBus.Common.AsyncResult.End[TAsyncResult](IAsyncResult result)
   at Microsoft.ServiceBus.NamespaceManager.OnEndTopicExists(IAsyncResult result)
   at Microsoft.ServiceBus.NamespaceManager.TopicExists(String path)
   at XXX.Core.Logic.Services.Bus.Impl.ServiceBusServiceBase.EnsureTopicExists(String topic)
   at XXX.Core.Logic.Services.Bus.Impl.ServiceBusSenderServiceImpl.SendBrokeredMessage(Object state)
________________________________________
System.Net.WebException The underlying connection was closed: An unexpected error occurred on a send. System.Net.WebResponse EndGetResponse(System.IAsyncResult)    at System.Net.HttpWebRequest.EndGetResponse(IAsyncResult asyncResult)
   at Microsoft.ServiceBus.Messaging.ServiceBusResourceOperations.GetAsyncResult`1.b__2d(GetAsyncResult`1 thisPtr, IAsyncResult r)
   at Microsoft.ServiceBus.Messaging.IteratorAsyncResult`1.StepCallback(IAsyncResult result)
________________________________________
System.IO.IOException Unable to read data from the transport connection: An existing connection was forcibly closed by the remote host. Void EndWrite(System.IAsyncResult)    at System.Net.TlsStream.EndWrite(IAsyncResult asyncResult)
   at System.Net.ConnectStream.WriteHeadersCallback(IAsyncResult ar)
________________________________________
System.Net.Sockets.SocketException An existing connection was forcibly closed by the remote host Int32 EndRead(System.IAsyncResult)    at System.Net.Sockets.NetworkStream.EndRead(IAsyncResult asyncResult)

For some topics this issue comes from time to time, but for some topics it is permanent. Same code is used for all topics all over application. We've tried different ways to workaround this - topic renaming, different code changes, but with no luck.

What could cause such kind of issues? Does anybody ever had such kind of stuff?

1

There are 1 best solutions below

0
On BEST ANSWER

Fortunately, we found an issue related to that in our project. The problem was in explicit SSLv3 that we applied in our code. After Azure deactivated SSLv3 on Service Bus service our code broken.

Good lesson here: never use explicit protocols project wide.