dtm-labs/dtm

性能测试和文档内描述的差距较大

Fort50 opened this issue · 1 comments

Fort50 commented

本地Docker部署的Redis,dtm运行在宿主机

Redis测试

redis-benchmark -n 300000 SET 'abcdefg' 'ddddddd'

24746.35 requests per second

本地测试dtm:

LOG_LEVEL=warn go run bench/main.go redis
ab -n 100000 -c 10 "http://127.0.0.1:8083/api/busi_bench/benchEmptyUrl"

Finished 100000 requests

Server Software:
Server Hostname:        127.0.0.1
Server Port:            8083

Document Path:          /api/busi_bench/benchEmptyUrl
Document Length:        4 bytes

Concurrency Level:      10
Time taken for tests:   192.606 seconds
Complete requests:      100000
Failed requests:        0
Total transferred:      11100000 bytes
HTML transferred:       400000 bytes
Requests per second:    519.19 [#/sec] (mean)
Time per request:       19.261 [ms] (mean)
Time per request:       1.926 [ms] (mean, across all concurrent requests)
Transfer rate:          56.28 [Kbytes/sec] received

Connection Times (ms)
              min  mean[+/-sd] median   max
Connect:        0   12 303.9      0   20100
Processing:     3    7  26.6      5    1264
Waiting:        3    7  26.6      5    1264
Total:          3   19 306.1      5   20107

Percentage of the requests served within a certain time (ms)
  50%      5
  66%      6
  75%      6
  80%      6
  90%      7
  95%      8
  98%     13
  99%     32
 100%  20107 (longest request)

和文档中提到的测试结果差距较大

yedf2 commented

文档的测试结果是很明确,也是可以复现的。

你的测试是本地走docker的,性能会比生产使用的高配置差很多,所以性能差距巨大很正常