有什么好的自动化 Web 负载测试工具建议吗?

发布于 2024-09-03 19:17:54 字数 680 浏览 4 评论 0原文

有哪些用于负载测试(压力测试)Web 应用程序的优秀自动化工具,它们使用 HTTP 网络数据包的记录和重放?

我知道市场上有许多负载测试工具可以记录和重放 HTTP 网络数据包。但这些不适合我的目的,因为:

  • HTTP 数据包格式在我们的应用程序中经常更改(例如,当 我们优化了 AJAX 调用)。我们不想仅仅因为 HTTP 数据包格式略有变化。

  • 我们的测试团队不需要了解有关我们应用程序的任何内部信息 编写他们的测试脚本。然而,重放 HTTP 数据包的工具需要 团队了解 HTTP 请求和响应的格式,以便他们 可以调整重放的 HTTP 数据包的详细信息(例如用户名)。

我正在寻找的自动化负载测试工具应该能够让测试团队编写“黑盒”测试脚本,例如:

  • 在 URL http://... 处调用网页。
  • 首先,在文本字段XXX中输入XXX
  • 然后,按XXX按钮。
  • 等待直到从网络服务器收到响应。
  • 验证文本字段 XXX 现在包含文本 XXX

该工具应该能够模拟多达 1000 个用户,并且应该与使用 ASP.NET 和 AJAX 的 Web 应用程序兼容。

What are some good automated tools for load testing (stress testing) web applications, that do not use record and replay of HTTP network packets?

I am aware that there are numerous load testing tools on the market that record and replay HTTP network packets. But these are unsuitable for my purpose, because of this:

  • The HTTP packet format changes very often in our application (e.g. when
    we optimize an AJAX call). We do not want to adapt all test scripts just because
    there is a slight change in HTTP packet format.

  • Our test team shall not need to know any internals about our application
    to write their test scripts. A tool that replays HTTP packets, however, requires
    the team to know the format of HTTP requests and responses, such that they
    can adapt details of the replayed HTTP packets (e.g. user name).

The automated load testing tool I am looking for should be able to let the test team write "black box" test scripts such as:

  • Invoke web page at URL http://... .
  • First, enter XXX into text field XXX.
  • Then, press button XXX.
  • Wait until response has been received from web server.
  • Verify that text field XXX now contains the text XXX.

The tool should be able to simulate up to several 1000 users, and it should be compatible with web applications using ASP.NET and AJAX.

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

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

发布评论

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

评论(5

唔猫 2024-09-10 19:17:54

我发现 JMeter 非常有用,它还具有记录功能来记录用例,因此您不必手动指定每个 GET/POST,而是“单击”用例一次,然后让 JMeter 重复它。< br>
http://jmeter.apache.org/

JMeter I've found to be pretty helpful, it also has a recording functionality to record use cases so you don't have to specify each GET/POST manually but rather "click" the use case once and then let JMeter repeat it.
http://jmeter.apache.org/

送舟行 2024-09-10 19:17:54

许可证可能很昂贵(如果您没有 MSDN),但 Visual Studio 2010 Ultimate 版本有一组很棒的负载和压力测试工具,可以执行您所描述的操作。 您可以尝试一下此处免费 90 天。

A license can be expensive for it (if you dont have MSDN), but Visual Studio 2010 Ultimate edition has a great set of load and stress testing tools that do what you describe. You can try it out for free for 90 days here.

空城仅有旧梦在 2024-09-10 19:17:54

PushToTest.com 的 TestMaker 可以运行录制的脚本,例如 Selenium 以及许多不同的语言,例如 HTML、Java、Ruby、Groovy、.Net、VB、PHP 等。它具有通用的报告基础架构,您可以在测试中创建负载实验室或使用 EC2 等云测试环境进行虚拟测试实验室。

他们每月提供有关使用开源测试工具的免费网络研讨会,下周二有一次。

http://www.pushtotest.com

TestMaker by PushToTest.com can run recorded scripts such as Selenium as well as many different languages like HTML, Java, Ruby, Groovy, .Net, VB, PHP, etc. It has a common reporting infrastructure and you can create load in your test lab or using cloud testing environments like EC2 for virtual test labs.

They provide free webinars on using open source testing tools on a monthly basis and there is one next Tuesday.

http://www.pushtotest.com

温柔戏命师 2024-09-10 19:17:54

有几种方法;然而,我曾经遇到过这样的情况,我不得不推出自己的负载生成实用程序。

就您的测试脚本而言,它涉及:

  • 发送 GET 请求到 http://表单输入页面(仅检查是否给出 200 响应)
  • 发送 POST 请求到 http://< i>表单提交页面,其中包含文本 XXX 的预先生成的键/值对,并对响应执行正则表达式检查

除非您的网页是复杂的 AJAX,否则不需要“模拟按下按钮” - 这是采取的由 POST 请求处理。

鉴于您的测试仅包含一个两步过程,应该有几个自动加载包可以做到这一点。

我之前曾使用 httperf 对大型网站进行负载测试:它可以模拟由多个请求组成的会话,可以同时模拟大量用户(即会话)。例如,如果您的网站从主页生成了一个会话 cookie,您可以发出第一个请求,httperf 将使用该 cookie 进行后续请求,直到完成提供的请求列表。

There are a few approaches; I've been in situations, however, where I've had to roll my own load generating utilities.

As far as your test script is concerned it involves:

  • sending a GET request to http://form entry page (only checking if a 200 response is given)
  • sending a POST request to http://form submit page with pre-generated key/value pairs for text XXX and performing a regexp check on the response

Unless your web page is complex AJAX there is no need to "simulate a button press" - this is taken care of by the POST request.

Given that your test consists of just a 2-step process there should be several automated load packages that could do this.

I've previously used httperf for load testing a large website: it can simulate a session consisting of several requests and can simulate a large number of users (i.e. sessions) simultaneously. For example, if your website generated a session cookie from the home page you could make that the first request, httperf would then use that cookie for subsequent requests, until it had finished doing the list of requests supplied.

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