加入收藏 | 设为首页 | 会员中心 | 我要投稿 李大同 (https://www.lidatong.com.cn/)- 科技、建站、经验、云计算、5G、大数据,站长网!
当前位置: 首页 > 编程开发 > asp.Net > 正文

asp.net-mvc – 在ASP.NET MVC3中有一个无会话控制器的情况是什

发布时间:2020-12-16 00:27:30 所属栏目:asp.Net 来源:网络整理
导读:读 Guru-Gu’s blog post about ASP.NET MVC3 hitting RC他说: Session-less Controller Support You can now indicate whether you want a Controller class to use session-state – and if so whether you want it to be read/write or readonly.read/wr
读 Guru-Gu’s blog post about ASP.NET MVC3 hitting RC他说:

Session-less Controller Support

You can now indicate whether you want a
Controller class to use session-state
– and if so whether you want it to be
read/write or readonly.read/write or readonly.

有人可以解释一些情景有人想要拥有无会话控制器吗?或只读控制器?

我一直在创造一个separate IIS website which I use to handle all static images/content and then have this same website have session state turned off …所以没有饼干通过电线发送。这是一个类似的场景吗?

解决方法

顾评论了这一点。引用:

The release notes cover this more (you
can download them from the download
link above). Session state is
designed so that only one request from
a particular user/session occurs at a
time. So if you have a page that has
multiple AJAX callbacks happening at
once they will be processed in serial
fashion on the server. Going
session-less means that they would
execute in parallel.

这是ASP.NET中一个已知的场景。同一用户的会话对象不是线程安全的。这意味着如果同一个用户(相同的会话id cookie)向使用会话的页面发送多个请求,那么这些请求将被排队并且将被并行处理,而不是并行处理。

(编辑:李大同)

【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容!

    推荐文章
      热点阅读