K2InformaticsGmbH / dderl

Web based Data Explorer / Data Jump Station with Erlang In-Memory Support
Apache License 2.0
23 stars 12 forks source link

tailing on a table does not show deletions #623

Closed shamis closed 5 years ago

shamis commented 5 years ago

Deleted records are not shown by red and line across the record. After the delete action the table is not usable any more. None of the button (reload, stop, play etc) does not work

stoch commented 5 years ago

probably related error log:

dderl_session received unknown msg {'EXIT',<0.16645.87>,{badarg,[{erlang,length,[<0.15932.87>],[]},{dderl_fsm,data_append,3,[{file,"d:/build/sbsgui/_build/default/lib/dderl/src/dderl_fsm.erl"},{line,2692}]},{dderl_fsm,tailing,3,[{file,"d:/build/sbsgui/_build/default/lib/dderl/src/dderl_fsm.erl"},{line,1047}]},{gen_statem,call_state_function,5,[{file,"gen_statem.erl"},{line,1240}]},{gen_statem,loop_event,6,[{file,"gen_statem.erl"},{line,1012}]},{proc_lib,init_p_do_apply,3,[{file,"proc_lib.erl"},{line,247}]}]}} for <<"system">>
c-bik commented 5 years ago

Confirmed and locally re produced!

@stoch

probably related error log:

dderl_session received unknown msg {'EXIT',<0.16645.87>,
{badarg,[{erlang,length,[<0.15932.87>],[]},
{dderl_fsm,data_append,3,[{file,"dderl/src/dderl_fsm.erl"},{line,2692}]},
{dderl_fsm,tailing,3,[{file,"dderl/src/dderl_fsm.erl"},{line,1047}]},
{gen_statem,call_state_function,5,[{file,"gen_statem.erl"},{line,1240}]},
{gen_statem,loop_event,6,[{file,"gen_statem.erl"},{line,1012}]},
{proc_lib,init_p_do_apply,3,[{file,"proc_lib.erl"},{line,247}]}]}}
for <<"system">>

Do not have this crash, what happening instead when any other table operation on the locked table is attempted:

2019-09-19 12:42:12.089 [error] [dderl<0.2709.0>@dderl_session:spawn_process_call:666]
 Problem processing command:
exit:{noproc,{gen_statem,call,[<0.1155.0>,{"get_columns"},infinity]}}
[{<<"button">>,[{<<"connection">>,
<<"g2gCZAAPZXJsaW1lbV9zZXNzaW9uZ2QAEGRkZXJsMUAxMjcuMC4wLjEAAAOVAAAAAAM=">>},
{<<"statement">>,
<<"g2gCZAAJZGRlcmxfZnNtZ2QAEGRkZXJsMUAxMjcuMC4wLjEAAASDAAAAAAM=">>},
{<<"binds">>,null},{<<"btn">>,<<"restart">>}]}]
[{gen,do_call,4,[{file,"gen.erl"},{line,177}]},
{gen_statem,call,3,[{file,"gen_statem.erl"},{line,461}]},
{imem_adapter,gui_resp_cb_fun,3,[{file,"dderl/src/imem_adapter.erl"},{line,736}]},
{imem_adapter,process_cmd,6,[{file,"dderl/src/imem_adapter.erl"},{line,593}]},
{dderl_session,spawn_process_call,8,[{file,"dderl/src/dderl_session.erl"},{line,663}]}]
c-bik commented 5 years ago

On delete

[error] [<0.6321.0>@dderl_fsm:data_append:2692] gen_statem <0.6321.0>
 in state tailing terminated with reason: bad argument in call to erlang:length(<0.6320.0>)
 in dderl_fsm:data_append/3 line 2692
[error] [dderl<0.916.0>@dderl_session:handle_info:191] dderl_session received unknown msg
 {'EXIT',<0.6321.0>,{badarg,[{erlang,length,[<0.6320.0>],[]},
{dderl_fsm,data_append,3,[{file,"dderl/src/dderl_fsm.erl"},{line,2692}]},
{dderl_fsm,tailing,3,[{file,"dderl/src/dderl_fsm.erl"},{line,1047}]},
{gen_statem,call_state_function,5,[{file,"gen_statem.erl"},{line,1240}]},
{gen_statem,loop_event,6,[{file,"gen_statem.erl"},{line,1012}]},
{proc_lib,init_p_do_apply,3,[{file,"proc_lib.erl"},{line,247}]}]}}
for <<"system">>
[error] [<0.6321.0>@dderl_fsm:data_append:2692] CRASH REPORT
 Process <0.6321.0> with 0 neighbours crashed with reason: bad argument
 in call to erlang:length(<0.6320.0>) in dderl_fsm:data_append/3 line 2692