<html><head></head><body bgcolor="#FFFFFF"><div>Please try only start/2, not the start_link/2, since every error in shell will cause the process exit.<br><br>Best regards,<div>Zheng Zhibin</div></div><div><br>在 2011-11-15,上午12:10,Geeth Narayanan <<a href="mailto:gnarayan1@gmail.com">gnarayan1@gmail.com</a>> 写道:<br><br></div><div></div><blockquote type="cite"><div><div>Zheng,</div><div><br></div><div>Thanks for your reply. I tried the term_to_binary on It and still get the error below.</div><div>Is there anyplace I can look to get more details on the exception.</div><div><br></div><div>
<br></div><div>** exception exit: {noproc,</div><div>                       {gen_server,call,</div><div>                           [<0.39.0>,</div><div>                            {req,</div><div>                                {rpbputreq,<<"Items">>,<<"Item1">>,undefined,</div>
<div>                                    {rpbcontent,</div><div>                                        <<131,104,4,100,0,4,105,116,101,109,97,1,</div><div>                                          107,...>>,</div>
<div>                                        undefined,undefined,undefined,undefined,</div><div>                                        undefined,undefined,undefined,undefined,</div><div>                                        undefined},</div>
<div>                                    undefined,undefined,undefined,undefined,</div><div>                                    undefined,undefined,undefined},</div><div>                                60000},</div><div>                            infinity]}}</div>
<div>     in function  gen_server:call/3</div><div><br></div><div>Thanks.</div><div>Geeth</div><div><br></div><br><div class="gmail_quote">2011/11/12 Zheng Zhibin <span dir="ltr"><<a href="mailto:witeman.g@gmail.com">witeman.g@gmail.com</a>></span><br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;"><div bgcolor="#FFFFFF"><div>Both the bucket name, key, and value should be binary format<br><br>Best regards,<div>Zheng Zhibin</div>
</div><div><br>在 2011-11-13,上午6:19,Geeth Narayanan <<a href="mailto:gnarayan1@gmail.com" target="_blank">gnarayan1@gmail.com</a>> 写道:<br><br></div><div class="im"><div></div><blockquote type="cite"><div><div>Hi,</div>
<div><br></div><div>I am trying to put some erlang record item to my dev riak nodes. I get the following error at the bottom. Can you please help?</div><div><br></div><div>1> code:which(riakc_pb_socket).</div>
<div>"/Users/geeth/Apps/riak-erlang-client/ebin/riakc_pb_socket.beam"</div><div><br></div><div>2> {ok, Pid} = riakc_pb_socket:start_link("127.0.0.1", 8081).</div><div>{ok,<0.34.0>}</div><div>
<br>
</div><div>3> rd(item, {id, name, desc}).     </div><div>item</div><div><br></div><div>4>     </div><div>4> It = #item{id=1, name="Item1", desc="Some desc"}.</div><div>#item{id = 1,name = "Item1",desc = "Some desc"}</div>

<div><br></div><div>5> MyRec = riakc_obj:new(<<"Items">>, list_to_binary(integer_to_list(It#<a href="http://item.id" target="_blank">item.id</a>)), It).   </div><div>{riakc_obj,<<"Items">>,<<"1">>,undefined,[],undefined,</div>

<div>           #item{id = 1,name = "Item1",desc = "Some desc"}}</div><div><br></div></div></blockquote></div>Try term_to_binary(It)<div class="im"><br><blockquote type="cite"><div><div>6> Rec = riakc_pb_socket:put(Pid, MyRec).</div>
<div>** exception exit: {noproc,</div><div>                    {gen_server,call,</div>
<div>                     [<0.34.0>,</div><div>                      {req,</div><div>                       {rpbputreq,<<"Items">>,<<"1">>,undefined,</div><div>                        {rpbcontent,</div>

<div>                         <<131,104,4,100,0,4,105,116,101,109,97,1,107,...>>,</div><div>                         "application/x-erlang-binary",undefined,undefined,</div><div>                         undefined,undefined,undefined,undefined,undefined,</div>

<div>                         undefined},</div><div>                        undefined,undefined,undefined,undefined,undefined,</div><div>                        undefined,undefined},</div><div>                       60000},</div>

<div>                      infinity]}}</div><div>     in function  gen_server:call/3</div><div><br></div><div><div><br>Thanks.</div><div>Geeth</div></div>
</div></blockquote></div><blockquote type="cite"><div><span>_______________________________________________</span><br><span>riak-users mailing list</span><br><span><a href="mailto:riak-users@lists.basho.com" target="_blank">riak-users@lists.basho.com</a></span><br>
<span><a href="http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com" target="_blank">http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com</a></span><br></div></blockquote></div></blockquote></div>
<br>
</div></blockquote></body></html>