我们有一个Windows Azure应用程序(Lokad.CQRS架构),可与多个第三方系统集成。其中一个集成发生在mySQL上。一切都很顺利,但最近我们有一个Windows Azure应用程序无法连接的mySQL数据库,导致超时。
这是相关的堆栈跟踪:
System.TimeoutException: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond --->
System.IO.IOException: Unable to read data from the transport connection: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond. --->
System.Net.Sockets.SocketException: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond
at System.Net.Sockets.NetworkStream.Read(Byte[] buffer, Int32 offset, Int32 size)
--- End of inner exception stack trace ---
at System.Net.Sockets.NetworkStream.Read(Byte[] buffer, Int32 offset, Int32 size)
at MyNetworkStream.Read(Byte[] buffer, Int32 offset, Int32 count)
--- End of inner exception stack trace ---
at MyNetworkStream.HandleOrRethrowException(Exception e)
at MyNetworkStream.Read(Byte[] buffer, Int32 offset, Int32 count)
at MySql.Data.MySqlClient.TimedStream.Read(Byte[] buffer, Int32 offset, Int32 count)
at System.IO.BufferedStream.Read(Byte[] array, Int32 offset, Int32 count)
at MySql.Data.MySqlClient.MySqlStream.ReadFully(Stream stream, Byte[] buffer, Int32 offset, Int32 count)
at MySql.Data.MySqlClient.MySqlStream.LoadPacket()
at MySql.Data.MySqlClient.MySqlStream.ReadPacket()
at MySql.Data.MySqlClient.NativeDriver.Open()
at MySql.Data.MySqlClient.Driver.Open()
at MySql.Data.MySqlClient.Driver.Create(MySqlConnectionStringBuilder settings)
at MySql.Data.MySqlClient.MySqlConnection.Open()
重要亮点:
我们通过Windows Azure以各种设置和配置(Linux / Windows托管的数据库服务器)从Lokad.CQRS开始使用Oracle,MS SQL,mySQL和PostgreSQL连接。但是这个特定的mySQL案例让我感到困惑。
对可能导致问题的原因有什么猜测?
答案 0 :(得分:0)
解决方案:
由于某些原因,Azure Production Fabric在连接到目标数据库时增加了太多的延迟,因此总是超时。来自欧洲附近机器的相同连接从未打破连接超时。
增加此特定情况的连接超时(按5x)确实解决了这种情况,并没有为分布式系统的其余部分增加太多风险。
可能问题出在NE DC的网络配置,路由器故障等等。
答案 1 :(得分:0)
由于我们想要跟踪此问题并帮助确保我们在Windows Azure上运行的oss应用程序没有任何问题,我只是强烈要求您提出一系列问题。如果你没有看到,请告诉我。