ソースを参照

fix: no clear persistent_term: channels

yr 2 年 前
コミット
1e74b60922
1 ファイル変更1 行追加0 行削除
  1. 1 0
      src/emqx_plugin_kafka_producer.erl

+ 1 - 0
src/emqx_plugin_kafka_producer.erl

@@ -75,6 +75,7 @@ on_stop(_InstId, #{client_id := ClientId, channels := Channels}) ->
     }),
     maps:foreach(fun(_, ChannelState) -> remove_producers(ClientId, ChannelState) end, Channels),
     deallocate_client(ClientId),
+    persistent_term:erase({?EMQX_PLUGIN_KAFKA_APP, ?EMQX_PLUGIN_KAFKA_CHANNELS}),
     ok.
 
 on_add_channel(