javascript - Constant load (x new requests per second) - Stack Overflow

Is there a way to to configure a performance test case with constant load (say, 3 new requests per seco

Is there a way to to configure a performance test case with constant load (say, 3 new requests per second for 1 minute)?

Other load testing libraries have this feature to set the request rate (e.g. Artillery.io, Vegeta). k6 has a way to set VUs, but VU does not make a new request until the previous iteration is finished.

Is there a way to to configure a performance test case with constant load (say, 3 new requests per second for 1 minute)?

Other load testing libraries have this feature to set the request rate (e.g. Artillery.io, Vegeta). k6 has a way to set VUs, but VU does not make a new request until the previous iteration is finished.

Share Improve this question edited Dec 19, 2017 at 12:23 user1010 asked Dec 19, 2017 at 11:52 user1010user1010 3791 gold badge5 silver badges19 bronze badges
Add a ment  | 

2 Answers 2

Reset to default 7

k6 actually has this feature now, in the master branch (https://github./loadimpact/k6/issues/211 was closed 5 days ago) - either you can download and pile master (go get github./loadimpact/k6 if you have Go installed) or you can just wait a little and it will be in the next release. Shouldn't take more than a week or so before we make a new release.

You use the RPS limiter feature by adding the rps parameter, either on the mand line as an option to the run mand: k6 run --rps 100 ... or as options.rps:

export let options = { vus: 50, rps: 100 }

Note that this feature is just limiting the max RPS rate k6 will produce. If you use too few VU threads you will not reach the desired RPS rate. Exactly how many VUs you'll need to use depends on how fast transactions plete. That, in turn, is dependent on network delay and server processing time. In general, using 100-200 VU should cover most mon situations.

As of k6 v0.27, there is now native support for constant arrival rates, aka. constant request rate. In the following article, I have explained how to generate a constant request rate in k6 with the new scenarios API:

How to generate a constant request rate in k6 with the new scenarios API?

发布者:admin,转转请注明出处:http://www.yc00.com/questions/1744294575a4567198.html

相关推荐

  • javascript - Constant load (x new requests per second) - Stack Overflow

    Is there a way to to configure a performance test case with constant load (say, 3 new requests per seco

    7天前
    60

发表回复

评论列表(0条)

  • 暂无评论

联系我们

400-800-8888

在线咨询: QQ交谈

邮件:admin@example.com

工作时间:周一至周五,9:30-18:30,节假日休息

关注微信