使用与状态服务器相同的服务器的同一 asp.net 应用程序的两个版本 - 不好?

发布于 2024-08-29 14:06:16 字数 538 浏览 1 评论 0原文

我们的 Web 应用程序有 2 个生产 Web 服务器,负载均衡以处理大量流量。

我们也有类似的测试设置。

Test pool:    [TEST 1]---[TEST 2] 

Prod pool:    [PROD 1]---[PROD 2]

在比较应用程序版本(测试与实时)的 Web.Config 时,我发现了一些令人惊讶的事情:两个池的 stateConnectionString 值相同。如果我理解正确,这意味着他们使用相同的状态服务器:

<sessionState 
mode="StateServer" 
stateConnectionString="tcpip=123.123.123.123:42424"
cookieless="false" 
timeout="30"/>

这是一个问题吗?(状态服务器如何不混淆两个池)?

我只是在测试服务器上遇到了奇怪的情况——有时会出现速度减慢/错误,这就是我首先考虑这个问题的原因,但产品池运行良好......

We have 2 production web servers for our web app, load balanced to handle lots of traffic.

We also have a similar setup for testing.

Test pool:    [TEST 1]---[TEST 2] 

Prod pool:    [PROD 1]---[PROD 2]

When comparing the Web.Config of the app versions (test vs live) I discovered something surprising: both pools have the same value for stateConnectionString. If I understand right, this means they are using the same state server:

<sessionState 
mode="StateServer" 
stateConnectionString="tcpip=123.123.123.123:42424"
cookieless="false" 
timeout="30"/>

Is this a problem? (How does the state server not confuse the two pools)?

I was having odd only-sometimes slowdown/errors on the test server, that's why I was looking at this in the first place, but the prod pool runs fine...

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

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

发布评论

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

评论(1

情愿 2024-09-05 14:06:16

这实际上意味着服务器 123.123.123.123 是网络场中所有服务器的所有共享状态的单一来源。

从概念上讲,这与将状态存储在集中式数据库中没有什么不同,只不过在这种情况下,状态全部存储在内存中的一台服务器上,而不是数据库中。

我认为它本身没有任何问题

What this really means is that server 123.123.123.123 is the single source of all shared state for all servers on the web farm.

It's no different conceptually than storing the state in a centralized database, except in this case it's all stored on that one server in memory, and not a database.

I don't see anything wrong with it, per se..

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