第一次更新超时 [英] First update times out

查看:110
本文介绍了第一次更新超时的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我们正在使用EF 4,RIA Services RC2,VS 2010和SQL 2008. 我们注意到第一次更新在RIA域服务Update方法完成之后以及在Designer.cs中获取getter之前超时

We're using EF 4, RIA Services RC2, VS 2010, and SQL 2008.  We've noticed that the first update times out just after the RIA domain service Update method finishes and before the getters fire in the Designer.cs

后续更新几乎立即返回。 第一次读取仅延迟几秒钟,但首先读取似乎对初始更新超时没有影响。 当然,我们可以推送RIA超时值,但这似乎不适合
必须在项目早期就这样做。 我怀疑edmx的第一次更新是罪魁祸首,但我找不到如何验证这是问题。 如果这是问题,应该有一些方法来避免延迟。

Subsequent updates return almost immediately.  The first read delays for only a few seconds, but reading first seems to have no effect on the initial update timeout.  Of course, we can push the RIA timeout value, but that doesn't seem right to have to do this early in the project.  I'm suspecting that the first hit on the edmx for the update is the culprit but I can't find how to verify that's the problem.  And if that is the issue, there should be some way to avoid the delay.

感谢任何想法/帮助!

---杰森

推荐答案

您好,

请按照以下建议设置上下文的CommandTimeout属性:< a href ="http://www.codeproject.com/KB/linq/LINQ2SQLCommandTimeout.aspx">
http://www.codeproject.com/KB/linq/LINQ2SQLCommandTimeout.aspx

Please set the CommandTimeout property of the context as suggested by: http://www.codeproject.com/KB/linq/LINQ2SQLCommandTimeout.aspx

关注


这篇关于第一次更新超时的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆