You *could* use Riak for all of that, but I personally find retrieving objects 
linked to other objects remarkably painful in Riak; even with secondary indexes 
Riak is still more suitable for fast growing data, and keeping the relational 
data in Postgres or MySQL.

Example of my setup:

MySQL is used for the majority of our user data (user object, user's billing 
profile object, and many many other objects that reference the user object) and 
Riak is used for only 3 pieces of *fast growing* data - a results bucket for 
one of the products we offer, a page cache bucket, and a stats bucket. The 
MySQL db is only, maybe, 300MB with all of the fast growing data moved into 
Riak. Riak, on our 5 node cluster is responsible for about 30GB of data, and 
it's growing pretty fast (for a really small startup).

On Sep 3, 2012, at 12:29 PM, Dan Milon wrote:

> Hello,
> 
> I am developing a web feed reader, with Riak as the database. While i have 
> read a few examples about designing schemas in Riak, i have come up with an 
> idea about this but i dont feel very confident.
> 
> Its quite simple, there are Users, Feeds, and Articles. User logs in, sees 
> feeds he is subscribed to, chooses one, and watches articles of that feed. 
> The further he scrolls down, more feeds are fetched.
> 
> The schema i came up with is the following
> 
> * User is a JSON object with his credentials, and a list of keys to feeds he 
> is subscribed to.
> 
> * Feeds are JSON objects with the basic information about the feed, 30 Links 
> to the most recent articles, and another Link to an object containing Links 
> to the next 30, and so on.
> 
> * Articles are JSON objects with meta info about the feed and a Link to a raw 
> object containing the actual content (ok, this might be embedded in the json 
> object)
> 
> Do you think this is the right way to go? Can you think of other designs with 
> pros/cons?
> 
> Thank you,
> danmilon.
> 
> _______________________________________________
> 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

Reply via email to