فهرست منبع

chore: list throttled log events in the change-log

Serge Tupchii 1 سال پیش
والد
کامیت
5d4c85cd84
2فایلهای تغییر یافته به همراه8 افزوده شده و 2 حذف شده
  1. 2 2
      apps/emqx/include/logger.hrl
  2. 6 0
      changes/ce/feat-12520.en.md

+ 2 - 2
apps/emqx/include/logger.hrl

@@ -59,8 +59,6 @@
 -define(TRACE_FILTER, emqx_trace_filter).
 -define(TRACE_FILTER, emqx_trace_filter).
 -define(OWN_KEYS, [level, filters, filter_default, handlers]).
 -define(OWN_KEYS, [level, filters, filter_default, handlers]).
 
 
--define(TRACE(Tag, Msg, Meta), ?TRACE(debug, Tag, Msg, Meta)).
-
 %% Internal macro
 %% Internal macro
 -define(_DO_TRACE(Tag, Msg, Meta),
 -define(_DO_TRACE(Tag, Msg, Meta),
     case persistent_term:get(?TRACE_FILTER, []) of
     case persistent_term:get(?TRACE_FILTER, []) of
@@ -73,6 +71,8 @@
     end
     end
 ).
 ).
 
 
+-define(TRACE(Tag, Msg, Meta), ?TRACE(debug, Tag, Msg, Meta)).
+
 %% Only evaluate when necessary
 %% Only evaluate when necessary
 -define(TRACE(Level, Tag, Msg, Meta), begin
 -define(TRACE(Level, Tag, Msg, Meta), begin
     ?_DO_TRACE(Tag, Msg, Meta),
     ?_DO_TRACE(Tag, Msg, Meta),

+ 6 - 0
changes/ce/feat-12520.en.md

@@ -1,2 +1,8 @@
 Implement log throttling. The feature reduces the number of potentially flooding logged events by
 Implement log throttling. The feature reduces the number of potentially flooding logged events by
 dropping all but the first event within a configured time window.
 dropping all but the first event within a configured time window.
+Throttling is applied to the following log events:
+ - authorization_permission_denied,
+ - cannot_publish_to_topic_due_to_not_authorized,
+ - cannot_publish_to_topic_due_to_quota_exceeded,
+ - connection_rejected_due_to_license_limit_reached,
+ - dropped_msg_due_to_mqueue_is_full.