出现通过使用自定义视图状态提供哪些陷阱?自定义、视图、陷阱、状态

2023-09-06 22:19:53 作者:三重梦i@

我最近开始研究如何使用自定义的视图状态提供从页面移动存储视图状态的服务器。这样做的明显优势是减少呈现页面大小,因此,增加了用户体验。另外,据我所知,最大的缺点是服务器的内存使用量将增加。对于这个问题,我可以除此之外存储轻松地移动到不同的服务器的Web服务器(AppFabric的,例如),有可能出现的还有其他的陷阱?是否有其中一个会使用正常的视图​​状态提供者,而不是一个自定义的视图状态的供应商?情况

I have recently started researching how to use a custom view-state provider to move storage of viewstate from the page to the server. The obvious advantage of this is reducing the rendered page size and thus, increasing the user experience. Also, the biggest disadvantage that I know of is that server memory usage will increase. For this issue I can easily move the storage to a different server than the web server (AppFabric, for example) Besides this, are there other pitfalls that may arise? Are there situations where one would use the normal view state provider and not a custom view state provider?

我希望我的问题是清楚的。

I hope my question is clear.

谢谢!

推荐答案

最近我没有在我的应用程序,但我仍然没有得到任何问题,这样做的。

Recently I did in my application but still I have not get any issue doing so.

不过移动,以保持自定义视图状态之前,你必须要考虑用户的流量。如果流量高,那么我不会建议保持视图状态在服务器上。在这种情况下,你必须考虑,以提高应用程序的性能的其他方式。

But before moving to maintain custom Viewstate, you have to think User traffic. If traffic is high then I would not recommend to maintain Viewstate on server. In that case you have to consider other way to improve performance of your application.

对此非常好的文章保持ViewState中出的页面