Hi Riak experts,

I am designing a simple message box feature for a web application using
riak where an user can send messages to other registered users. So each
user will have a Inbox and Outbox just like an email system.

Also users can search messages in their message box. Here I am providing
two different data model design. Could you please let me know if it makes
sense.

1)  Each user will have a separate bucket for their messages. So user u1
will have a bucket u1_messages and u2 will have u2_messages. All messages
for an user will be added to his/her bucket.  This will simplify search
operation as the search operation will only operate on user's bucket.

With this approach there will be lot many buckets in riak. So for 10000
registered users, there will be 10000 buckets.

So does this approach makes sense ? Is there any limitation or drawback
when there are too many buckets in riak ?

2) Common message bucket for all the users. The messages in the bucket will
be tagged with the user id. So one big bucket for all the messages. Search
operation will operate on that big bucket.

Please suggest which of the above approach makes sense.  I would really
appreciate any help on this.

Thanks for your help.

Cheers,
Satya
_______________________________________________
riak-users mailing list
[email protected]
http://lists.basho.com/mailman/listinfo/riak-users_lists.basho.com

Reply via email to