Skip to content

Commit

Permalink
Apply comments from review
Browse files Browse the repository at this point in the history
Use a smaller key for the persistent_terms map, and remove unreachable
code.
  • Loading branch information
NelsonVides committed May 20, 2022
1 parent d9c72a3 commit 2bf64f6
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions src/metrics/mongoose_metrics.erl
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@
remove_host_type_metrics/1, get_report_interval/0,
sample_metric/1]).

-define(PREFIXES, {?MODULE, prefixes}).
-define(PREFIXES, mongoose_metrics_prefixes).
-define(DEFAULT_REPORT_INTERVAL, 60000). %%60s

-type use_or_skip() :: use | skip.
Expand Down Expand Up @@ -216,8 +216,6 @@ get_host_type_prefix(HostType) when is_binary(HostType) ->
#{} -> make_host_type_prefix(HostType)
end.

make_host_type_prefix(global) ->
global;
make_host_type_prefix(HT) when is_binary(HT) ->
binary:replace(HT, <<" ">>, <<"_">>, [global]).

Expand Down

0 comments on commit 2bf64f6

Please sign in to comment.