WCF-RIA 服务客户端 OutputCache - 无法在具有 localhost 的 IE 中工作

发布于 2024-11-30 04:22:18 字数 420 浏览 3 评论 0原文

我们在项目中使用 WCF-RIA 服务。 部分是搜索,它将触发服务器上的 RIA 请求。

对于此请求,我们使用此属性启用了客户端输出缓存:

[OutputCache(OutputCacheLocation.Client, duration: 2 * 60)]

我们希望使用客户端缓存,因为要缓存的信息是特定于用户的。问题是,在 IIS 中安装应用程序后,缓存在 Firefox 和 IE 中工作正常,但在调试时 IE 似乎忽略了缓存。

也许这并不是 RIA 服务特定的问题,而更多的是 IE 问题。看起来 IE 看​​到“嘿,这是对本地主机的请求,我不想缓存它”(某种功能)。

这有点无益,因为调试情况与“实时”情况不同。

有没有办法在调试时在 IE 中使用 WCF-RIA 服务客户端缓存?

We are using the WCF-RIA Services in our project.
On part is a search which will trigger a RIA request on the server.

For this request we have enabled the Client output cache using this attribute:

[OutputCache(OutputCacheLocation.Client, duration: 2 * 60)]

We want to use the client cache, because the information to be cached are user specific. The problem ist, that the cache works fine in Firefox and IE after the application is installed in an IIS, but while debugging IE seems to ignore the caching.

Maybe this is not really a RIA Service specific problem but more of an IE problem. It looks as IE sees "Hey, this is a request to localhost, I don't want to cache that" (some kind of feature).

This is a bit unhelpful, because the debugging situation is not the same as the "live" situation.

Is there a way to use the WCF-RIA Services client cache in IE while debugging?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

來不及說愛妳 2024-12-07 04:22:18

您应该能够使用 URL 中的计算机名称或使用 localhost 进行测试。 (注意末尾的点)而不是 localhost。 请参阅此处了解更多信息

一旦你让它与 Fiddler 一起工作,你应该能够看到你的缓存是打开还是关闭并调试它。

You should be able to test this using either your machine name in the URL or using localhost. (note the dot at the end) instead of localhost. See here for more info.

Once you have it working with Fiddler you should be able to see if your caching is on or off and debug it.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文