This commit is contained in:
2026-03-17 17:36:29 +08:00
parent e7dd712164
commit dbd677ede4
20 changed files with 102 additions and 592737 deletions
@@ -1,177 +0,0 @@
# 压测报告
生成时间: 2026-03-17 15:36:32
服务地址: http://localhost:8080
## 测试概览
| 测试项目 | 状态 | 结果文件 |
|---------|------|---------|
| 任务幂等性 | test-2.1-task-idempotent_20260317_153327.json |
| 消息幂等性 | test-2.2-message-idempotent_20260317_153327.json |
| 点赞方案A | |
| 点赞方案B | |
## 详细结果
### test-2.1-task-idempotent_20260317_153327
```
* concurrent_submit: 100 iterations shared among 100 VUs (maxDuration: 30s, gracefulStop: 30s)
http_req_duration
http_req_duration..............: avg=282.12ms min=143.72ms med=290.62ms max=398.7ms p(90)=371.3ms p(95)=383.34ms
http_reqs......................: 100 199.695727/s
iterations.....................: 100 199.695727/s
running (0m00.5s), 000/100 VUs, 100 complete and 0 interrupted iterations
```
### test-2.2-message-idempotent_20260317_153327
```
running (0m01.0s), 50/50 VUs, 0 complete and 0 interrupted iterations
running (0m02.0s), 50/50 VUs, 50 complete and 0 interrupted iterations
running (0m03.0s), 50/50 VUs, 100 complete and 0 interrupted iterations
running (0m04.0s), 50/50 VUs, 150 complete and 0 interrupted iterations
running (0m05.0s), 50/50 VUs, 200 complete and 0 interrupted iterations
running (0m06.0s), 50/50 VUs, 250 complete and 0 interrupted iterations
running (0m07.0s), 50/50 VUs, 300 complete and 0 interrupted iterations
running (0m08.0s), 50/50 VUs, 350 complete and 0 interrupted iterations
running (0m09.0s), 50/50 VUs, 400 complete and 0 interrupted iterations
running (0m10.0s), 50/50 VUs, 450 complete and 0 interrupted iterations
running (0m11.0s), 50/50 VUs, 500 complete and 0 interrupted iterations
running (0m12.0s), 50/50 VUs, 550 complete and 0 interrupted iterations
running (0m13.0s), 50/50 VUs, 600 complete and 0 interrupted iterations
running (0m14.0s), 50/50 VUs, 650 complete and 0 interrupted iterations
running (0m15.0s), 50/50 VUs, 700 complete and 0 interrupted iterations
running (0m16.0s), 50/50 VUs, 750 complete and 0 interrupted iterations
running (0m17.0s), 50/50 VUs, 800 complete and 0 interrupted iterations
running (0m18.0s), 50/50 VUs, 850 complete and 0 interrupted iterations
running (0m19.0s), 50/50 VUs, 900 complete and 0 interrupted iterations
running (0m20.0s), 50/50 VUs, 950 complete and 0 interrupted iterations
```
### test-2.3-like-benchmark-a_20260317_153327
```
running (0m01.0s), 005/100 VUs, 25 complete and 0 interrupted iterations
running (0m02.0s), 010/100 VUs, 98 complete and 0 interrupted iterations
running (0m03.0s), 015/100 VUs, 216 complete and 0 interrupted iterations
running (0m04.0s), 020/100 VUs, 381 complete and 0 interrupted iterations
running (0m05.0s), 025/100 VUs, 589 complete and 0 interrupted iterations
running (0m06.0s), 030/100 VUs, 850 complete and 0 interrupted iterations
running (0m07.0s), 035/100 VUs, 1151 complete and 0 interrupted iterations
running (0m08.0s), 040/100 VUs, 1491 complete and 0 interrupted iterations
running (0m09.0s), 045/100 VUs, 1843 complete and 0 interrupted iterations
running (0m10.0s), 049/100 VUs, 2200 complete and 0 interrupted iterations
running (0m11.0s), 052/100 VUs, 2554 complete and 0 interrupted iterations
running (0m12.0s), 054/100 VUs, 2903 complete and 0 interrupted iterations
running (0m13.0s), 057/100 VUs, 3251 complete and 0 interrupted iterations
running (0m14.0s), 059/100 VUs, 3594 complete and 0 interrupted iterations
running (0m15.0s), 062/100 VUs, 3922 complete and 0 interrupted iterations
running (0m16.0s), 064/100 VUs, 4248 complete and 0 interrupted iterations
running (0m17.0s), 067/100 VUs, 4567 complete and 0 interrupted iterations
running (0m18.0s), 069/100 VUs, 4904 complete and 0 interrupted iterations
running (0m19.0s), 072/100 VUs, 5258 complete and 0 interrupted iterations
running (0m20.0s), 074/100 VUs, 5608 complete and 0 interrupted iterations
```
### test-2.3-like-benchmark-b_20260317_153327
```
running (0m01.0s), 005/100 VUs, 25 complete and 0 interrupted iterations
running (0m02.0s), 010/100 VUs, 100 complete and 0 interrupted iterations
running (0m03.0s), 015/100 VUs, 225 complete and 0 interrupted iterations
running (0m04.0s), 020/100 VUs, 400 complete and 0 interrupted iterations
running (0m05.0s), 025/100 VUs, 622 complete and 0 interrupted iterations
running (0m06.0s), 030/100 VUs, 870 complete and 0 interrupted iterations
running (0m07.0s), 035/100 VUs, 1190 complete and 0 interrupted iterations
running (0m08.0s), 040/100 VUs, 1560 complete and 0 interrupted iterations
running (0m09.0s), 045/100 VUs, 1980 complete and 0 interrupted iterations
running (0m10.0s), 049/100 VUs, 2448 complete and 0 interrupted iterations
running (0m11.0s), 052/100 VUs, 2906 complete and 0 interrupted iterations
running (0m12.0s), 054/100 VUs, 3436 complete and 0 interrupted iterations
running (0m13.0s), 057/100 VUs, 3991 complete and 0 interrupted iterations
running (0m14.0s), 059/100 VUs, 4571 complete and 0 interrupted iterations
running (0m15.0s), 062/100 VUs, 5176 complete and 0 interrupted iterations
running (0m16.0s), 064/100 VUs, 5753 complete and 0 interrupted iterations
running (0m17.0s), 067/100 VUs, 6408 complete and 0 interrupted iterations
running (0m18.0s), 069/100 VUs, 7087 complete and 0 interrupted iterations
running (0m19.0s), 072/100 VUs, 7789 complete and 0 interrupted iterations
running (0m20.0s), 074/100 VUs, 8519 complete and 0 interrupted iterations
```
### test-2.4-cache-consistency_20260317_153327
```
running (0m01.0s), 50/50 VUs, 50 complete and 0 interrupted iterations
running (0m02.0s), 50/50 VUs, 150 complete and 0 interrupted iterations
running (0m03.0s), 50/50 VUs, 250 complete and 0 interrupted iterations
running (0m04.0s), 50/50 VUs, 350 complete and 0 interrupted iterations
running (0m05.0s), 50/50 VUs, 450 complete and 0 interrupted iterations
running (0m06.0s), 50/50 VUs, 550 complete and 0 interrupted iterations
running (0m07.0s), 50/50 VUs, 650 complete and 0 interrupted iterations
running (0m08.0s), 50/50 VUs, 750 complete and 0 interrupted iterations
running (0m09.0s), 50/50 VUs, 850 complete and 0 interrupted iterations
running (0m10.0s), 50/50 VUs, 950 complete and 0 interrupted iterations
running (0m11.0s), 50/50 VUs, 1050 complete and 0 interrupted iterations
running (0m12.0s), 50/50 VUs, 1150 complete and 0 interrupted iterations
running (0m13.0s), 50/50 VUs, 1250 complete and 0 interrupted iterations
running (0m14.0s), 50/50 VUs, 1350 complete and 0 interrupted iterations
running (0m15.0s), 50/50 VUs, 1450 complete and 0 interrupted iterations
running (0m16.0s), 50/50 VUs, 1550 complete and 0 interrupted iterations
running (0m17.0s), 50/50 VUs, 1650 complete and 0 interrupted iterations
running (0m18.0s), 50/50 VUs, 1750 complete and 0 interrupted iterations
running (0m19.0s), 50/50 VUs, 1850 complete and 0 interrupted iterations
running (0m20.0s), 50/50 VUs, 1950 complete and 0 interrupted iterations
```
### test-2.5-zset-hash-mysql_20260317_153327
```
running (01.0s), 10/10 VUs, 10 complete and 0 interrupted iterations
running (02.0s), 10/10 VUs, 30 complete and 0 interrupted iterations
running (03.0s), 10/10 VUs, 50 complete and 0 interrupted iterations
running (04.0s), 10/10 VUs, 70 complete and 0 interrupted iterations
running (05.0s), 10/10 VUs, 90 complete and 0 interrupted iterations
running (06.0s), 10/10 VUs, 110 complete and 0 interrupted iterations
running (07.0s), 10/10 VUs, 130 complete and 0 interrupted iterations
running (08.0s), 10/10 VUs, 150 complete and 0 interrupted iterations
running (09.0s), 10/10 VUs, 170 complete and 0 interrupted iterations
running (10.0s), 10/10 VUs, 190 complete and 0 interrupted iterations
running (11.0s), 10/10 VUs, 210 complete and 0 interrupted iterations
running (12.0s), 10/10 VUs, 230 complete and 0 interrupted iterations
running (13.0s), 10/10 VUs, 250 complete and 0 interrupted iterations
running (14.0s), 10/10 VUs, 270 complete and 0 interrupted iterations
running (15.0s), 10/10 VUs, 290 complete and 0 interrupted iterations
running (16.0s), 10/10 VUs, 310 complete and 0 interrupted iterations
running (17.0s), 10/10 VUs, 330 complete and 0 interrupted iterations
running (18.0s), 10/10 VUs, 350 complete and 0 interrupted iterations
running (19.0s), 10/10 VUs, 370 complete and 0 interrupted iterations
running (20.0s), 10/10 VUs, 390 complete and 0 interrupted iterations
```
### test-2.5-zset-hash-redis_20260317_153327
```
running (01.0s), 10/10 VUs, 10 complete and 0 interrupted iterations
running (02.0s), 10/10 VUs, 30 complete and 0 interrupted iterations
running (03.0s), 10/10 VUs, 50 complete and 0 interrupted iterations
running (04.0s), 10/10 VUs, 70 complete and 0 interrupted iterations
running (05.0s), 10/10 VUs, 90 complete and 0 interrupted iterations
running (06.0s), 10/10 VUs, 110 complete and 0 interrupted iterations
running (07.0s), 10/10 VUs, 130 complete and 0 interrupted iterations
running (08.0s), 10/10 VUs, 150 complete and 0 interrupted iterations
running (09.0s), 10/10 VUs, 170 complete and 0 interrupted iterations
running (10.0s), 10/10 VUs, 190 complete and 0 interrupted iterations
running (11.0s), 10/10 VUs, 210 complete and 0 interrupted iterations
running (12.0s), 10/10 VUs, 230 complete and 0 interrupted iterations
running (13.0s), 10/10 VUs, 250 complete and 0 interrupted iterations
running (14.0s), 10/10 VUs, 270 complete and 0 interrupted iterations
running (15.0s), 10/10 VUs, 290 complete and 0 interrupted iterations
running (16.0s), 10/10 VUs, 310 complete and 0 interrupted iterations
running (17.0s), 10/10 VUs, 330 complete and 0 interrupted iterations
running (18.0s), 10/10 VUs, 350 complete and 0 interrupted iterations
running (19.0s), 10/10 VUs, 370 complete and 0 interrupted iterations
running (20.0s), 10/10 VUs, 390 complete and 0 interrupted iterations
```
File diff suppressed because it is too large Load Diff
@@ -1,53 +0,0 @@
/\ Grafana /‾‾/
/\ / \ |\ __ / /
/ \/ \ | |/ / / ‾‾\
/ \ | ( | (‾) |
/ __________ \ |_|\_\ \_____/
execution: local
script: ./benchmark/test-2.1-task-idempotent.js
output: json (./benchmark/results/test-2.1-task-idempotent_20260317_153327.json)
scenarios: (100.00%) 1 scenario, 100 max VUs, 1m0s max duration (incl. graceful stop):
* concurrent_submit: 100 iterations shared among 100 VUs (maxDuration: 30s, gracefulStop: 30s)
█ THRESHOLDS
http_req_duration
✓ 'p(95)<5000' p(95)=383.34ms
http_req_failed
✓ 'rate<0.01' rate=0.00%
█ TOTAL RESULTS
checks_total.......: 200 399.391454/s
checks_succeeded...: 100.00% 200 out of 200
checks_failed......: 0.00% 0 out of 200
✓ status is 200
✓ has response body
HTTP
http_req_duration..............: avg=282.12ms min=143.72ms med=290.62ms max=398.7ms p(90)=371.3ms p(95)=383.34ms
{ expected_response:true }...: avg=282.12ms min=143.72ms med=290.62ms max=398.7ms p(90)=371.3ms p(95)=383.34ms
http_req_failed................: 0.00% 0 out of 100
http_reqs......................: 100 199.695727/s
EXECUTION
iteration_duration.............: avg=383.29ms min=244.09ms med=391.87ms max=500.58ms p(90)=472.18ms p(95)=484.55ms
iterations.....................: 100 199.695727/s
NETWORK
data_received..................: 44 kB 89 kB/s
data_sent......................: 18 kB 37 kB/s
running (0m00.5s), 000/100 VUs, 100 complete and 0 interrupted iterations
concurrent_submit ✓ [ 100% ] 100 VUs 00.5s/30s 100/100 shared iters
File diff suppressed because it is too large Load Diff
@@ -1,145 +0,0 @@
/\ Grafana /‾‾/
/\ / \ |\ __ / /
/ \/ \ | |/ / / ‾‾\
/ \ | ( | (‾) |
/ __________ \ |_|\_\ \_____/
execution: local
script: ./benchmark/test-2.2-message-idempotent.js
output: json (./benchmark/results/test-2.2-message-idempotent_20260317_153327.json)
scenarios: (100.00%) 1 scenario, 50 max VUs, 1m0s max duration (incl. graceful stop):
* default: 50 looping VUs for 30s (gracefulStop: 30s)
running (0m01.0s), 50/50 VUs, 0 complete and 0 interrupted iterations
default [ 3% ] 50 VUs 01.0s/30s
running (0m02.0s), 50/50 VUs, 50 complete and 0 interrupted iterations
default [ 7% ] 50 VUs 02.0s/30s
running (0m03.0s), 50/50 VUs, 100 complete and 0 interrupted iterations
default [ 10% ] 50 VUs 03.0s/30s
running (0m04.0s), 50/50 VUs, 150 complete and 0 interrupted iterations
default [ 13% ] 50 VUs 04.0s/30s
running (0m05.0s), 50/50 VUs, 200 complete and 0 interrupted iterations
default [ 17% ] 50 VUs 05.0s/30s
running (0m06.0s), 50/50 VUs, 250 complete and 0 interrupted iterations
default [ 20% ] 50 VUs 06.0s/30s
running (0m07.0s), 50/50 VUs, 300 complete and 0 interrupted iterations
default [ 23% ] 50 VUs 07.0s/30s
running (0m08.0s), 50/50 VUs, 350 complete and 0 interrupted iterations
default [ 27% ] 50 VUs 08.0s/30s
running (0m09.0s), 50/50 VUs, 400 complete and 0 interrupted iterations
default [ 30% ] 50 VUs 09.0s/30s
running (0m10.0s), 50/50 VUs, 450 complete and 0 interrupted iterations
default [ 33% ] 50 VUs 10.0s/30s
running (0m11.0s), 50/50 VUs, 500 complete and 0 interrupted iterations
default [ 37% ] 50 VUs 11.0s/30s
running (0m12.0s), 50/50 VUs, 550 complete and 0 interrupted iterations
default [ 40% ] 50 VUs 12.0s/30s
running (0m13.0s), 50/50 VUs, 600 complete and 0 interrupted iterations
default [ 43% ] 50 VUs 13.0s/30s
running (0m14.0s), 50/50 VUs, 650 complete and 0 interrupted iterations
default [ 47% ] 50 VUs 14.0s/30s
running (0m15.0s), 50/50 VUs, 700 complete and 0 interrupted iterations
default [ 50% ] 50 VUs 15.0s/30s
running (0m16.0s), 50/50 VUs, 750 complete and 0 interrupted iterations
default [ 53% ] 50 VUs 16.0s/30s
running (0m17.0s), 50/50 VUs, 800 complete and 0 interrupted iterations
default [ 57% ] 50 VUs 17.0s/30s
running (0m18.0s), 50/50 VUs, 850 complete and 0 interrupted iterations
default [ 60% ] 50 VUs 18.0s/30s
running (0m19.0s), 50/50 VUs, 900 complete and 0 interrupted iterations
default [ 63% ] 50 VUs 19.0s/30s
running (0m20.0s), 50/50 VUs, 950 complete and 0 interrupted iterations
default [ 67% ] 50 VUs 20.0s/30s
running (0m21.0s), 50/50 VUs, 1000 complete and 0 interrupted iterations
default [ 70% ] 50 VUs 21.0s/30s
running (0m22.0s), 50/50 VUs, 1050 complete and 0 interrupted iterations
default [ 73% ] 50 VUs 22.0s/30s
running (0m23.0s), 50/50 VUs, 1100 complete and 0 interrupted iterations
default [ 77% ] 50 VUs 23.0s/30s
running (0m24.0s), 50/50 VUs, 1150 complete and 0 interrupted iterations
default [ 80% ] 50 VUs 24.0s/30s
running (0m25.0s), 50/50 VUs, 1200 complete and 0 interrupted iterations
default [ 83% ] 50 VUs 25.0s/30s
running (0m26.0s), 50/50 VUs, 1250 complete and 0 interrupted iterations
default [ 87% ] 50 VUs 26.0s/30s
running (0m27.0s), 50/50 VUs, 1300 complete and 0 interrupted iterations
default [ 90% ] 50 VUs 27.0s/30s
running (0m28.0s), 50/50 VUs, 1350 complete and 0 interrupted iterations
default [ 93% ] 50 VUs 28.0s/30s
running (0m29.0s), 50/50 VUs, 1400 complete and 0 interrupted iterations
default [ 97% ] 50 VUs 29.0s/30s
running (0m30.0s), 50/50 VUs, 1450 complete and 0 interrupted iterations
default [ 100% ] 50 VUs 30.0s/30s
█ THRESHOLDS
http_req_duration
✓ 'p(95)<500' p(95)=42.86ms
http_req_failed
✓ 'rate<0.01' rate=0.00%
█ TOTAL RESULTS
checks_total.......: 3000 98.088937/s
checks_succeeded...: 100.00% 3000 out of 3000
checks_failed......: 0.00% 0 out of 3000
✓ status is 200
✓ response time < 500ms
HTTP
http_req_duration..............: avg=18.27ms min=4.13ms med=8.68ms max=281.27ms p(90)=13.03ms p(95)=42.86ms
{ expected_response:true }...: avg=18.27ms min=4.13ms med=8.68ms max=281.27ms p(90)=13.03ms p(95)=42.86ms
http_req_failed................: 0.00% 0 out of 1500
http_reqs......................: 1500 49.044469/s
EXECUTION
iteration_duration.............: avg=1.01s min=1s med=1s max=1.28s p(90)=1.01s p(95)=1.04s
iterations.....................: 1500 49.044469/s
vus............................: 50 min=50 max=50
vus_max........................: 50 min=50 max=50
NETWORK
data_received..................: 689 kB 23 kB/s
data_sent......................: 269 kB 8.8 kB/s
running (0m30.6s), 00/50 VUs, 1500 complete and 0 interrupted iterations
default ✓ [ 100% ] 50 VUs 30s
File diff suppressed because it is too large Load Diff
@@ -1,172 +0,0 @@
/\ Grafana /‾‾/
/\ / \ |\ __ / /
/ \/ \ | |/ / / ‾‾\
/ \ | ( | (‾) |
/ __________ \ |_|\_\ \_____/
execution: local
script: ./benchmark/test-2.3-like-benchmark-a.js
output: json (./benchmark/results/test-2.3-like-benchmark-a_20260317_153327.json)
scenarios: (100.00%) 1 scenario, 100 max VUs, 1m10s max duration (incl. graceful stop):
* default: Up to 100 looping VUs for 40s over 3 stages (gracefulRampDown: 30s, gracefulStop: 30s)
running (0m01.0s), 005/100 VUs, 25 complete and 0 interrupted iterations
default [ 2% ] 005/100 VUs 01.0s/40.0s
running (0m02.0s), 010/100 VUs, 98 complete and 0 interrupted iterations
default [ 5% ] 010/100 VUs 02.0s/40.0s
running (0m03.0s), 015/100 VUs, 216 complete and 0 interrupted iterations
default [ 7% ] 015/100 VUs 03.0s/40.0s
running (0m04.0s), 020/100 VUs, 381 complete and 0 interrupted iterations
default [ 10% ] 020/100 VUs 04.0s/40.0s
running (0m05.0s), 025/100 VUs, 589 complete and 0 interrupted iterations
default [ 12% ] 025/100 VUs 05.0s/40.0s
running (0m06.0s), 030/100 VUs, 850 complete and 0 interrupted iterations
default [ 15% ] 030/100 VUs 06.0s/40.0s
running (0m07.0s), 035/100 VUs, 1151 complete and 0 interrupted iterations
default [ 17% ] 035/100 VUs 07.0s/40.0s
running (0m08.0s), 040/100 VUs, 1491 complete and 0 interrupted iterations
default [ 20% ] 040/100 VUs 08.0s/40.0s
running (0m09.0s), 045/100 VUs, 1843 complete and 0 interrupted iterations
default [ 22% ] 045/100 VUs 09.0s/40.0s
running (0m10.0s), 049/100 VUs, 2200 complete and 0 interrupted iterations
default [ 25% ] 049/100 VUs 10.0s/40.0s
running (0m11.0s), 052/100 VUs, 2554 complete and 0 interrupted iterations
default [ 27% ] 052/100 VUs 11.0s/40.0s
running (0m12.0s), 054/100 VUs, 2903 complete and 0 interrupted iterations
default [ 30% ] 054/100 VUs 12.0s/40.0s
running (0m13.0s), 057/100 VUs, 3251 complete and 0 interrupted iterations
default [ 32% ] 057/100 VUs 13.0s/40.0s
running (0m14.0s), 059/100 VUs, 3594 complete and 0 interrupted iterations
default [ 35% ] 059/100 VUs 14.0s/40.0s
running (0m15.0s), 062/100 VUs, 3922 complete and 0 interrupted iterations
default [ 37% ] 062/100 VUs 15.0s/40.0s
running (0m16.0s), 064/100 VUs, 4248 complete and 0 interrupted iterations
default [ 40% ] 064/100 VUs 16.0s/40.0s
running (0m17.0s), 067/100 VUs, 4567 complete and 0 interrupted iterations
default [ 42% ] 067/100 VUs 17.0s/40.0s
running (0m18.0s), 069/100 VUs, 4904 complete and 0 interrupted iterations
default [ 45% ] 069/100 VUs 18.0s/40.0s
running (0m19.0s), 072/100 VUs, 5258 complete and 0 interrupted iterations
default [ 47% ] 072/100 VUs 19.0s/40.0s
running (0m20.0s), 074/100 VUs, 5608 complete and 0 interrupted iterations
default [ 50% ] 074/100 VUs 20.0s/40.0s
running (0m21.0s), 077/100 VUs, 5954 complete and 0 interrupted iterations
default [ 52% ] 077/100 VUs 21.0s/40.0s
running (0m22.0s), 079/100 VUs, 6310 complete and 0 interrupted iterations
default [ 55% ] 079/100 VUs 22.0s/40.0s
running (0m23.0s), 082/100 VUs, 6663 complete and 0 interrupted iterations
default [ 57% ] 082/100 VUs 23.0s/40.0s
running (0m24.0s), 084/100 VUs, 7018 complete and 0 interrupted iterations
default [ 60% ] 084/100 VUs 24.0s/40.0s
running (0m25.0s), 087/100 VUs, 7372 complete and 0 interrupted iterations
default [ 62% ] 087/100 VUs 25.0s/40.0s
running (0m26.0s), 089/100 VUs, 7731 complete and 0 interrupted iterations
default [ 65% ] 089/100 VUs 26.0s/40.0s
running (0m27.0s), 092/100 VUs, 8071 complete and 0 interrupted iterations
default [ 67% ] 092/100 VUs 27.0s/40.0s
running (0m28.0s), 094/100 VUs, 8408 complete and 0 interrupted iterations
default [ 70% ] 094/100 VUs 28.0s/40.0s
running (0m29.0s), 097/100 VUs, 8736 complete and 0 interrupted iterations
default [ 72% ] 097/100 VUs 29.0s/40.0s
running (0m30.0s), 099/100 VUs, 9061 complete and 0 interrupted iterations
default [ 75% ] 099/100 VUs 30.0s/40.0s
running (0m31.0s), 091/100 VUs, 9403 complete and 0 interrupted iterations
default [ 77% ] 091/100 VUs 31.0s/40.0s
running (0m32.0s), 082/100 VUs, 9749 complete and 0 interrupted iterations
default [ 80% ] 082/100 VUs 32.0s/40.0s
running (0m33.0s), 072/100 VUs, 10092 complete and 0 interrupted iterations
default [ 82% ] 072/100 VUs 33.0s/40.0s
running (0m34.0s), 061/100 VUs, 10436 complete and 0 interrupted iterations
default [ 85% ] 061/100 VUs 34.0s/40.0s
running (0m35.0s), 052/100 VUs, 10786 complete and 0 interrupted iterations
default [ 87% ] 052/100 VUs 35.0s/40.0s
running (0m36.0s), 042/100 VUs, 11128 complete and 0 interrupted iterations
default [ 90% ] 042/100 VUs 36.0s/40.0s
running (0m37.0s), 031/100 VUs, 11463 complete and 0 interrupted iterations
default [ 92% ] 031/100 VUs 37.0s/40.0s
running (0m38.0s), 021/100 VUs, 11720 complete and 0 interrupted iterations
default [ 95% ] 021/100 VUs 38.0s/40.0s
running (0m39.0s), 014/100 VUs, 11849 complete and 0 interrupted iterations
default [ 97% ] 014/100 VUs 39.0s/40.0s
running (0m40.0s), 001/100 VUs, 11914 complete and 0 interrupted iterations
default [ 100% ] 001/100 VUs 40.0s/40.0s
█ THRESHOLDS
http_req_duration
✓ 'p(95)<1000' p(95)=189.54ms
█ TOTAL RESULTS
checks_total.......: 23830 595.650955/s
checks_succeeded...: 100.00% 23830 out of 23830
checks_failed......: 0.00% 0 out of 23830
✓ status is 200
✓ response time < 500ms (Direct DB)
HTTP
http_req_duration..............: avg=88.64ms min=3.02ms med=96.41ms max=405.43ms p(90)=173.6ms p(95)=189.54ms
{ expected_response:true }...: avg=88.64ms min=3.02ms med=96.41ms max=405.43ms p(90)=173.6ms p(95)=189.54ms
http_req_failed................: 0.00% 0 out of 11915
http_reqs......................: 11915 297.825477/s
EXECUTION
iteration_duration.............: avg=189.21ms min=103.17ms med=196.95ms max=506.18ms p(90)=274.16ms p(95)=290.03ms
iterations.....................: 11915 297.825477/s
vus............................: 1 min=1 max=99
vus_max........................: 100 min=100 max=100
NETWORK
data_received..................: 2.0 MB 50 kB/s
data_sent......................: 1.3 MB 34 kB/s
running (0m40.0s), 000/100 VUs, 11915 complete and 0 interrupted iterations
default ✓ [ 100% ] 000/100 VUs 40s
File diff suppressed because it is too large Load Diff
@@ -1,172 +0,0 @@
/\ Grafana /‾‾/
/\ / \ |\ __ / /
/ \/ \ | |/ / / ‾‾\
/ \ | ( | (‾) |
/ __________ \ |_|\_\ \_____/
execution: local
script: ./benchmark/test-2.3-like-benchmark-b.js
output: json (./benchmark/results/test-2.3-like-benchmark-b_20260317_153327.json)
scenarios: (100.00%) 1 scenario, 100 max VUs, 1m10s max duration (incl. graceful stop):
* default: Up to 100 looping VUs for 40s over 3 stages (gracefulRampDown: 30s, gracefulStop: 30s)
running (0m01.0s), 005/100 VUs, 25 complete and 0 interrupted iterations
default [ 2% ] 005/100 VUs 01.0s/40.0s
running (0m02.0s), 010/100 VUs, 100 complete and 0 interrupted iterations
default [ 5% ] 010/100 VUs 02.0s/40.0s
running (0m03.0s), 015/100 VUs, 225 complete and 0 interrupted iterations
default [ 7% ] 015/100 VUs 03.0s/40.0s
running (0m04.0s), 020/100 VUs, 400 complete and 0 interrupted iterations
default [ 10% ] 020/100 VUs 04.0s/40.0s
running (0m05.0s), 025/100 VUs, 622 complete and 0 interrupted iterations
default [ 12% ] 025/100 VUs 05.0s/40.0s
running (0m06.0s), 030/100 VUs, 870 complete and 0 interrupted iterations
default [ 15% ] 030/100 VUs 06.0s/40.0s
running (0m07.0s), 035/100 VUs, 1190 complete and 0 interrupted iterations
default [ 17% ] 035/100 VUs 07.0s/40.0s
running (0m08.0s), 040/100 VUs, 1560 complete and 0 interrupted iterations
default [ 20% ] 040/100 VUs 08.0s/40.0s
running (0m09.0s), 045/100 VUs, 1980 complete and 0 interrupted iterations
default [ 22% ] 045/100 VUs 09.0s/40.0s
running (0m10.0s), 049/100 VUs, 2448 complete and 0 interrupted iterations
default [ 25% ] 049/100 VUs 10.0s/40.0s
running (0m11.0s), 052/100 VUs, 2906 complete and 0 interrupted iterations
default [ 27% ] 052/100 VUs 11.0s/40.0s
running (0m12.0s), 054/100 VUs, 3436 complete and 0 interrupted iterations
default [ 30% ] 054/100 VUs 12.0s/40.0s
running (0m13.0s), 057/100 VUs, 3991 complete and 0 interrupted iterations
default [ 32% ] 057/100 VUs 13.0s/40.0s
running (0m14.0s), 059/100 VUs, 4571 complete and 0 interrupted iterations
default [ 35% ] 059/100 VUs 14.0s/40.0s
running (0m15.0s), 062/100 VUs, 5176 complete and 0 interrupted iterations
default [ 37% ] 062/100 VUs 15.0s/40.0s
running (0m16.0s), 064/100 VUs, 5753 complete and 0 interrupted iterations
default [ 40% ] 064/100 VUs 16.0s/40.0s
running (0m17.0s), 067/100 VUs, 6408 complete and 0 interrupted iterations
default [ 42% ] 067/100 VUs 17.0s/40.0s
running (0m18.0s), 069/100 VUs, 7087 complete and 0 interrupted iterations
default [ 45% ] 069/100 VUs 18.0s/40.0s
running (0m19.0s), 072/100 VUs, 7789 complete and 0 interrupted iterations
default [ 47% ] 072/100 VUs 19.0s/40.0s
running (0m20.0s), 074/100 VUs, 8519 complete and 0 interrupted iterations
default [ 50% ] 074/100 VUs 20.0s/40.0s
running (0m21.0s), 077/100 VUs, 9213 complete and 0 interrupted iterations
default [ 52% ] 077/100 VUs 21.0s/40.0s
running (0m22.0s), 079/100 VUs, 9993 complete and 0 interrupted iterations
default [ 55% ] 079/100 VUs 22.0s/40.0s
running (0m23.0s), 082/100 VUs, 10794 complete and 0 interrupted iterations
default [ 57% ] 082/100 VUs 23.0s/40.0s
running (0m24.0s), 084/100 VUs, 11622 complete and 0 interrupted iterations
default [ 60% ] 084/100 VUs 24.0s/40.0s
running (0m25.0s), 087/100 VUs, 12475 complete and 0 interrupted iterations
default [ 62% ] 087/100 VUs 25.0s/40.0s
running (0m26.0s), 089/100 VUs, 13350 complete and 0 interrupted iterations
default [ 65% ] 089/100 VUs 26.0s/40.0s
running (0m27.0s), 092/100 VUs, 14190 complete and 0 interrupted iterations
default [ 67% ] 092/100 VUs 27.0s/40.0s
running (0m28.0s), 094/100 VUs, 15119 complete and 0 interrupted iterations
default [ 70% ] 094/100 VUs 28.0s/40.0s
running (0m29.0s), 097/100 VUs, 16074 complete and 0 interrupted iterations
default [ 72% ] 097/100 VUs 29.0s/40.0s
running (0m30.0s), 099/100 VUs, 17053 complete and 0 interrupted iterations
default [ 75% ] 099/100 VUs 30.0s/40.0s
running (0m31.0s), 091/100 VUs, 18004 complete and 0 interrupted iterations
default [ 77% ] 091/100 VUs 31.0s/40.0s
running (0m32.0s), 081/100 VUs, 18869 complete and 0 interrupted iterations
default [ 80% ] 081/100 VUs 32.0s/40.0s
running (0m33.0s), 071/100 VUs, 19564 complete and 0 interrupted iterations
default [ 82% ] 071/100 VUs 33.0s/40.0s
running (0m34.0s), 061/100 VUs, 20229 complete and 0 interrupted iterations
default [ 85% ] 061/100 VUs 34.0s/40.0s
running (0m35.0s), 051/100 VUs, 20794 complete and 0 interrupted iterations
default [ 87% ] 051/100 VUs 35.0s/40.0s
running (0m36.0s), 041/100 VUs, 21259 complete and 0 interrupted iterations
default [ 90% ] 041/100 VUs 36.0s/40.0s
running (0m37.0s), 031/100 VUs, 21624 complete and 0 interrupted iterations
default [ 92% ] 031/100 VUs 37.0s/40.0s
running (0m38.0s), 021/100 VUs, 21865 complete and 0 interrupted iterations
default [ 95% ] 021/100 VUs 38.0s/40.0s
running (0m39.0s), 011/100 VUs, 22030 complete and 0 interrupted iterations
default [ 97% ] 011/100 VUs 39.0s/40.0s
running (0m40.0s), 001/100 VUs, 22095 complete and 0 interrupted iterations
default [ 100% ] 001/100 VUs 40.0s/40.0s
█ THRESHOLDS
http_req_duration
✓ 'p(95)<200' p(95)=2.17ms
█ TOTAL RESULTS
checks_total.......: 44192 1103.539485/s
checks_succeeded...: 100.00% 44192 out of 44192
checks_failed......: 0.00% 0 out of 44192
✓ status is 200
✓ response time < 100ms (Redis)
HTTP
http_req_duration..............: avg=1.23ms min=256.58µs med=1.17ms max=6.18ms p(90)=1.89ms p(95)=2.17ms
{ expected_response:true }...: avg=1.23ms min=256.58µs med=1.17ms max=6.18ms p(90)=1.89ms p(95)=2.17ms
http_req_failed................: 0.00% 0 out of 22096
http_reqs......................: 22096 551.769742/s
EXECUTION
iteration_duration.............: avg=101.78ms min=100.31ms med=101.78ms max=107.24ms p(90)=102.49ms p(95)=102.78ms
iterations.....................: 22096 551.769742/s
vus............................: 1 min=1 max=99
vus_max........................: 100 min=100 max=100
NETWORK
data_received..................: 3.7 MB 93 kB/s
data_sent......................: 2.3 MB 59 kB/s
running (0m40.0s), 000/100 VUs, 22096 complete and 0 interrupted iterations
default ✓ [ 100% ] 000/100 VUs 40s
File diff suppressed because it is too large Load Diff
@@ -1,143 +0,0 @@
/\ Grafana /‾‾/
/\ / \ |\ __ / /
/ \/ \ | |/ / / ‾‾\
/ \ | ( | (‾) |
/ __________ \ |_|\_\ \_____/
execution: local
script: ./benchmark/test-2.4-cache-consistency.js
output: json (./benchmark/results/test-2.4-cache-consistency_20260317_153327.json)
scenarios: (100.00%) 1 scenario, 50 max VUs, 1m0s max duration (incl. graceful stop):
* default: 50 looping VUs for 30s (gracefulStop: 30s)
running (0m01.0s), 50/50 VUs, 50 complete and 0 interrupted iterations
default [ 3% ] 50 VUs 01.0s/30s
running (0m02.0s), 50/50 VUs, 150 complete and 0 interrupted iterations
default [ 7% ] 50 VUs 02.0s/30s
running (0m03.0s), 50/50 VUs, 250 complete and 0 interrupted iterations
default [ 10% ] 50 VUs 03.0s/30s
running (0m04.0s), 50/50 VUs, 350 complete and 0 interrupted iterations
default [ 13% ] 50 VUs 04.0s/30s
running (0m05.0s), 50/50 VUs, 450 complete and 0 interrupted iterations
default [ 17% ] 50 VUs 05.0s/30s
running (0m06.0s), 50/50 VUs, 550 complete and 0 interrupted iterations
default [ 20% ] 50 VUs 06.0s/30s
running (0m07.0s), 50/50 VUs, 650 complete and 0 interrupted iterations
default [ 23% ] 50 VUs 07.0s/30s
running (0m08.0s), 50/50 VUs, 750 complete and 0 interrupted iterations
default [ 27% ] 50 VUs 08.0s/30s
running (0m09.0s), 50/50 VUs, 850 complete and 0 interrupted iterations
default [ 30% ] 50 VUs 09.0s/30s
running (0m10.0s), 50/50 VUs, 950 complete and 0 interrupted iterations
default [ 33% ] 50 VUs 10.0s/30s
running (0m11.0s), 50/50 VUs, 1050 complete and 0 interrupted iterations
default [ 37% ] 50 VUs 11.0s/30s
running (0m12.0s), 50/50 VUs, 1150 complete and 0 interrupted iterations
default [ 40% ] 50 VUs 12.0s/30s
running (0m13.0s), 50/50 VUs, 1250 complete and 0 interrupted iterations
default [ 43% ] 50 VUs 13.0s/30s
running (0m14.0s), 50/50 VUs, 1350 complete and 0 interrupted iterations
default [ 47% ] 50 VUs 14.0s/30s
running (0m15.0s), 50/50 VUs, 1450 complete and 0 interrupted iterations
default [ 50% ] 50 VUs 15.0s/30s
running (0m16.0s), 50/50 VUs, 1550 complete and 0 interrupted iterations
default [ 53% ] 50 VUs 16.0s/30s
running (0m17.0s), 50/50 VUs, 1650 complete and 0 interrupted iterations
default [ 57% ] 50 VUs 17.0s/30s
running (0m18.0s), 50/50 VUs, 1750 complete and 0 interrupted iterations
default [ 60% ] 50 VUs 18.0s/30s
running (0m19.0s), 50/50 VUs, 1850 complete and 0 interrupted iterations
default [ 63% ] 50 VUs 19.0s/30s
running (0m20.0s), 50/50 VUs, 1950 complete and 0 interrupted iterations
default [ 67% ] 50 VUs 20.0s/30s
running (0m21.0s), 50/50 VUs, 2050 complete and 0 interrupted iterations
default [ 70% ] 50 VUs 21.0s/30s
running (0m22.0s), 50/50 VUs, 2150 complete and 0 interrupted iterations
default [ 73% ] 50 VUs 22.0s/30s
running (0m23.0s), 50/50 VUs, 2250 complete and 0 interrupted iterations
default [ 77% ] 50 VUs 23.0s/30s
running (0m24.0s), 50/50 VUs, 2350 complete and 0 interrupted iterations
default [ 80% ] 50 VUs 24.0s/30s
running (0m25.0s), 50/50 VUs, 2450 complete and 0 interrupted iterations
default [ 83% ] 50 VUs 25.0s/30s
running (0m26.0s), 50/50 VUs, 2550 complete and 0 interrupted iterations
default [ 87% ] 50 VUs 26.0s/30s
running (0m27.0s), 50/50 VUs, 2650 complete and 0 interrupted iterations
default [ 90% ] 50 VUs 27.0s/30s
running (0m28.0s), 50/50 VUs, 2750 complete and 0 interrupted iterations
default [ 93% ] 50 VUs 28.0s/30s
running (0m29.0s), 50/50 VUs, 2850 complete and 0 interrupted iterations
default [ 97% ] 50 VUs 29.0s/30s
running (0m30.0s), 50/50 VUs, 2950 complete and 0 interrupted iterations
default [ 100% ] 50 VUs 30.0s/30s
█ THRESHOLDS
http_req_duration
✓ 'p(95)<500' p(95)=8.2ms
█ TOTAL RESULTS
checks_total.......: 6000 198.26608/s
checks_succeeded...: 0.00% 0 out of 6000
checks_failed......: 100.00% 6000 out of 6000
✗ status is 200
↳ 0% — ✓ 0 / ✗ 3000
✗ has data
↳ 0% — ✓ 0 / ✗ 3000
HTTP
http_req_duration....: avg=3.46ms min=1.07ms med=2.69ms max=25.46ms p(90)=4.65ms p(95)=8.2ms
http_req_failed......: 100.00% 3000 out of 3000
http_reqs............: 3000 99.13304/s
EXECUTION
iteration_duration...: avg=504.16ms min=501.25ms med=503.41ms max=529.57ms p(90)=505.46ms p(95)=509.19ms
iterations...........: 3000 99.13304/s
vus..................: 50 min=50 max=50
vus_max..............: 50 min=50 max=50
NETWORK
data_received........: 606 kB 20 kB/s
data_sent............: 243 kB 8.0 kB/s
running (0m30.3s), 00/50 VUs, 3000 complete and 0 interrupted iterations
default ✓ [ 100% ] 50 VUs 30s
File diff suppressed because it is too large Load Diff
@@ -1,112 +0,0 @@
/\ Grafana /‾‾/
/\ / \ |\ __ / /
/ \/ \ | |/ / / ‾‾\
/ \ | ( | (‾) |
/ __________ \ |_|\_\ \_____/
execution: local
script: ./benchmark/test-2.5-zset-hash-mysql.js
output: json (./benchmark/results/test-2.5-zset-hash-mysql_20260317_153327.json)
scenarios: (100.00%) 1 scenario, 10 max VUs, 50s max duration (incl. graceful stop):
* default: 10 looping VUs for 20s (gracefulStop: 30s)
running (01.0s), 10/10 VUs, 10 complete and 0 interrupted iterations
default [ 5% ] 10 VUs 01.0s/20s
running (02.0s), 10/10 VUs, 30 complete and 0 interrupted iterations
default [ 10% ] 10 VUs 02.0s/20s
running (03.0s), 10/10 VUs, 50 complete and 0 interrupted iterations
default [ 15% ] 10 VUs 03.0s/20s
running (04.0s), 10/10 VUs, 70 complete and 0 interrupted iterations
default [ 20% ] 10 VUs 04.0s/20s
running (05.0s), 10/10 VUs, 90 complete and 0 interrupted iterations
default [ 25% ] 10 VUs 05.0s/20s
running (06.0s), 10/10 VUs, 110 complete and 0 interrupted iterations
default [ 30% ] 10 VUs 06.0s/20s
running (07.0s), 10/10 VUs, 130 complete and 0 interrupted iterations
default [ 35% ] 10 VUs 07.0s/20s
running (08.0s), 10/10 VUs, 150 complete and 0 interrupted iterations
default [ 40% ] 10 VUs 08.0s/20s
running (09.0s), 10/10 VUs, 170 complete and 0 interrupted iterations
default [ 45% ] 10 VUs 09.0s/20s
running (10.0s), 10/10 VUs, 190 complete and 0 interrupted iterations
default [ 50% ] 10 VUs 10.0s/20s
running (11.0s), 10/10 VUs, 210 complete and 0 interrupted iterations
default [ 55% ] 10 VUs 11.0s/20s
running (12.0s), 10/10 VUs, 230 complete and 0 interrupted iterations
default [ 60% ] 10 VUs 12.0s/20s
running (13.0s), 10/10 VUs, 250 complete and 0 interrupted iterations
default [ 65% ] 10 VUs 13.0s/20s
running (14.0s), 10/10 VUs, 270 complete and 0 interrupted iterations
default [ 70% ] 10 VUs 14.0s/20s
running (15.0s), 10/10 VUs, 290 complete and 0 interrupted iterations
default [ 75% ] 10 VUs 15.0s/20s
running (16.0s), 10/10 VUs, 310 complete and 0 interrupted iterations
default [ 80% ] 10 VUs 16.0s/20s
running (17.0s), 10/10 VUs, 330 complete and 0 interrupted iterations
default [ 85% ] 10 VUs 17.0s/20s
running (18.0s), 10/10 VUs, 350 complete and 0 interrupted iterations
default [ 90% ] 10 VUs 18.0s/20s
running (19.0s), 10/10 VUs, 370 complete and 0 interrupted iterations
default [ 95% ] 10 VUs 19.0s/20s
running (20.0s), 10/10 VUs, 390 complete and 0 interrupted iterations
default [ 100% ] 10 VUs 20.0s/20s
█ THRESHOLDS
http_req_duration
✓ 'p(95)<200' p(95)=2.42ms
█ TOTAL RESULTS
checks_total.......: 800 39.771169/s
checks_succeeded...: 100.00% 800 out of 800
checks_failed......: 0.00% 0 out of 800
✓ status is 200
✓ response time < 200ms (MySQL)
HTTP
http_req_duration..............: avg=2.2ms min=548.05µs med=1.5ms max=27.47ms p(90)=2.09ms p(95)=2.42ms
{ expected_response:true }...: avg=2.2ms min=548.05µs med=1.5ms max=27.47ms p(90)=2.09ms p(95)=2.42ms
http_req_failed................: 0.00% 0 out of 400
http_reqs......................: 400 19.885584/s
EXECUTION
iteration_duration.............: avg=502.85ms min=500.7ms med=502.15ms max=529.09ms p(90)=502.97ms p(95)=503.78ms
iterations.....................: 400 19.885584/s
vus............................: 10 min=10 max=10
vus_max........................: 10 min=10 max=10
NETWORK
data_received..................: 67 kB 3.3 kB/s
data_sent......................: 41 kB 2.0 kB/s
running (20.1s), 00/10 VUs, 400 complete and 0 interrupted iterations
default ✓ [ 100% ] 10 VUs 20s
File diff suppressed because it is too large Load Diff
@@ -1,112 +0,0 @@
/\ Grafana /‾‾/
/\ / \ |\ __ / /
/ \/ \ | |/ / / ‾‾\
/ \ | ( | (‾) |
/ __________ \ |_|\_\ \_____/
execution: local
script: ./benchmark/test-2.5-zset-hash-redis.js
output: json (./benchmark/results/test-2.5-zset-hash-redis_20260317_153327.json)
scenarios: (100.00%) 1 scenario, 10 max VUs, 50s max duration (incl. graceful stop):
* default: 10 looping VUs for 20s (gracefulStop: 30s)
running (01.0s), 10/10 VUs, 10 complete and 0 interrupted iterations
default [ 5% ] 10 VUs 01.0s/20s
running (02.0s), 10/10 VUs, 30 complete and 0 interrupted iterations
default [ 10% ] 10 VUs 02.0s/20s
running (03.0s), 10/10 VUs, 50 complete and 0 interrupted iterations
default [ 15% ] 10 VUs 03.0s/20s
running (04.0s), 10/10 VUs, 70 complete and 0 interrupted iterations
default [ 20% ] 10 VUs 04.0s/20s
running (05.0s), 10/10 VUs, 90 complete and 0 interrupted iterations
default [ 25% ] 10 VUs 05.0s/20s
running (06.0s), 10/10 VUs, 110 complete and 0 interrupted iterations
default [ 30% ] 10 VUs 06.0s/20s
running (07.0s), 10/10 VUs, 130 complete and 0 interrupted iterations
default [ 35% ] 10 VUs 07.0s/20s
running (08.0s), 10/10 VUs, 150 complete and 0 interrupted iterations
default [ 40% ] 10 VUs 08.0s/20s
running (09.0s), 10/10 VUs, 170 complete and 0 interrupted iterations
default [ 45% ] 10 VUs 09.0s/20s
running (10.0s), 10/10 VUs, 190 complete and 0 interrupted iterations
default [ 50% ] 10 VUs 10.0s/20s
running (11.0s), 10/10 VUs, 210 complete and 0 interrupted iterations
default [ 55% ] 10 VUs 11.0s/20s
running (12.0s), 10/10 VUs, 230 complete and 0 interrupted iterations
default [ 60% ] 10 VUs 12.0s/20s
running (13.0s), 10/10 VUs, 250 complete and 0 interrupted iterations
default [ 65% ] 10 VUs 13.0s/20s
running (14.0s), 10/10 VUs, 270 complete and 0 interrupted iterations
default [ 70% ] 10 VUs 14.0s/20s
running (15.0s), 10/10 VUs, 290 complete and 0 interrupted iterations
default [ 75% ] 10 VUs 15.0s/20s
running (16.0s), 10/10 VUs, 310 complete and 0 interrupted iterations
default [ 80% ] 10 VUs 16.0s/20s
running (17.0s), 10/10 VUs, 330 complete and 0 interrupted iterations
default [ 85% ] 10 VUs 17.0s/20s
running (18.0s), 10/10 VUs, 350 complete and 0 interrupted iterations
default [ 90% ] 10 VUs 18.0s/20s
running (19.0s), 10/10 VUs, 370 complete and 0 interrupted iterations
default [ 95% ] 10 VUs 19.0s/20s
running (20.0s), 10/10 VUs, 390 complete and 0 interrupted iterations
default [ 100% ] 10 VUs 20.0s/20s
█ THRESHOLDS
http_req_duration
✓ 'p(95)<50' p(95)=2.45ms
█ TOTAL RESULTS
checks_total.......: 800 39.814136/s
checks_succeeded...: 100.00% 800 out of 800
checks_failed......: 0.00% 0 out of 800
✓ status is 200
✓ response time < 50ms (Redis)
HTTP
http_req_duration..............: avg=1.54ms min=380.37µs med=1.06ms max=17.07ms p(90)=1.56ms p(95)=2.45ms
{ expected_response:true }...: avg=1.54ms min=380.37µs med=1.06ms max=17.07ms p(90)=1.56ms p(95)=2.45ms
http_req_failed................: 0.00% 0 out of 400
http_reqs......................: 400 19.907068/s
EXECUTION
iteration_duration.............: avg=502.31ms min=500.58ms med=501.98ms max=517.74ms p(90)=502.51ms p(95)=503.44ms
iterations.....................: 400 19.907068/s
vus............................: 10 min=10 max=10
vus_max........................: 10 min=10 max=10
NETWORK
data_received..................: 67 kB 3.3 kB/s
data_sent......................: 40 kB 2.0 kB/s
running (20.1s), 00/10 VUs, 400 complete and 0 interrupted iterations
default ✓ [ 100% ] 10 VUs 20s
+33 -5
View File
@@ -2,7 +2,7 @@
set -e
BASE_URL=${BASE_URL:-"http://localhost:8080"}
BASE_URL=${BASE_URL:-"http://119.28.87.231:8080"}
OUTPUT_DIR="./benchmark/results"
TIMESTAMP=$(date +%Y%m%d_%H%M%S)
@@ -49,11 +49,38 @@ check_prerequisites() {
fi
print_success "服务正常运行: ${BASE_URL}"
print_info "准备测试数据..."
curl -s -X POST "${BASE_URL}/api/posts" \
-H "Content-Type: application/json" \
-d '{"content": "Benchmark Test Post"}' > /dev/null || true
echo ""
}
prepare_test_data() {
print_header "准备测试数据"
print_info "创建测试帖子..."
for i in {1..5}; do
curl -s -X POST "${BASE_URL}/api/posts" \
-H "Content-Type: application/json" \
-d "{\"content\": \"Benchmark Test Post $i\"}" > /dev/null
done
print_success "已创建 5 个测试帖子"
print_info "创建报告数据(用于 ZSET+HASH 测试)..."
for i in {1..1000}; do
curl -s -X POST "${BASE_URL}/api/reports?title=Report%20$i&content=Content%20$i&hotScore=$((RANDOM % 10000))" > /dev/null
if [ $((i % 200)) -eq 0 ]; then
print_info " 已创建 $i 条报告..."
fi
done
print_success "已创建 1000 条报告"
print_info "预加载报告数据到 Redis..."
PRELOAD_RESP=$(curl -s -X POST "${BASE_URL}/api/reports/preload?count=10000")
print_info "预加载响应: ${PRELOAD_RESP}"
print_info "验证 Redis 缓存数据..."
HOT_RESP=$(curl -s "${BASE_URL}/api/reports/hot?page=0&size=5")
echo " 热门报告响应: ${HOT_RESP:0:100}..."
print_success "测试数据准备完成"
echo ""
}
@@ -137,6 +164,7 @@ main() {
echo ""
check_prerequisites
prepare_test_data
print_info "开始执行压测..."
echo ""
+22 -3
View File
@@ -13,10 +13,29 @@ export const options = {
};
const BASE_URL = __ENV.BASE_URL || 'http://localhost:8080';
const POST_ID = 1;
export default function () {
const res = http.post(`${BASE_URL}/api/posts/${POST_ID}/like/direct`);
export function setup() {
const res = http.post(`${BASE_URL}/api/posts`, JSON.stringify({
content: 'Like Benchmark Test Post A'
}), {
headers: { 'Content-Type': 'application/json' },
});
if (res.status !== 200) {
throw new Error(`Failed to create post: ${res.status} ${res.body}`);
}
const body = res.json();
if (!body.data || !body.data.id) {
throw new Error(`Invalid response: ${res.body}`);
}
console.log(`Created post with ID: ${body.data.id}`);
return { postId: body.data.id };
}
export default function (data) {
const res = http.post(`${BASE_URL}/api/posts/${data.postId}/like/direct`);
check(res, {
'status is 200': (r) => r.status === 200,
+22 -3
View File
@@ -13,10 +13,29 @@ export const options = {
};
const BASE_URL = __ENV.BASE_URL || 'http://localhost:8080';
const POST_ID = 1;
export default function () {
const res = http.post(`${BASE_URL}/api/posts/${POST_ID}/like`);
export function setup() {
const res = http.post(`${BASE_URL}/api/posts`, JSON.stringify({
content: 'Like Benchmark Test Post B'
}), {
headers: { 'Content-Type': 'application/json' },
});
if (res.status !== 200) {
throw new Error(`Failed to create post: ${res.status} ${res.body}`);
}
const body = res.json();
if (!body.data || !body.data.id) {
throw new Error(`Invalid response: ${res.body}`);
}
console.log(`Created post with ID: ${body.data.id}`);
return { postId: body.data.id };
}
export default function (data) {
const res = http.post(`${BASE_URL}/api/posts/${data.postId}/like`);
check(res, {
'status is 200': (r) => r.status === 200,
+23 -3
View File
@@ -11,14 +11,34 @@ export const options = {
const BASE_URL = __ENV.BASE_URL || 'http://localhost:8080';
export default function () {
const res = http.get(`${BASE_URL}/api/posts/1`);
export function setup() {
const res = http.post(`${BASE_URL}/api/posts`, JSON.stringify({
content: 'Cache Consistency Test Post'
}), {
headers: { 'Content-Type': 'application/json' },
});
if (res.status !== 200) {
throw new Error(`Failed to create post: ${res.status} ${res.body}`);
}
const body = res.json();
if (!body.data || !body.data.id) {
throw new Error(`Invalid response: ${res.body}`);
}
console.log(`Created post with ID: ${body.data.id}`);
return { postId: body.data.id };
}
export default function (data) {
const res = http.get(`${BASE_URL}/api/posts/${data.postId}`);
check(res, {
'status is 200': (r) => r.status === 200,
'has data': (r) => {
try {
const body = JSON.parse(r.body);
const body = r.json();
return body.code === 200 && body.data !== null;
} catch {
return false;
@@ -4,7 +4,7 @@ import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.data.redis.connection.RedisConnectionFactory;
import org.springframework.data.redis.core.RedisTemplate;
import org.springframework.data.redis.serializer.Jackson2JsonRedisSerializer;
import org.springframework.data.redis.serializer.GenericJackson2JsonRedisSerializer;
import org.springframework.data.redis.serializer.StringRedisSerializer;
@Configuration
@@ -16,7 +16,7 @@ public class RedisConfig {
template.setConnectionFactory(connectionFactory);
StringRedisSerializer stringSerializer = new StringRedisSerializer();
Jackson2JsonRedisSerializer<Object> jsonSerializer = new Jackson2JsonRedisSerializer<>(Object.class);
GenericJackson2JsonRedisSerializer jsonSerializer = new GenericJackson2JsonRedisSerializer();
template.setKeySerializer(stringSerializer);
template.setHashKeySerializer(stringSerializer);