[英]Is the throughput value related to the response time of requests in JMeter?
I'm getting the following results, where the throughput does not have a change, even when I increase the number of threads. 我得到以下结果,即使增加线程数,吞吐量也没有变化。
Scenario#1: 方案1:
Number of threads: 10 线程数:10
Ramp-up period: 60 准备阶段:60
Throughput: 5.8/s 吞吐率:5.8 / s
Avg: 4025 平均:4025
Scenario#2: 情景2:
Number of threads: 20 线程数:20
Ramp-up period: 60 准备阶段:60
Throughput: 7.8/s 吞吐率:7.8 / s
Avg: 5098 平均:5098
Scenario#3: 情景3:
Number of threads: 40 线程数:40
Ramp-up period: 60 准备阶段:60
Throughput: 6.8/s 吞吐率:6.8 / s
Avg: 4098 平均:4098
The my JMeter file consists of a single ThreadGroup that contains a single GET. 我的JMeter文件由一个包含单个GET的ThreadGroup组成。
When I perform the request for an endpoit where the response time faster (less than 300 ms) I can achieve throughput greater than 50 requests per seconds. 当我执行响应速度更快(小于300毫秒)的端对端请求时,我可以获得的吞吐量大于每秒50个请求。
Can you see the bottleneck of this? 您能看到这个瓶颈吗?
Is there a relationship between response time and throughput? 响应时间和吞吐量之间有关系吗?
In ideal world if you increase number of threads by factor of 2x - throughput should increase by the same factor. 在理想情况下,如果将线程数增加2倍,则吞吐量应增加相同的倍数。
In reality the "ideal" scenario is hardly achievable so it looks like a bottleneck in your application. 实际上,“理想”方案是无法实现的,因此它看起来像是应用程序中的瓶颈。 The process of identifying the bottleneck normally looks as follows:
识别瓶颈的过程通常如下所示:
Once you figure out what is the saturation point you need to know what prevents your application from from serving more requests, the reasons could be in: 一旦确定了饱和点 ,就需要知道是什么阻止了您的应用程序处理更多请求,其原因可能是:
It's simple as JMeter user manual states: 正如JMeter用户手册所述,这很简单:
Throughput = (number of requests) / (total time)
吞吐量=(请求数)/(总时间)
Now assuming your test contains only a single GET then Throughput will be correlate average response time of your requests. 现在假设您的测试仅包含一个GET,那么吞吐量将与您请求的平均响应时间相关。
Notice Ramp-up period: 60 will start to create threads over 1 minute, so it will add to total time of execution, you can try to reduce it to 10 or equal to Number of threads. 注意加速期:60将在1分钟内开始创建线程,因此它将增加总的执行时间,您可以尝试将其减少到10或等于线程数。
But you may have other sampler/controllers/component that may effect total time. 但是您可能还有其他采样器/控制器/组件可能会影响总时间。
Also in your case especially in Scenario 3, maybe some requests failed then you are not calculating Throughput of successful transactions. 同样在您的情况下,尤其是在方案3中,也许某些请求失败了,那么您就没有在计算成功事务的吞吐量。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.