0

I've built EC2 hosting solutions before, but the application I'm building now is more advanced and I'd like some insight to see if I'm on the right track. The system is hosting a mobile application API where traffic will likely be coming in from around North America. We're still narrowing down the expected levels but are anticipating serious traffic. The primary operations are DB reads but include proportionally small writes as well.

Here is the layout I'm anticipating. Are there serious problems or otherwise what can I do to improve it?

  • large RDS instance storing everything (actual size dependant on researched traffic)
  • elastic load balancer directs traffic to
  • smaller instances in different zones and regions to geographically spread the load

Our API does not contain any static content like images, so every EC2 instance can point to the core RDS volume and the load balancer can cycle between. Is it smart to do something like this or do I need to get into database master/slave configurations? Even though the traffic is expected to be reasonably high, I don't think it will be that high.

  • I don't see any reason to use a geographically distributed service, given the information provided. – womble Sep 8 '15 at 19:20
3

Based on the information given, stick with a single region: either us-east-1 or us-west-2. Latency within North America to any of these regions should be reasonable.

  1. Use multiple EC2 instances spread across multiple availability zones.
  2. Use ELB to distribute traffic to your EC2 instances.
  3. Use an RDS instance for your database. Take advantage of Multi-AZ. It add high-availability to your data layer and it also helps at maintenance time when your RDS instance needs to be upgraded or otherwise made unavailable.

Later on, you could expand to another region:

  1. Use Route 53 latency-based routing so users go to the closest region
  2. Use an RDS read-replica in your second region so reads are faster.
  • Thank you for the info. That sounds like the best solution, and should offer enough room to expand as needed. – MechEngineer Sep 8 '15 at 19:58
  • As a side note, an ELB would not have worked as originally proposed -- ELB can only route traffic to instances within a single region. Latency-based routing would have been needed there, too. Your best interests might also be served (now) by integrating CloudFront, which will store cacheable responses geographically close to the requester and use more of the Amazon private IP network and less of the public Internet for transport of traffic to more distant visitors of the site. – Michael - sqlbot Sep 8 '15 at 22:06

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.