Hi Emil, 2010/6/11 Емил Иванов / Emil Ivanov <[email protected]>: > Hi, > > I am looking for a way to insert an object and have the key > autogenerated. I know that via the REST interface if I omit the key > one will be created for me, but how do I do that with the erlang > client? >
You have to generate a key. The generator that's used when doing a POST on a bucket is riak_core_util:unique_id_62() which you could reuse if you like. > Also, are there any restrictions on the keys (like length, only ascii, etc.)? > My understanding is that though there isn't a specific limit, in practice you'll want to restrict your keys to something URL safe so the HTTP interface can be used. Also if you're using the Innostore backend, a maximum length of 255 bytes applies. Regards, Andrew > Regards, > Emil > > -- > My place to share my ideas: > http://bolddream.com (now live :) > > _______________________________________________ > riak-users mailing list > [email protected] > http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com > _______________________________________________ riak-users mailing list [email protected] http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com
