riak C:get() 后台跑出异常 > in state waiting_vnode_r terminated with re
(riaktest@127.0.0.1)6> O0 = riak_object:new(<<"groceries">>, <<"mine">>, ["bread"]). O0 = riak_object:new(<<"groceries">>, <<"mine">>, ["bread"]). {r_object,<<"groceries">>,<<"mine">>, [{r_content,{dict,0,16,16,8,80,48, {[],[],[],[],[],[],[],[],[],[],[],[],[],[],...}, {{[],[],[],[],[],[],[],[],[],[],[],[],...}}}, ["bread"]}], [], {dict,1,16,16,8,80,48, {[],[],[],[],[],[],[],[],[],[],[],[],[],[],[],...}, {{[],[],[],[],[],[],[],[],[],[],[],[],[],...}}}, undefined} (riaktest@127.0.0.1)3> C:put(O0, 1).
{ok, O1} = C:get(<<"groceries">>, <<"mine">>, 1).
?
看了一下源码 源码要求
riak_object:new(<<"groceries">>, <<"mine">>, ["bread"]). 三个参数是binary类型
这里比较奇怪 list竟然能存储,读取也能读取,只是riak后台抛出错误。当大量操作时就。。。。
?
eason bad argument in call to erlang:size([{set,1,16,16,8,80,48,{[],[],[],[],[],[],[],[],[],[],[],[],[],[],[],[]},{{[],[],[],[],[],[],[],...}}}]) in riak_kv_get_fsm:'-update_stats/2-lc$^0/1-0-'/1 in context child_terminated
11:15:20.486 [error] gen_fsm <0.6199.10> in state waiting_vnode_r terminated with reason: bad argument in call to erlang:size([{set,1,16,16,8,80,48,{[],[],[],[],[],[],[],[],[],[],[],[],[],[],[],[]},{{[],[<<131,104,2,...>>],...}}}]) in riak_kv_get_fsm:'-update_stats/2-lc$^0/1-0-'/1
11:15:20.495 [error] CRASH REPORT Process <0.6199.10> with 0 neighbours crashed with reason: bad argument in call to erlang:size([{set,1,16,16,8,80,48,{[],[],[],[],[],[],[],[],[],[],[],[],[],[],[],[]},{{[],[<<131,104,2,...>>],...}}}]) in riak_kv_get_fsm:'-update_stats/2-lc$^0/1-0-'/1
11:15:20.511 [error] Supervisor riak_kv_get_fsm_sup had child undefined started with {riak_kv_get_fsm,start_link,undefined} at <0.6199.10> exit with reason bad argument in call to erlang:size([{set,1,16,16,8,80,48,{[],[],[],[],[],[],[],[],[],[],[],[],[],[],[],[]},{{[],[<<131,104,2,...>>],...}}}]) in riak_kv_get_fsm:'-update_stats/2-lc$^0/1-0-'/1 in context child_terminated