fix(relup): get broker metrics

This commit is contained in:
Turtle 2021-08-27 14:06:07 +08:00 committed by turtleDeng
parent ea15aa3f9e
commit 7bcc67f95d
1 changed files with 8 additions and 1 deletions

View File

@ -67,7 +67,7 @@
!./bin/emqx_ctl rules create 'SELECT * FROM "t/#"' '[{"name":"data_to_webserver", "params": {"$$resource": "resource:691c29ba"}}]' !./bin/emqx_ctl rules create 'SELECT * FROM "t/#"' '[{"name":"data_to_webserver", "params": {"$$resource": "resource:691c29ba"}}]'
?created ?created
?SH-PROMPT ?SH-PROMPT
?sleep 5 !sleep 5
?SH-PROMPT ?SH-PROMPT
[shell emqx] [shell emqx]
@ -77,6 +77,8 @@
!./bin/emqx_ctl rules list !./bin/emqx_ctl rules list
?691c29ba ?691c29ba
?SH-PROMPT ?SH-PROMPT
!./bin/emqx_ctl broker metrics | grep "messages.publish"
???SH-PROMPT
[shell bench] [shell bench]
!cd $BENCH_PATH !cd $BENCH_PATH
@ -140,6 +142,11 @@
!sleep 30 !sleep 30
?SH-PROMPT ?SH-PROMPT
[shell emqx]
!./bin/emqx_ctl broker metrics | grep "messages.publish"
???SH-PROMPT
[shell bench]
!curl --user admin:public --silent --show-error http://localhost:8081/api/v4/rules | jq --raw-output ".data[0].metrics[] | select(.node==\"emqx@127.0.0.1\").matched" !curl --user admin:public --silent --show-error http://localhost:8081/api/v4/rules | jq --raw-output ".data[0].metrics[] | select(.node==\"emqx@127.0.0.1\").matched"
?300 ?300
?SH-PROMPT ?SH-PROMPT