mirror of
https://github.com/bluenviron/mediamtx.git
synced 2026-01-22 19:39:48 -08:00
metrics: allow filtering metrics (#953) (#4809)
Some checks are pending
code_lint / golangci_lint (push) Waiting to run
code_lint / mod_tidy (push) Waiting to run
code_lint / api_docs (push) Waiting to run
code_test / test_64 (push) Waiting to run
code_test / test_32 (push) Waiting to run
code_test / test_e2e (push) Waiting to run
Some checks are pending
code_lint / golangci_lint (push) Waiting to run
code_lint / mod_tidy (push) Waiting to run
code_lint / api_docs (push) Waiting to run
code_test / test_64 (push) Waiting to run
code_test / test_32 (push) Waiting to run
code_test / test_e2e (push) Waiting to run
This commit is contained in:
parent
21404a6821
commit
cc48fdb2b8
4 changed files with 531 additions and 198 deletions
|
|
@ -74,6 +74,9 @@ func TestMetrics(t *testing.T) {
|
|||
bo := httpPullFile(t, hc, "http://localhost:9998/metrics")
|
||||
|
||||
require.Equal(t, `paths 0
|
||||
paths_bytes_received 0
|
||||
paths_bytes_sent 0
|
||||
paths_readers 0
|
||||
hls_muxers 0
|
||||
hls_muxers_bytes_sent 0
|
||||
rtsp_conns 0
|
||||
|
|
@ -490,6 +493,10 @@ webrtc_sessions_rtcp_packets_sent 0
|
|||
|
||||
bo := httpPullFile(t, hc, "http://localhost:9998/metrics")
|
||||
|
||||
require.Equal(t, "paths 0\n", string(bo))
|
||||
require.Equal(t, "paths 0\n"+
|
||||
"paths_bytes_received 0\n"+
|
||||
"paths_bytes_sent 0\n"+
|
||||
"paths_readers 0\n",
|
||||
string(bo))
|
||||
})
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue