确定 Web 应用程序支持的用户数量
我正在开发一个面向企业客户的 ASP.NET Web 应用程序。 谁能提供一些关于如何确定我的应用程序可以支持的用户数量的指南?
此外,该应用程序使用会话变量,因此目前仅限于一台 Web 服务器,直到情况发生变化。
I'm developing an asp.net web application targeted to business customers. Can anyone provide some guidelines on how I can determine the number of users my application can support?
Also, the application uses session variables so its currently limited to one web server until that changes.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(5)
只有您/您的团队才能确定可以支持的确切数量。
此处的关键是深入了解您的问题域以及处理层的明显分离。
这种分离使您能够隔离瓶颈,并更轻松地调整最低性能因素的性能,然后继续处理下一层/性能限制。
不要做出假设,因为您会发现与您的假设无关的影响可能会让您感到惊讶。
这是我用来衡量设计质量的痛苦因素之一 - Plan All I增量需要并已在其他地方和博客中讨论过。
就我个人而言,我经常根据性能做出设计决策,但您的营销策略可能会有所不同。
Only you/your team can determine the exact numbers that can be supported.
Your key to here is having a deep understanding of your problem domain and a distinct separation of the processing layers.
The separation allows you to isolate the bottlenecks, and tune the performance of the lowest performance factor much more easily, then move on to the next layer/performance limitation.
Do not make assumptions, as you will find impact unrelated to your assumptions that might surprise you.
This is one of the PAIN factors that I use to measure quality in designs – Plan All Incremental Needs and have discused elsewhere and in blogs.
Personally, I will often make decisions on design based on performance, but your marketing strategy might differ.
所以您知道,只需将会话移至 SQL Server 数据库,就可以非常简单地使会话与多个 Web 服务器一起使用。
此处提供了快速操作方法
至于您最初的问题,我会研究负载测试。 希望还有其他发帖者对此有更多了解。 我会关注页面浏览量,而不是用户。
So you know, session can be made to work with multiple web servers very simply by moving it out to a sql server database.
A quick how to is available here
As for your original question, I would look into load testing. Hopefully there will be other posters who know more about that. I would focus on page views, as opposed to users.
测量应用程序中典型操作所需的资源(CPU、内存、磁盘、带宽)。 将可用资源除以代表性用户“会话”所需的资源,您就会得到一个粗略的数字。
在获得一组良好的真实数据之前,您必须猜测典型的使用习惯和资源需求。 这就是您在第一次估算容量时所能做的全部事情。
Measure the resources (CPU, memory, disk, bandwidth) needed for typical actions within your application. Divide available resources by resources needed for a representative user "session" and you have a rough number.
Until you have a good set of real data, you'll have to make guesses about typical usage habits and the resource requirements. That's about all you can do for a 1st pass at estimating capacity.
一个好的负载均衡器可以确保用户返回到同一台服务器。
A good load balancer can ensure that a user will return to the same server.
您可以使用在第二个机器上运行的会话状态服务器或 SQL Server 支持的会话来解决单个机器问题。
至于手头的问题,除了获得生产硬件、设置应用程序并运行负载测试,直到找出她的故障点之外,没有真正的方法可以确定。 这不一定会给您真实的数字,因为您必须假设用户正在做什么,并且几乎不可能在测试环境中模拟网络云的影响。
You can use a session state server running on a second box or sql server backed sessions to get around the single box issue.
As for the question at hand, there is no real way to determine that besides getting your hands on production hardware, setting up the app and running load tests until you can figure out where she breaks. This won't necessarily give you the real number as you have to make assumptions about what the users are doing and it is pretty much impossible to simulate the effects of the network cloud in test environments.