Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.

ARC302 AWS Cloud Design Patterns - AWS re: Invent 2012


Published on

AWS Cloud Design Patterns (a.k.a. CDP) are generally repeatable solutions to commonly occurring problems in cloud architecting. In this session, we introduce CDP and explain how you can apply CDPs in practical scenarios such as photo sharing, e-commerce, and web site campaigns.

ARC302 AWS Cloud Design Patterns - AWS re: Invent 2012

  1. 1. CDP
  2. 2. CDP
  3. 3. “This allows builders to create advanced models with simple parts”
  4. 4. Example of “Cloud Design Pattern” Amazon Route 53 “Floating IP Pattern” Elastic IP EC2 EC2
  5. 5. Floating AC Adaptor
  6. 6. “Weighted Transition” Pattern Route 53 α% 100-α% Elastic Load ELB Balancing (ELB) Web/AP Web/AP Web/AP Web/AP Web/AP Web/AP EC2 EC2 DB DB EC2 EC2
  7. 7. “Job Observer” Pattern CloudWatch Auto Scaling Put EC2 New SQS EC2 Get EC2
  8. 8. • Wanted to exchange servers with a shorter amount of down time• Solution (no AWS terminology) • Using IP address to exchange an existing server to a newly launched server Route 53• Implementation (AWS terminology) • Using EIP to exchange an existing EC2 instance to a Elastic IP newly launched one• Diagram• Pros • Can exchange servers regardless of DNS TTL EC2 EC2• Notes• Others
  9. 9. Other Examples Cache Distribution Direct Hosting Cache Proxy Deep Health Check Multi Data Center Stamp
  10. 10. Basic Static Contents Batch Processing Snapshot Web Storage Queuing Chain Stamp Direct Hosting Priority Queue Scale Up Private Distribution Job Observer On-Demand Disk Cache Distribution Scheduled Auto Scaling Rename DistributionAvailability Maintenance Multi-Server Data Uploading Bootstrap Multi Data Center Write Proxy Cloud DI Floating IP Storage Index Stack Deployment Deep Health Check Direct Object Upload Server Swapping Monitoring IntegrationScaling Relational Database Web Storage Archive Scale Out DB Replication Clone Server Read Replica Networking NFS Sharding In-Memory DB Cache On-Demand NAT NFS Replica Sharding Write Backnet State Sharing Functional Firewall URL Rewriting Operational Firewall Rewrite Proxy Multi Load Balancer Cache Proxy WAF Proxy Scheduled Scale Out CloudHub
  11. 11. “Amazon Web Services CDP – Design Guidebook”“This was a test marketing in Japan, and it worked very well! Now we started translating this into English!”
  12. 12. - “sorry, Japanese only!”
  13. 13. • Example of Implementation Scenario • Content Distribution • Distribute static content to large number of users • E-Commerce • Implement fault-tolerance application • Campaign Site • Deal with unpredictable massive traffic • and others… • Streaming, batch processing, monitoring, VPC migration, etc.
  14. 14. Content Distribution Scenario
  15. 15. Environments Amazon Linux (64bit) Movable Type 5.12 (MTOS) Apache HTTP Server 2.2.21 MySQL 5.1.52 Perl 5.10.1 S3FS 1.61 21
  16. 16. Initial Design Amazon Route 53 EIP Blog System EC2 Instance (t1.micro) 22
  17. 17.
  18. 18. ProblemNeed to distribute photos andvideos in a cost-effective way offloadImplementationHost heavy files by Amazon S3 Web(web hosting feature) and users S3 EC2will download them from S3directly
  19. 19. Apply “Web Storage” Pattern EIP Download Link Blog Videos System S3 EC2 Instance (t1.micro) 25
  20. 20.
  21. 21. ProblemNeed to host website in acost-effective wayImplementation upload WebUse Amazon S3 website hostingfeature. Dynamically upload EC2updated contents from Amazon S3EC2
  22. 22. Apply “Direct Hosting” Pattern EIP Blog System 28
  23. 23. Editor’s choice : No1 “Clouds” blog
  24. 24. Apply “Cache Distribution” Pattern Blog contents Videos/Images Blog post Blog posting/ Search Management EIP 30
  25. 25. Web Storage Direct Hosting Cache Distribution
  26. 26. E-Commerce Site Scenario
  27. 27. Environments Amazon Linux (64bit) Apache HTTP Server 2.2.21 EC-Cube 2.11.3 PHP 5.3.8 MySQL 5.1.52 34
  28. 28. Initial Design Amazon Route 53 EIP EC System EC2 Instance (t1.micro) 35
  29. 29. Apply “Floating IP” Amazon Route 53 EIP ④change EIPEIP「」 Prod Test ③Updating and testing EC2 EC2 ①Create AMI ②Launch Test environment EC2 AMI 37
  30. 30. @Studio 4Directions
  31. 31. Apply “Server Swapping” EC2 EC2 Data Data AMI EBS EBS 39
  32. 32. Apply “Multi-Server” ELB Original Duplicate EC2 EC2 DB Instance 41
  33. 33. 42
  34. 34. Apply “Multi-Server” ELB Original Duplicate EC2 EC2 DB Instance 43
  35. 35. Adding EC2 instances
  36. 36. Apply “DB Replication” ELB Original Duplicate EC2 EC2 Sync AZ - 1a AZ – 1b 49
  37. 37. @gigazine
  38. 38. Apply “Multi Data Center” ELB Original Duplicate EC2 EC2 Sync AZ - 1a AZ – 1b 51
  39. 39. Server Swapping Multi Server DB replication Multi Data Center
  40. 40. Campaign Site Scenario
  41. 41. Environments Amazon Linux (32bit) Apache HTTP Server 2.2.21 MySQL 5.1.52 PHP 5.3.8 WordPress 3.3.1 55
  42. 42. Initial Design• Small start• Stand-alone server configuration 56
  43. 43. Apply “Clone Server” Pattern 58
  44. 44. Apply “Scale Out” Pattern 59
  45. 45. Apply “NFS Sharing” Pattern NFS 61
  46. 46. Apply “NFS Replica” Pattern 63
  47. 47. Apply “URL Rewriting” Pattern• Off-load static contents to S3• Rewrite the URLs by using mod_ext_filter 65
  48. 48.•• Created by ARCHITYP•
  49. 49. We are sincerely eager to hear your feedback on thispresentation and on re:Invent. Please fill out an evaluation form when you have a chance.