mtproto_proxy icon indicating copy to clipboard operation
mtproto_proxy copied to clipboard

Crash when one of the keys of replay_check_session_storage_opts is not set

Open seriyps opened this issue 4 years ago • 0 comments

Proxy crashes with

{function_clause,
 [{mtp_session_storage,do_clean,[mtp_session_storage,mtp_session_storage_histogram,
  #{max_age_minutes => 43200,max_memory_mb => 4096},count], 
  [{file,"/opt/mtproto_proxy/src/mtp_session_storage.erl"},{line,154}]},
 {lists,filtermap,2,[{file,"lists.erl"},{line,1317}]},
 {mtp_session_storage,handle_info,2,[{file,"/opt/mtproto_proxy/src/mtp_session_storage.erl"},{line,110}]},
 {gen_server,try_dispatch,4,[{file,"gen_server.erl"},{line,616}]},
 {gen_server,handle_msg,6,[{file,"gen_server.erl"},{line,686}]},
 {proc_lib,init_p_do_apply,3,[{file,"proc_lib.erl"},{line,247}]}]}

if some of the keys of replay_check_session_storage_opts config is not set. Eg:

{replay_check_session_storage_opts,
 #{max_age_minutes => 43200,
   max_memory_mb => 4096}  % max_count is not set

seriyps avatar Apr 21 '20 00:04 seriyps