Merge pull request #6850 from DDDHuang/rename_mestics

fix(metrics): client metrics key name
This commit is contained in:
tigercl 2022-01-25 17:56:49 +08:00 committed by GitHub
commit 55751b5854
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 3 additions and 3 deletions

View File

@ -58,7 +58,7 @@ insert_user(User = #emqx_user{login = Login}) ->
[_|_] -> mnesia:abort(existed) [_|_] -> mnesia:abort(existed)
end. end.
-spec(add_default_user(clientid | username, tuple(), binary()) -> ok | {error, any()}). -spec(add_default_user(clientid | username, binary(), binary()) -> ok | {error, any()}).
add_default_user(Type, Key, Password) -> add_default_user(Type, Key, Password) ->
Login = {Type, Key}, Login = {Type, Key},
case add_user(Login, Password) of case add_user(Login, Password) of

View File

@ -122,7 +122,7 @@
, 'recv_msg.qos1' , 'recv_msg.qos1'
, 'recv_msg.qos2' , 'recv_msg.qos2'
, 'recv_msg.dropped' , 'recv_msg.dropped'
, 'recv_msg.dropped.expired' , 'recv_msg.dropped.await_pubrel_timeout'
, send_pkt , send_pkt
, send_msg , send_msg
, 'send_msg.qos0' , 'send_msg.qos0'

View File

@ -687,7 +687,7 @@ inc_delivery_expired_cnt(N) ->
inc_await_pubrel_timeout(N) -> inc_await_pubrel_timeout(N) ->
ok = inc_pd('recv_msg.dropped', N), ok = inc_pd('recv_msg.dropped', N),
ok = inc_pd('recv_msg.dropped.expired', N), ok = inc_pd('recv_msg.dropped.await_pubrel_timeout', N),
ok = emqx_metrics:inc('messages.dropped', N), ok = emqx_metrics:inc('messages.dropped', N),
emqx_metrics:inc('messages.dropped.await_pubrel_timeout', N). emqx_metrics:inc('messages.dropped.await_pubrel_timeout', N).