简体   繁体   English

ASP.NET客户端和ASP.NET WCF Server生产更新过载

[英]ASP.NET Client and ASP.NET WCF Server production update overload

We have a WCF Server with all the business logic, and a MVC client who get all data, including news and images, from this server. 我们有一个具有所有业务逻辑的WCF服务器,以及一个MVC客户端,该客户端从该服务器获取所有数据,包括新闻和图像。

The problem is when I have to update the server, the constant access the client overloads the server with calls, and it can't go up. 问题是当我必须更新服务器时,客户端的持续访问会使服务器超载调用,并且无法启动。 In the end all available memory is consumed and the server does not start. 最后,所有可用内存被消耗,服务器无法启动。

If I stop the client, start the server, then after it is loaded (relatively fast) I start the client, it works fine. 如果我停止客户端,请启动服务器,然后在加载它(相对较快)后,我启动客户端,它可以正常工作。

I use ISS with Windows Server 2013, and MVC 4.5 我在Windows Server 2013和MVC 4.5中使用ISS

You have to build a 'temporary off-line' checker in your app. 您必须在应用程序中构建“临时离线”检查器。

If you experience X errors in Y time, wait for a few seconds, and then try again. 如果您在Y时间内遇到X错误,请等待几秒钟,然后重试。 Increase the waiting time over the number of tries. 增加尝试次数的等待时间。

In this way, you prevent the server to get overloaded. 这样,可以防止服务器过载。 And your client will resume as soon as the service is ready. 服务准备就绪后,您的客户将立即恢复。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM