我们可以在Jmeter的单个测试计划中并行运行两个线程组吗?

问题描述:

我们可以通过在Jmeter中创建一个测试计划来并行运行两个线程组吗?

can we run two thread groups parallel by creating a single test plan in Jmeter ??

示例:

我必须在一个测试计划中添加2个测试用例,这些测试用例必须并行执行,并且我们可以将此测试计划与任何其他要同时执行的测试计划相结合

I have to add 2 test cases in a test plan, which has to be executed in parallel and can we combine this test plan with any other test plan to be executed simultaneously

Jmeter支持在同一测试计划中并行运行多个场景.

Jmeter supports running more than one scenario in parallel as part of the same test plan.

每个方案都在其自己的线程组元素中进行管理.

Each scenario is managed in its own Thread Group element.

因此,根据您的情况,在测试计划中添加一个新的线程组,并在那里设置第二种方案的步骤.如果线程组超过1个,则可以配置测试计划以同时(或一个接一个)启动它们.

So for your case, add a new Thread Group to the test plan, and set the steps for the second scenario there. When you have more than 1 Thread Group, you can configure the test plan to start them at the same time (or one after the other).

不能保证请求会在同一时间进行,但是两个线程组将同时启动.

There is no guarantee that the requests will be in the exact same time, but both Thread Groups will start simultaneously.

希望它会有所帮助:)