What is the most efficient way to store data

wilson Tuladhar mailwilson007 at gmail.com
Wed Feb 23 15:02:42 EST 2011


I am using Riak for the first time and I have been looking into it for
couple of days now.
I know that Riak is a key-value store and the data are kept in a bucket
specifying the key and its values.
Now what I would like to know is what is the most efficient way to store the
data so the data retrieval can be as fast as possible.
Say, i want to store the user information, so I made a bucket "Users" and
made the username its key as they are always unique.
Then, in the values section I kept the user information in a proplist i.e
[{password, User_pwd},{fname, F_name},...]
So, after that, I stored around 100000 users information in it and when i
search through the key its rather fast but when i try to search through the
I check all the keys for their values and match against them which is a very
slow process and i took me around 50 - 55 sec to get the result :-(

so, i was thinking if I have kept the data in a wrong way or if I have done
something wrong somewhere else.
I recently also looked into the indexing and searching feature provided by
riak, but before doing i want to verify that the way I am storing the data
is the correct way to do it in Riak.

So, could anyone tell me if i am right or wrong and if I am wrong what is
the correct way to put the data in the above scenario ??

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.basho.com/pipermail/riak-users_lists.basho.com/attachments/20110223/2fffcc71/attachment.html>

More information about the riak-users mailing list