Add WS stats
This commit is contained in:
parent
a183693ac8
commit
35d821a62e
|
@ -59,7 +59,9 @@
|
||||||
'subscribers/count',
|
'subscribers/count',
|
||||||
'subscribers/max',
|
'subscribers/max',
|
||||||
'subscriptions/count',
|
'subscriptions/count',
|
||||||
'subscriptions/max'
|
'subscriptions/max',
|
||||||
|
'subscriptions/shared/count',
|
||||||
|
'subscriptions/shared/max'
|
||||||
]).
|
]).
|
||||||
|
|
||||||
-define(ROUTE_STATS, [
|
-define(ROUTE_STATS, [
|
||||||
|
|
|
@ -131,9 +131,9 @@ stat_fun() ->
|
||||||
fun() -> {ok, get(recv_oct)} end.
|
fun() -> {ok, get(recv_oct)} end.
|
||||||
|
|
||||||
websocket_handle({binary, <<>>}, State) ->
|
websocket_handle({binary, <<>>}, State) ->
|
||||||
{ok, State};
|
{ok, ensure_stats_timer(State)};
|
||||||
websocket_handle({binary, [<<>>]}, State) ->
|
websocket_handle({binary, [<<>>]}, State) ->
|
||||||
{ok, State};
|
{ok, ensure_stats_timer(State)};
|
||||||
websocket_handle({binary, Data}, State = #state{parser_state = ParserState,
|
websocket_handle({binary, Data}, State = #state{parser_state = ParserState,
|
||||||
proto_state = ProtoState}) ->
|
proto_state = ProtoState}) ->
|
||||||
BinSize = iolist_size(Data),
|
BinSize = iolist_size(Data),
|
||||||
|
|
Loading…
Reference in New Issue