Note that there are some explanatory texts on larger screens.

plurals
  1. POHow should I architect Amazon Web Services for my app?
    text
    copied!<p>I am planning a social-networking app I am about to develop. I already have experience in using many AWS services, which are: SES, SimpleDB, DynamoDB, CloudFront and S3. I am open to learning more any time.</p> <p>Basically in the app, you have status updates. Each user has an account, can upload their own status updates, like, comment on a status update etc. The user can check out the most liked status update in the last 'x' hours, and can also search the whole database for status updates by searching for a username or searching for status update keywords -- like YouTube tags that users specify upon creation.</p> <p>Here is my current schema:</p> <ul> <li>Use DynamoDB to host every single status update <strong>key</strong> on S3 with attributes and use range queries to compare for likes, timestamp,</li> <li>Use SimpleDB to host all the account keys and other keys for S3 with attributes to query</li> <li>Use Amazon S3 to host all the account data and status update data</li> <li>Use CloudFront to distribute S3 bucket contents worldwide</li> </ul> <p>So, when the user wants to see the most liked status updates for the last day, it range queries DynamoDB to find the most liked status update within a timestamp of 24 hours. If the user wants to <strong>search</strong> for tags of a status update, DynamoDB would have the tags attribute and query for it. But can DynamoDB query for strings? See if strings are matching? I do not think so... I would not like to scan DynamoDB and individually match keys based on their format. Naming convention could include attributes inside, for example a key name for a status update could be:</p> <blockquote> <p>max:UploadedQuote:ijfi93nSNDiI:numberOfLikes="3499" </p> </blockquote> <p>or something like that</p> <p>This is because the scan limit is 10 MB, which I think with an average and active user base might not work out, I do not want to send multiple requests and bloat the app. If the user wants to view somebody's account, it finds the key on SimpleDB and loads it on S3.</p> <p>Obviously status update's by a particular user would have to be organized into their account object, but I need a separate object to hold all the status updates (DynamoDB) -- otherwise how can I let the user search status updates throughout the whole database?</p> <p>I think the hardest part is the sorting by likes and tags, I need to somehow have a database like DynamoDB, fast and scalable but be able to query like SimpleDB. I would like to <strong>only</strong> use AWS though. I know this is possible as I know an app called PanoPerfect that uses AWS, they have fairy similar functionalities to what I plan. I wonder how their architecture runs. Instagram does too!</p> <p>Obviously hosting all the status updates on SimpleDB makes more sense because you can query them properly, Im not even sure the querying on DynamoDB works as I plan, but if I host every single status update it will overflow SimpleDB and bloat it. DynamoDB can be expensive though.</p> <p>Is there a better schema to this? Should I use CloudSearch for searching instead of this DynamoDB process? Is CloudSearch available on iOS? What about EC2? How does that work? I'm quite unsure how I can architect my app with AWS at this stage of planning.</p> <p>Thanks for the help!</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload