Is it expected that SQLAzure is unavailable from time to time?

限于喜欢 提交于 2019-12-12 02:16:34

问题


I am connecting to SQLAzure from my Azure service.

Most of the time, things work fine.

However, once in a while (about once a day), I am unable to connect. It lasts about 5 minutes.

I get the following error:

SQLException: A network-related or instance-specific error occurred while establishing a connection to SQL Server

Is this to be expected?

Is it part of cloud programming?

Am I supposed to program defensively against it?


回答1:


Yes, this is expected. It is expected in your connections and commands you build some kind of retry logic. How hard this is depends on your data layer.

There is lots of info on google https://www.google.com/search?q=sql+azure+transient

Entity Framework - SQL Azure Retry Policy




回答2:


This type of behavior is expected for SQL Azure and as well as for other cloud services. Microsoft provides the Transient Fault Application Block which includes robust transient fault handling logic for various Azure services, including SQL Azure.



来源:https://stackoverflow.com/questions/11976118/is-it-expected-that-sqlazure-is-unavailable-from-time-to-time

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!