Loading links after a map phase in a map reduce query

2010-10-07 Thread Jan Metzner
Hi folks, i am experimenting with riak and have a problem with too many links in a riak object. If i store the object the server send 400 Bad Request. This is caused from the link header which is too long. As workaround i thought about storing the links inside the riak object and fetch them in a m

Re: Loading links after a map phase in a map reduce query

2010-10-07 Thread Robin Edwards
What is the hard limit on links, through the REST API? Would it be possible to have an object with say 300,000 links? Or is this a terrible idea, R On 7 October 2010 13:50, Jan Metzner wrote: > Hi folks, > > i am experimenting with riak and have a problem with too many links in a > riak objec

Re: Loading links after a map phase in a map reduce query

2010-10-07 Thread Sean Cribbs
Jan, It is possible to do a link phase after a map phase, if your map phase outputs lists of [bucket,key] pairs. However, the semantics of the link phase will be to load those specified objects and follow *their* links. If you just want to extract the links from the body of your first object

Re: Loading links after a map phase in a map reduce query

2010-10-07 Thread Sean Cribbs
300,000 links is probably too large (at least for HTTP). At that scale, I would consider building tree-like structure where target objects are only linked off of the leaves of the tree. Sean Cribbs Developer Advocate Basho Technologies, Inc. http://basho.com/ On Oct 7, 2010, at 9:06 AM, Robin

Re: Loading links after a map phase in a map reduce query

2010-10-07 Thread Jan Metzner
Patching the java client did the job. For anyone who is interesed in the patch here are the links: http://github.com/jmetzner/riak-java-client/commit/61aa7df0a7314a673ca18f286a39108ad2d7 http://github.com/jmetzner/riak-java-client/commit/2910f6f39479866bb7d0e7065257f268a7af35dc Jan 2010/10/7

Re: Ping: Using Erlang funs for map reduce via the REST API and protocol buffers client

2010-10-07 Thread Mark Phillips
Hey Seth, We would love to have you send the patch along. When you have a moment head over to issues.basho.com and file a new bug with the patch attached. Thanks for putting it together. Mark ___ riak-users mailing list riak-users@lists.basho.com http

Re: Loading links after a map phase in a map reduce query

2010-10-07 Thread Mark Phillips
Hey Jan, I went ahead and filed a ticket to have this code pulled into our java client. Thanks for sending this over! You can track it here ---> https://issues.basho.com/show_bug.cgi?id=792 Feel free to make changes or add additional information I may have missed. Mark Community Manager Basho

cool riak schema for storing log-like data

2010-10-07 Thread Michal Zajda
Hi, I come up with this idea of riak schema and wanted to know if you see some bad sides of that. So, I have those devices, which generate logs (these are documents with stats). Each log is tagged with timestamp. If we store it like that, in a bucket some-device-name, retrieving data is pretty ha

Re: erlang:phash2(now())

2010-10-07 Thread David Smith
> make_ref is 6 times faster than erlang:phash2(make_ref()) which is 50% > faster than erlang:phash2(now()). > > Of course, in the grand scheme of things this might not be your biggest > bottleneck, but why hashing now() when there exsists an idiomatic make_ref() > solution? Am I missing something?

Re: erlang:phash2(now())

2010-10-07 Thread Lev Walkin
Do you have a robust policy of accepting outside patches? On Oct 7, 2010, at 6:47 PM, David Smith wrote: make_ref is 6 times faster than erlang:phash2(make_ref()) which is 50% faster than erlang:phash2(now()). Of course, in the grand scheme of things this might not be your biggest bottlene

Re: erlang:phash2(now())

2010-10-07 Thread David Smith
Please file an issue in bugzilla (http://issues.basho.com) with either a patch, or a reference to a git or mercurial repo. I can't guarantee that we'll accept every patch, but I do promise to give it a serious review. Thanks. :) D. On Fri, Oct 8, 2010 at 2:46 AM, Lev Walkin wrote: > Do you have