问题描述
我有一个节点服务,该服务通过SSE( https://www.npmjs.com /package/sse-channel ).我想通过建立"n"个并发连接对该服务进行负载测试,我尝试了"loadtest" npm模块,但是由于我们正在处理流式响应,因此我无法报告任何数据,如每秒请求数,平均等待时间等.发出流请求,是否有办法使用"loadtest"模块提供流服务,如果不能有人将我指向在发出并发流请求时会报告状态的模块.
I have a node service that streams data via SSE (https://www.npmjs.com/package/sse-channel). I would like to loadtest this service my making 'n' concurrent connections, i tried the "loadtest" npm module but since we are dealing with streaming responses i was not able to report back any data like requests per second, mean latency etc… when the streaming requests are made, is there a way to use "loadtest" module for streaming services if not can someone point me to the module that would report back status while making concurrent streaming requests.
推荐答案
加特林( http://gatling.io/# /)支持SSE( http://gatling.io/docs/2.2.2/http/sse.html ).它不在js中,而是Scala.但是,编写针对SSE服务器的方案非常简单.
Gatling (http://gatling.io/#/) has support for SSE (http://gatling.io/docs/2.2.2/http/sse.html). It's not in js, it's Scala. But, it's quite simple to write a scenario that targets a SSE server.
这篇关于如何对服务器发送的事件进行负载测试的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!