emqtt-bench icon indicating copy to clipboard operation
emqtt-bench copied to clipboard

Will autoreconnection option be added into emqtt-bench?

Open mcoder2014 opened this issue 4 years ago • 0 comments

It seems that some device simulator would crashed when doing bench test. Will you add autoreconnect option in emqtt_bench?

It may have some help to judge if the emqx server can serve so many device and throughout.

=ERROR REPORT==== 21-Apr-2020::11:24:50.542652 ===
** State machine <0.20097.0> terminating
** Last event = {cast,{mqtt_packet,{mqtt_packet_header,14,false,0,false},
                                   {mqtt_packet_disconnect,141,#{}},
                                   undefined}}
** When server state  = {connected,
                            {state,undefined,<0.20096.0>,undefined,
                                "127.0.0.1",1883,[],emqtt_sock,#Port<0.19991>,
                                [],60000,false,
                                <<"n227-020-138_bench_sub_8_3858259646">>,
                                true,<<"chaoqun">>,<<"123456">>,5,<<"MQTT">>,
                                300,#Ref<0.1290390736.2687238147.149946>,
                                false,false,false,
                                {mqtt_msg,0,false,false,undefined,undefined,
                                    undefined,undefined},
                                #{'Maximum-Packet-Size' => 1048576,
                                  'Maximum-QoS' => 2,'Retain-Available' => 1,
                                  'Shared-Subscription-Available' => 1,
                                  'Subscription-Identifier-Available' => 1,
                                  'Topic-Alias-Maximum' => 65535,
                                  'Wildcard-Subscription-Available' => 1},
                                [],
                                #{<<"ota/8/server/upgrade">> =>
                                      #{nl => 0,qos => 1,rap => 0,rh => 0}},
                                infinity,#{},#{},true,30000,undefined,0,
                                undefined,0,5,
                                {none,#{max_size => 268435455,version => 5}}}}
** Reason for termination = exit:{disconnected,141,#{}}
** Callback modules = [emqtt]
** Callback mode = state_functions
** Stacktrace =
**  [{gen_statem,loop_state_callback_result,11,
                 [{file,"gen_statem.erl"},{line,1312}]},
     {proc_lib,wake_up,3,[{file,"proc_lib.erl"},{line,259}]}]

=CRASH REPORT==== 21-Apr-2020::11:24:50.543313 ===
  crasher:
    initial call: emqtt:init/1
    pid: <0.20097.0>
    registered_name: []
    exception exit: {disconnected,141,#{}}
      in function  gen_statem:loop_state_callback_result/11 (gen_statem.erl, line 1312)
    ancestors: [<0.20096.0>]
    message_queue_len: 0
    messages: []
    links: [<0.20096.0>]
    dictionary: [{send_oct,97}]
    trap_exit: true
    status: running
    heap_size: 4185
    stack_size: 27
    reductions: 139686
  neighbours:

mcoder2014 avatar Apr 21 '20 03:04 mcoder2014