1 / 67

Scaling

Scaling. ThisM. I’m not as cool as Zach. There’s no picture for this, it would change too much. The “Living and Evolving” AWS Cloud. Your Application. Tools to access services. Libraries and SDKs .NET/Java etc. Web Interface Management Console. Tools AWS Toolkit for Eclipse.

devona
Download Presentation

Scaling

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Scaling

  2. ThisM I’m not as cool as Zach

  3. There’s no picture for this, it would change too much

  4. The “Living and Evolving” AWS Cloud Your Application Tools to access services Libraries and SDKs .NET/Java etc. Web Interface Management Console Tools AWS Toolkit for Eclipse Command Line Interface Cross Service features Authentication and AuthorizationAWS IAM, MFA Monitoring Amazon CloudWatch Deployment and Automation AWS Elastic BeanstalkAWS CloudFormation Platform building blocks Parallel Processing Amazon Elastic MapReduce Payments Amazon DevPay Amazon FPS • Content Delivery Amazon CloudFront Workforce Amazon Mechanical Turk Messaging Amazon SNS Amazon SQS Email Amazon SES Infrastructure building blocks Compute Amazon EC2 Storage Amazon S3 Amazon EBS Network Amazon VPC Elastic LB Amazon Route 53 Database Amazon RDS Amazon SimpleDB Amazon Global Physical Infrastructure (Geographical Regions, Availability Zones, Edge Locations)

  5. Each day, AWS adds the equivalent server capacity to power Amazon when it was a global, $2.76B enterprise (circa 2000)

  6. The Cloud Scales: Amazon S3 Growth 566 Billion Peak Requests: 370,000+per second 262 Billion 102 Billion 40 Billion 14 Billion 2.9 Billion Total Number of Objects Stored in Amazon S3

  7. Global Infrastructure for Global Enterprises Asia Pacific Region (Tokyo) US West (Northern California) US East (Northern Virginia) Europe West (Dublin) Asia Pacific Region (Singapore) GovCloud (US ITAR Region) AWS Regions AWS Edge Locations

  8. Powerful Highly scalable, Highly available, Highly responsive Fault-tolerant, Cost-effective globally deployed Web application

  9. Seriouslyradwebsite.com Elastic IP Availability Zone #1 Amazon EC2 Instance Apache PHP Mod Buckets Amazon S3 MySQL Backups

  10. Pattern #1: Design for failure and nothing will fail

  11. Seriouslyradwebsite.com Elastic IP Availability Zone #1 Amazon EC2 Instance Apache PHP Mod Buckets Amazon S3 MySQL Backups

  12. Seriouslyradwebsite.com Elastic IP Availability Zone #1 Amazon EC2 Instance Apache PHP Mod Buckets LogsStatic Data Amazon S3 MySQL Backups Root Volume Data Volume Snapshots Amazon EBS

  13. Pattern #2: Edge cache static content

  14. Seriouslyradwebsite.com Elastic IP Availability Zone #1 Amazon EC2 Instance Apache PHP Mod Buckets LogsStatic Data Amazon S3 MySQL Backups Root Volume Data Volume Snapshots Amazon EBS

  15. Media.Seriouslyradwebsite.com (static data) Seriouslyradwebsite.com (dynamic data) Distribution Amazon CloudFront Elastic IP Availability Zone #1 Amazon EC2 Instance Apache PHP Mod Buckets LogsStatic Data Amazon S3 MySQL Backups Root Volume Data Volume Snapshots Amazon EBS

  16. Media.seriouslyradwebsite.com (static data) Seriouslyradwebsite.com (dynamic data) Distribution Amazon CloudFront Elastic IP Availability Zone #1 Amazon EC2 Instance Apache PHP Mod Buckets LogsStatic Data Amazon S3 MySQL Backups Root Volume Data Volume Snapshots Amazon EBS

  17. Seriouslyradwebsite.com (static data) Seriouslyradwebsite.com (dynamic data) Distribution Amazon CloudFront Elastic IP Availability Zone #1 Amazon EC2 Instance Apache Buckets Logs Static Data PHP Mod Amazon S3 MySQL Backups Amazon RDS

  18. Seriouslyradwebsite.com staging.Seriouslyradwebsite.com Dynamic IP 172.3.1.4 Elastic IP183.2.3.1 Availability Zone #1 Cloud Tip: Smart use of Elastic IPs (when upgrading new versions of your app) Staging EC2 Instance Production EC2 Instance App v1.2 App v1.1 Apache Apache PHP Mod PHP Mod Production EC2 Instance MySQL Amazon RDS

  19. Media.Seriouslyradwebsite.com (static data) Seriouslyradwebsite.com (dynamic data) Distribution Amazon CloudFront Elastic IP Availability Zone #1 Amazon EC2 Instance Apache Buckets Logs Static Data PHP Mod Amazon S3 MySQL Backups Amazon RDS

  20. Principles of elastic cloud architectures • Resilient to reboot and re-launch: • Design the system such that in the event of a failure, it is resilient enough to automatically re-launch and restart. Forcefully fail and test. • Stateless: • Extract stateful components out and make them stateless • Packable into an AMI: • Package and deploy your application into an AMI so it can run on an Amazon EC2 instance. Try to run multiple instances of the application on one EC2 instance, if needed. Run multiple instances on multiple Amazon EC2 instances. • Decouple: • Isolate the components using Amazon SQS. Decouple code with deployment and configuration.

  21. Pattern #3: Implement Elasticity

  22. media.myphpwebsite.com (static data) www.myphpwebsite.com (dynamic data) Distribution Amazon CloudFront Elastic IP Availability Zone #1 Amazon Machine Image Amazon EC2 Instance Apache Buckets Logs Static Data PHP Mod Amazon S3 MySQL Backups Amazon RDS

  23. www.myphpwebsite.com (dynamic data) media.myphpwebsite.com (static data) Amazon Route 53 (DNS) Elastic Load Balancer LB Distribution Amazon CloudFront Availability Zone #1 AutoScaling Group Amazon Machine Image Amazon EC2 Instance Apache Buckets Logs Static Data PHP Mod Amazon S3 MySQL Backups Amazon RDS

  24. www.myphpwebsite.com (dynamic data) media.myphpwebsite.com (static data) Amazon Route 53 (DNS) Elastic Load Balancer LB Distribution Amazon CloudFront Availability Zone #1 AutoScaling Group Amazon EC2 Instance Apache Buckets Amazon SNS (notifications) Logs Static Data PHP Mod Amazon S3 Amazon SimpleDB (Catalog and Config data) MySQL Amazon CloudWatch (Monitoring) Backups Amazon RDS

  25. www.myphpwebsite.com (dynamic data) Amazon Route 53 (DNS) Elastic Load Balancer LB media.myphpwebsite.com (static data) Availability Zone #1 AutoScaling group : Web App Tier Apache Apache Amazon SNS (notifications) Distribution Amazon CloudFront PHP Mod PHP Mod Amazon EC2 Amazon SimpleDB (Catalog and Config data) Buckets MySQL Amazon S3 Amazon RDS Amazon CloudWatch (Monitoring)

  26. Tight Coupling Controller A Controller B Controller C Q Q Q Loose Coupling using Queues Controller A Controller B Controller C Cloud Tip: Decouple components. The looser they're coupled, the bigger they scale

  27. www.myphpwebsite.com (dynamic data) Amazon Route 53 (DNS) Elastic Load Balancer LB media.myphpwebsite.com (static data) Availability Zone #1 AutoScaling group : Web App Tier Apache Apache Amazon SNS (notifications) Distribution Amazon CloudFront PHP Mod PHP Mod Amazon EC2 Amazon SimpleDB (Catalog and Config data) Buckets MySQL Amazon S3 Amazon RDS Amazon CloudWatch (Monitoring)

  28. Pattern #4: Leverage Multiple Availability Zones

  29. www.myphpwebsite.com (dynamic data) Amazon Route 53 (DNS) Elastic Load Balancer LB media.myphpwebsite.com (static data) Availability Zone #1 AutoScaling group : Web App Tier Apache Apache Availability Zone #2 Distribution Amazon CloudFront PHP Mod PHP Mod Amazon EC2 Buckets Failover Primary Multi-AZ Amazon S3 Amazon RDS Synchronous Replication Standby Slave Amazon RDS

  30. Pattern #5: Isolate read and write traffic; Isolate static and dynamic traffic

  31. www.myphpwebsite.com (dynamic data) Amazon Route 53 (DNS) media.myphpwebsite.com (static data) Elastic Load Balancer LB Distribution Amazon CloudFront Availability Zone #1 Amazon EC2 AutoScaling group : Web App Tier Apache Apache Availability Zone #2 PHP Mod PHP Mod Failover Read Replica Buckets Primary Master Async Replication Read Replica Amazon S3 Amazon RDS Synchronous Replication Standby Multi-AZ Amazon RDS

  32. Pattern #6: Automate your in-cloud Software Development and Deployment Lifecycle

  33. YAGNI(You ain’tgonna need it)

  34. YAGNI-UYRNI(You ain’tgonna need it, until you really need it)

  35. Hello, I am Mr. Automate Development And Testing Automate Using Cloud APIs Staging and Production Monitoring Build and Deployment

  36. Keep absolutely everything in version control Commit early and commit often Always check in to trunk and avoid branching Take responsibility if your check in breaks the build Automate the build, test, deploy process Be prepared to stop the mainline when/if build breaks Create a comprehensive automated test suite Only one way deploy and everybody uses that same way Be prepared to revert to the previous revision Continuously improve collaboration and increase speed of feedback

  37. Application Containers - JBoss, Tomcat, IIS, Mongrel. NOTE: there are so many app containers, I'm not going to try to list all of them.Build Tools - Ant, AntContrib, NAnt, MSBuild, Buildr, Gant, Gradle, make, Maven, RakeCode Review - CrucibleCode Insight - FisheyeContinuous Integration - Bamboo, Jenkins, AntHill Pro, Go, TeamCity, TFS 2010Database - Hibernate, MySQL, Liquibase, Oracle, PostgreSQL, SQL Server, SimpleDB, SQL Azure, Ant, MongoDBDatabase Change Management - dbdeploy, LiquibaseData Center Configuration Automation - Capistrano, Cobbler, BMC Bladelogic, CFEngine, IBM Tivoli Provisioning Manager, Puppet, Chef, Bcfg2, AWS Cloud Formation, Windows Azure AppFabricNOTE: There are many names and overlap for this tool "category". Dependency Management - Ivy, Archiva, Nexus, Artifactory, BundlerDeployment Automation - Java Secure Channel, ControlTier, Altiris, Capistrano, Fabric, FuncInformation Sharing - Confluence, Google AppsInstaller - InstallShield, IzPackIntegrated Development Environment (IDE) - Eclipse, IDEA, Visual StudioIssue Tracking - Greenhopper, JIRAMulti-Type - rPathPasswords - PassPack, PasswordSafeProtected Configuration - ESCAPE, ConfigGenProject Management - JIRA, Pivotal Tracker, SmartSheetProvisioning - JEOS, BoxGrinder, CLIP, Eucalyptus, AppLogicReporting/Documentation - Doxygen, Grand, GraphViz, JavaDoc, NDoc, SchemaSpy, UmlGraphStatic Analysis - CheckStyle, Clover, Cobertura, FindBugs, FxCop, JavaNCSS, JDepend, PMD, Sonar, SimianSystems Monitoring - CloudKick, Nagios, Zabbix, ZenossTestingAntUnit, Cucumber, DbUnit, webrat, easyb, Fitnesse, JMeter, JUnit, NBehave, SoapUI, Selenium, RSpec,SauceLabsVersion-Control System - SVN/Subversion, git, Perforce Paul Duvall’s Blog http://blog.stelligent.com/integrate-button/2011/03/list-of-software-tools-for-continuous-delivery-in-the-cloud.html

  38. Application Containers - JBoss, Tomcat, IIS, Mongrel. NOTE: there are so many app containers, I'm not going to try to list all of them.Build Tools - Ant, AntContrib, NAnt, MSBuild, Buildr, Gant, Gradle, make, Maven, RakeCode Review - CrucibleCode Insight - FisheyeContinuous Integration - Bamboo, Jenkins, AntHill Pro, Go, TeamCity, TFS 2010Database - Hibernate, MySQL, Liquibase, Oracle, PostgreSQL, SQL Server, SimpleDB, SQL Azure, Ant, MongoDBDatabase Change Management - dbdeploy, LiquibaseData Center Configuration Automation - Capistrano, Cobbler, BMC Bladelogic, CFEngine, IBM Tivoli Provisioning Manager, Puppet, Chef, Bcfg2, AWS Cloud Formation, Windows Azure AppFabricNOTE: There are many names and overlap for this tool "category". Dependency Management - Ivy, Archiva, Nexus, Artifactory, BundlerDeployment Automation - Java Secure Channel, ControlTier, Altiris, Capistrano, Fabric, FuncInformation Sharing - Confluence, Google AppsInstaller - InstallShield, IzPackIntegrated Development Environment (IDE) - Eclipse, IDEA, Visual StudioIssue Tracking - Greenhopper, JIRAMulti-Type - rPathPasswords - PassPack, PasswordSafeProtected Configuration - ESCAPE, ConfigGenProject Management - JIRA, Pivotal Tracker, SmartSheetProvisioning - JEOS, BoxGrinder, CLIP, Eucalyptus, AppLogicReporting/Documentation - Doxygen, Grand, GraphViz, JavaDoc, NDoc, SchemaSpy, UmlGraphStatic Analysis - CheckStyle, Clover, Cobertura, FindBugs, FxCop, JavaNCSS, JDepend, PMD, Sonar, SimianSystems Monitoring - CloudKick, Nagios, Zabbix, ZenossTestingAntUnit, Cucumber, DbUnit, webrat, easyb, Fitnesse, JMeter, JUnit, NBehave, SoapUI, Selenium, RSpec,SauceLabsVersion-Control System - SVN/Subversion, git, Perforce DO USE YES GOOD Paul Duvall’s Blog http://blog.stelligent.com/integrate-button/2011/03/list-of-software-tools-for-continuous-delivery-in-the-cloud.html

  39. CloudFormation Templates for Env Repo Generate Package Builder Config Install Create AMIs Push Code Config Tests Test Env Deploy Server Version Control CI Server Staging Env Pull Code Commit to Git/master Prod Env Dev Distributed Builds Run Tests in parallel Send Build Report to Dev Stop everything if build failed Cloud Continuous Integration

  40. www.myphpwebsite.com (dynamic data) Amazon Route 53 (DNS) media.myphpwebsite.com (static data) Elastic Load Balancer LB Distribution Amazon CloudFront Availability Zone #1 Amazon EC2 AutoScaling group : Web App Tier Apache Apache Availability Zone #2 PHP Mod PHP Mod Failover Read Replica Buckets Primary Master Async Replication Read Replica Amazon S3 Amazon RDS Synchronous Replication Standby Multi-AZ Amazon RDS

  41. Pattern #7: Cache as much as possible

  42. www.myphpwebsite.com (dynamic data) Amazon Route 53 (DNS) media.myphpwebsite.com (static data) Elastic Load Balancer LB Distribution Amazon CloudFront Availability Zone #1 Amazon EC2 AutoScaling group : Web App Tier Apache Apache Availability Zone #2 PHP Mod PHP Mod Failover Read Replica Buckets Primary Master Async Replication Read Replica Amazon S3 Amazon RDS Synchronous Replication Standby Multi-AZ Amazon RDS

  43. www.myphpwebsite.com (dynamic data) Amazon Route 53 (DNS) media.myphpwebsite.com (static data) LB Elastic Load Balancer Distribution Availability Zone #1 Amazon CloudFront AutoScaling group : Web Tier Availability Zone #2 Apache Apache Amazon EC2 PHP Mod PHP Mod cache Tier Memcache Memcache Tomcat Buckets RDS Master Amazon S3 RDS MultiAZ

  44. Pattern #8: Hardening security at every stage

  45. In the cloud, Security is a Shared Responsibility SAS 70 Type II Audit ISO 27001/2 Certification PCI DSS 2.0 Level 1-5 HIPAA/SOX Compliance FISMA A&A Low Encrypt data in transit Encrypt data at rest Protect your AWS Credentials Rotate your keys Secure your application, OS, Stack and AMIs How we secure our infrastructure How can you secure your application and what is your responsibility? Enforce IAM policies Use MFA, VPC, Leverage S3 bucket policies, EC2 Security groups, EFS in EC2 Etc.. What security options and features are available to you?

  46. www.myphpwebsite.com (dynamic data) Amazon Route 53 (DNS) media.myphpwebsite.com (static data) LB Elastic Load Balancer # Permit HTTP(S) access to Web Layer from the Entire Internetec2auth Web -p 80,443 -s 0.0.0.0/0 # Permit Web Layer access to App Layer ec2auth App -p 8000 -s 1.2.3.4/32 # Permit App Layer access to DB ec2auth App -p 3209 -s 1.2.3.4/32 # Permit administrative access SSH to all three layersec2auth Web -p 22 -o Appec2auth DB -p 22 -o App Distribution Availability Zone #1 Amazon CloudFront AutoScaling group : Web Tier Availability Zone #2 Apache Apache Amazon EC2 PHP Mod PHP Mod Cache Tier Memcache Memcache Tomcat Buckets RDS Master Amazon S3 RDS Slave

  47. www.myphpwebsite.com (dynamic data) Amazon Route 53 (DNS) media.myphpwebsite.com (static data) LB Elastic Load Balancer Distribution Availability Zone #1 Amazon CloudFront AutoScaling group : Web Tier Availability Zone #2 Apache Apache Amazon EC2 PHP Mod PHP Mod cache Tier Memcache Memcache Tomcat Buckets RDS Master Amazon S3 RDS MultiAZ

  48. www.myphpwebsite.com (dynamic data) Amazon Route 53 (DNS) media.myphpwebsite.com (static data) LB Elastic Load Balancer Availability Zone #1 Availability Zone #2 AutoScaling group : Web Tier AutoScaling group : Web Tier Availability Zone #n Distribution Apache Apache Apache Apache Amazon EC2 Amazon CloudFront PHP Mod PHP Mod PHP Mod PHP Mod Cache Tier Cache Tier Memcache Memcache Memcache Memcache Tomcat Tomcat Buckets Multi-AZ Slave DB Master Read Replica Amazon RDS Amazon S3

  49. Seriouslyradwebsite.com Elastic IP Availability Zone #1 Amazon EC2 Instance Apache PHP Mod Buckets Amazon S3 MySQL Backups

More Related