SlideShare une entreprise Scribd logo
1  sur  188
Télécharger pour lire hors ligne
Patterns for Cloud Computing

Simon Guest
Senior Director, Technical Strategy
Microsoft Corporation
Patterns for Cloud Computing
Patterns for Cloud Computing




                   This is Jim
Patterns for Cloud Computing




 Jim has many questions about cloud computing
Patterns for Cloud Computing




 The more he reads, the more confused he gets
Patterns for Cloud Computing




           “What is cloud computing?”
Patterns for Cloud Computing




     “What are vendors doing in this space?”
Patterns for Cloud Computing




 “What applications make sense in the cloud?”
Session Objectives
Session Objectives

               Build on Stefan’s introduction of
                      of cloud computing


                Provide you with 5 patterns for
                   cloud-based applications


                     Show implementations of
                         these patterns
Defining Cloud Computing
Defining Cloud Computing

       Application runs
       on-premises




    • Bring my own
      machines,
        Buy my own
      connectivity,
      software, etc.and
       hardware,
    • manage my own
      Complete control
         data center
      and responsibility
    • Upfront capital
      costs for the
      infrastructure
Defining Cloud Computing

       Application runs     Application runs at a
       on-premises                 hoster




    • Bring my own         • Rent machines,
      machines,              connectivity,
        Buy my own           Pay someone to
                             software
      connectivity,
      software, etc.and
       hardware,            host my application
                           • Less control, but
    • manage my own
      Complete control     using hardware that
                             fewer
         data center
      and responsibility         I specify
                             responsibilities
    • Upfront capital      • Lower capital costs,
      costs for the          but pay for fixed
      infrastructure         capacity, even if idle
Defining Cloud Computing

       Application runs     Application runs at a     Application runs using
       on-premises                 hoster               cloud platform




    • Bring my own         • Rent machines,           • Shared,
      machines,              connectivity,              multi-tenant
                                                       Pay someone for a
        Buy my own           Pay someone to
                             software                   environment
      connectivity,                                    pool of computing
      software, etc.and
       hardware,            host my application
                           • Less control, but        • Offers pool of
                                                       resources that can
    • manage my own
      Complete control     using hardware that
                             fewer                      computing
                                                       be applied to a set
         data center
      and responsibility         I specify
                             responsibilities           resources,
                                                         of applications
                                                        abstracted from
    • Upfront capital      • Lower capital costs,
      costs for the          but pay for fixed          infrastructure
      infrastructure         capacity, even if idle   • Pay as you go
Defining Cloud Computing




            Cloud “Variants”
Defining Cloud Computing




              Public Cloud
Defining Cloud Computing




Pool of computing resources offered by
       a vendor, typically using a
         “pay as you go” model
Defining Cloud Computing




              Private Cloud
Defining Cloud Computing




 Pool of computing resources that lives
  within a self managed datacenter
Defining Cloud Computing




 Pool of computing resources that lives
 within a datacenter with no sharing
Defining Cloud Computing

            Compute: Virtualized compute based on Windows Server
            Storage: Durable, scalable, & available storage
            Management: Automated, management of the service



             Database: Relational processing for structured/
             unstructured data




             Service Bus: General purpose application bus
             Access Control: Rules-driven, claims-based access control
Defining Cloud Computing



             Different Models

        Infrastructure as a Service (IaaS)
                        vs.
          Platform as a Service (PaaS)
Defining Cloud Computing


                      Your Application      Deployment

                        Frameworks

        Deployment       Web Server

                         OS Services         Provided by
                                            Windows Azure
                     Operating System

         Provided    Virtualized Instance
            By
         Amazon
                         Hardware
           EC2
Defining Cloud Computing

        Deployment     Your Application      Deployment

                         Frameworks

                          Web Server

        Provided by       OS Services         Provided by
          Google
                                             Windows Azure
        AppEngine
                      Operating System

                      Virtualized Instance

                          Hardware
Patterns for Cloud Computing




    #1 - Using the Cloud for Scale
Patterns for Cloud Computing




“Isn’t the cloud good for applications that need to
                 scale dynamically?”
Patterns for Cloud Computing




  “For example, applications that have spikes or
                  peak loads”
Patterns for Cloud Computing




             “How does this work?”
Patterns for Cloud Computing




     Let’s do some white boarding for Jim…
…and when I say white boarding, I really mean it
#1 - Using the Cloud for Scale


“Wow! What a great site!”


                  Request
     Browser                 Web Tier   B/L Tier   Database
                  Response
#1 - Using the Cloud for Scale


Browser

Browser

Browser          Web Tier      B/L Tier    Database
               “Server Busy”
Browser

Browser
#1 - Using the Cloud for Scale


Browser

Browser

Browser         Web Tier      B/L Tier     Database

Browser                       “Timeout”


Browser
How would Jim do this today on premises?
#1 - Using the Cloud for Scale
           How would Jim do this today on premises?


Browser

Browser             Web Tier
                N
Browser         L   Web Tier           B/L Tier       Database
                B
Browser             Web Tier

Browser
#1 - Using the Cloud for Scale
           How would Jim do this today on premises?


Browser

Browser                                  B/L Tier
                                    N
Browser           Web Tier          L    B/L Tier     Database
                                    B
Browser                                  B/L Tier

Browser
#1 - Using the Cloud for Scale
           How would Jim do this today on premises?


Browser

Browser             Web Tier             B/L Tier
                N                   N
Browser         L   Web Tier        L    B/L Tier     Database
                B                   B
Browser             Web Tier             B/L Tier

Browser
#1 - Using the Cloud for Scale
           How would Jim do this today on premises?


Browser                                               p1 p2 p3

Browser             Web Tier             B/L Tier
                N                   N
Browser         L   Web Tier        L    B/L Tier     Database
                B                   B
Browser             Web Tier             B/L Tier

Browser
Not without consequences...
#1 - Using the Cloud for Scale
           How would Jim do this today on premises?


Browser                                                  p1 p2 p3

Browser              Web Tier               B/L Tier
                N                      N
Browser         L    Web Tier          L    B/L Tier     Database
                B                      B
Browser              Web Tier               B/L Tier

Browser         “That took a lot of work - and money!”
#1 - Using the Cloud for Scale
                  How would Jim do this today on premises?


                                                                        p1 p2 p3
“Not so great now…”
                             Web Tier                  B/L Tier
                        N                        N
    Browser             L    Web Tier            L     B/L Tier         Database
                        B                        B
                             Web Tier                  B/L Tier

                        “That took a lot of work - and money!”
                      “Hmmm... Most of this stuff is sitting idle...”
#1 - Using the Cloud for Scale


                                         Datacenter peak load




Usage                                    Idle time




        Jan       Apr     Jul     Oct
How can cloud computing help?
#1 - Using the Cloud for Scale


“Wow! What a great site!”


                  Request
     Browser                 Web Role   Worker Role    Azure
                                                      Storage
                  Response
#1 - Using the Cloud for Scale


Browser

Browser

Browser          Web Role      Worker Role    Azure
                                             Storage
               “Server Busy”
Browser

Browser
#1 - Using the Cloud for Scale


Browser

Browser               Web Role
                 N
Browser          L    Web Role   Worker Role    Azure
                 B                             Storage
Browser               Web Role

Browser

            You don’t see
               this bit
#1 - Using the Cloud for Scale


Browser

Browser            Web Role       Worker Role
               N              N
Browser        L   Web Role   L   Worker Role    Azure
               B              B                 Storage
Browser            Web Role       Worker Role

Browser
OK, so changing config is easy...

…but what else do I need to know?
#1 - Using the Cloud for Scale


Browser

Browser            Web Role       Worker Role
               N              N
Browser        L   Web Role   L   Worker Role    Azure
               B              B                 Storage
Browser            Web Role       Worker Role

Browser
#1 - Using the Cloud for Scale


Browser

Browser            Web Role              Worker Role
               N                     N
Browser        L   Web Role          L   Worker Role     Azure
               B                     B                  Storage
Browser            Web Role               Worker Role

Browser             Tight coupling between web and
                    worker role is an anti-pattern
#1 - Using the Cloud for Scale


                                                 4. Process

      Web Role                     Worker Role

              2. Respond to UI

                     Req
1 Place on queue
 .                                        3. Pickup from queue
                           Queue
#1 - Using the Cloud for Scale


                                                   4. Process

       Web Role                      Worker Role




                      Req                          5. Add result to table

                            Queue


6. Query table on refresh
                             Table
Demo: Prime Solver
How many web and worker roles do you need?
How many web and worker roles do you need?
#1 - Using the Cloud for Scale

             WMI_Win32_PerfFormattedData_ASPNET_ASPNETApplications
             /RequestsPerSecond
Browser

Browser            Web Role
               N
Browser        L   Web Role        Worker Role         Azure
               B                                      Storage
Browser            Web Role

Browser

                                                    Management API
                     Log           Worker Role
                                                       or Email
How many web and worker roles do you need?
#1 - Using the Cloud for Scale

Web Role

  Web Role

     Web Role                            Worker Role




                  Req   Req   Req



                        Queue

      Web Role

  Web Role         Monitor queue
                 length against user’s
Web Role            expectations
#1 - Using the Cloud for Scale

Web Role                                      Worker Role

  Web Role                                  Worker Role

     Web Role                            Worker Role




                  Req   Req   Req



                        Queue

      Web Role                           Worker Role

  Web Role         Monitor queue            Worker Role
                 length against user’s
Web Role            expectations              Worker Role
Patterns for Cloud Computing
                   Takeaways

          A core tenet of cloud computing is
          the ability to scale up/down

          Understand how to communicate
          between roles and nodes

          Strategy on when to scale up/down
          roles in production
Patterns for Moving to the Cloud




#2 - Using the Cloud for Multi Tenancy
Patterns for Cloud Computing




      “I like the idea of scaling Web roles…”
Patterns for Cloud Computing




    “…but need to serve multiple customers”
Patterns for Cloud Computing




     “Without creating separate codebases!”
How would Jim do this today on premises?
#2 - Using the Cloud for Multi Tenancy
              How would Jim do this today on premises?


  Browser            Web Tier            B/L Tier        Database
Customer #1


  Browser            Web Tier             B/L Tier       Database
Customer #2


  Browser            Web Tier             B/L Tier       Database
Customer #3
Gets expensive pretty quickly
#2 - Using the Cloud for Multi Tenancy


  Browser
Customer #1

  Browser        Web Tier     B/L Tier    Database
Customer #2

  Browser
Customer #3
Schema Customizations

  UI Customizations
Schema Customizations

  UI Customizations
3 options for data in multi tenant environment
#2 - Using the Cloud for Multi Tenancy


  Browser
                                                     Fixed Schema
Customer #1

  Browser        Web Tier            B/L Tier          Database
Customer #2

  Browser
               Option 1: Everyone Uses the Same Database/Schema
Customer #3
               Pros: Simplest approach, easy to maintain/upgrade.
               Cons: No customizations. Restoring of tenant data.
#2 - Using the Cloud for Multi Tenancy


  Browser                                                       Database
Customer #1                                                  Customer #1

  Browser            Web Tier              B/L Tier             Database
Customer #2                                                  Customer #2

  Browser                                                       Database
Customer #3                                                  Customer #3

              Option 2: Give Each Customer Their Own Database/Schema
              Pros: Flexible. Tenant restore is easier. High Isolation.
              Cons: Can be costly. Difficult to upgrade db schemas.
#2 - Using the Cloud for Multi Tenancy


  Browser                                              Fixed Schema
                                                    with Customizations
Customer #1

  Browser         Web Tier            B/L Tier           Database
Customer #2

  Browser
              Option 3: Fixed Database/Schema, with customizations
Customer #3
              Pros: Customers can add their own custom fields
              Cons: Non standard way of customizing the schema.
              Tenant restore is difficult.
#2 - Using the Cloud for Multi Tenancy
                                         Tenant


                                                            *
                           1
                                TenantID           int

                               TenantName        nvarchar



        *
      Employee
EmployeeId        int                                           TypeID
                                                                            *
                                                                         Type
                                                                                    int

FirstName       nvarchar                                         Name       nvarchar

 LastName       nvarchar                                        CLRType     nvarchar

            1                                                                   1
                                    Customization




                                                            *
                                                    int


                           *
                               CustomizationID


                                   Value         nvarchar
#2 - Using the Cloud for Multi Tenancy
                                       Tenant


                                                         *
                         1
                              TenantID           1

                             TenantName UK Branch


        *
      Employee
EmployeeId        1                                          TypeID
                                                                         *
                                                                      Type
                                                                                 1

FirstName       Gordon                                        Name       PostalCode

 LastName       Brown                                        CLRType         string

            1                                                                1
                                  Customization




                                                         *
                                                  1


                         *
                             CustomizationID


                                 Value         SW1 2AA
                                                  A
#2 - Using the Cloud for Multi Tenancy
                                       Tenant


                                                        *
                         1
                              TenantID           2

                             TenantName US Branch


        *
      Employee
EmployeeId        2                                         TypeID
                                                                        *
                                                                     Type
                                                                                2

FirstName       Barack                                       Name           ZipCode

 LastName       Obama                                       CLRType          string

            1                                                               1
                                  Customization




                                                        *
                                                  2


                         *
                             CustomizationID


                                 Value          20500
#2 - Using the Cloud for Multi Tenancy
                                            Tenant


                                                             *
                              1
Fixed Schema                       TenantID           2
Applies to All                                                                   Could be both
                                  TenantName US Branch


                 *                                                           *
   Tenants

            Employee                                                      Type
     EmployeeId        2                                         TypeID              2
                                       Customizable
      FirstName      Barack          Tenant by Tenant             Name           ZipCode

      LastName       Obama                 Basis                 CLRType          string

                 1                                                               1
                                       Customization




                                                             *
                                                       2


                              *
                                  CustomizationID


                                      Value          20500
Schema Customizations

  UI Customizations
#2 - Using the Cloud for Multi Tenancy


  Browser
Customer #1

  Browser        Web Tier     B/L Tier    Database
Customer #2

  Browser
Customer #3
URL Handing
Routing using MVC approach
#2 - Using the Cloud for Multi Tenancy

              http://hr.contoso.co.uk
  Browser
Customer #1           http://employeedata.cloudapp.net
  Browser                Web Tier              B/L Tier   Database
Customer #2

  Browser
Customer #3
              http://hr.fabrikam.com
#2 - Using the Cloud for Multi Tenancy

              http://hr.contoso.co.uk -> CNAME (employeedata.cloudapp.net)
  Browser
Customer #1          http://employeedata.cloudapp.net
  Browser               Web Tier               B/L Tier            Database
Customer #2

  Browser
Customer #3
              http://hr.fabrikam.com -> CNAME (employeedata.cloudapp.net)
#2 - Using the Cloud for Multi Tenancy

              http://hr.contoso.co.uk -> CNAME (employeedata.cloudapp.net)
  Browser
Customer #1          http://employeedata.cloudapp.net
  Browser               Web Tier               B/L Tier            Database
Customer #2          Use custom route to controller mapping

  Browser
Customer #3
              http://hr.fabrikam.com -> CNAME (employeedata.cloudapp.net)
Demo: Multi Tenant Schema and UI
Patterns for Cloud Computing
                   Takeaways

          Always consider Multi Tenancy first,
          even if only one customer

          Design considerations must include
          both data and UI

          Many other considerations, such as
          identity – p&p guidance
Patterns for Moving to the Cloud




 #3 - Using the Cloud for Compute
Patterns for Cloud Computing




    Jim sees how cloud computing supports
            scaling up/down nodes
Patterns for Cloud Computing




    “Can I use all of these nodes in parallel?”
Patterns for Cloud Computing




 “I’ve got this complex calculation I would like to
        share across these multiple nodes…”
#3 - Using the Cloud for Compute



                                       Data
         Data                Worker
                                       Data
Client          Master       Worker

                                       Data
                             Worker
#3 - Using the Cloud for Compute



                           Result
                                    Worker

                           Result
Client            Master            Worker

         Result
                                    Worker
                           Result
Popularized by the term “MapReduce”*




     * 2004 OSDI paper by Jeff Dean and Sanjay Ghemawat (Google)
#3 - Using the Cloud for Compute

               How many ”e”’s in
“The quick brown fox jumps over the lazy dog”?
                                                                     M<k,v>
                    Data                                 Worker
                                                                     M<k,v>
         Client             Master                       Worker

                                                                     M<k.v>
                                                         Worker


                                                            “Map”


                                                 M<“the quick brown”.”e”>
                                                 M<“fox jumps over”.”e”>
                                                 M<“the lazy dog”.”e”>
#3 - Using the Cloud for Compute



                                      L<k,v>
                                                  Worker

                                     L<k,v>
    Client                 Master                 Worker

                 Result
                                                  Worker
                                     L<k,v>
3 x ”e”s found
                          “Reduce”
                                     L<”e”,”1”>
                                     L<”e”,”1”>
                                     L<”e”,”1”>
And it’s definitely popular...
#3 - Using the Cloud for Compute

                    Google
20pb of data analyzed every day using MapReduce

                    Yahoo!
    10k+ cores, 4pb of data using MapReduce

                  Facebook
   2500+ cores, 1pb of data using MapReduce
Frameworks
#3 - Using the Cloud for Compute

            Apache Hadoop
Open Source Java “Inspired by MapReduce”
       (Core, HDFS, many more)

                   Cloudera
 Consulting, training, distribution of Hadoop

        Amazon Elastic MapReduce
      Hadoop implementation on EC2
How would Jim do this today on premises?
#3 - Using the Cloud for Compute
                     How would Jim do this today on premises?




                                                                      Data
                     Data                               Worker
                                                                      Data
      Client                     Master                 Worker

Client Application          Job/Task Scheduler          Worker
                                                                      Data



                                                     Remote Service
How about implementing this on Windows Azure?
#3 - Using the Cloud for Compute


                                                                             Data
                                                               Worker
                     Data

                                                                             Data
                                                               Worker
      Client                    Web Role
                                                                             Data
Client Application          Job/Task Scheduler                 Worker
                                                            Remote Service

                                             Req



                                                   Queue




                                                    Table
Demo: Windows Azure Demo
 “Inspired by MapReduce”
Patterns for Cloud Computing
                   Takeaways

          MapReduce very visible, although
          can be difficult to initially grasp

          Learn about existing frameworks,
          especially Apache Hadoop

          Read up on Dryad (DryadLINQ) for
          future direction
Patterns for Moving to the Cloud




  #4 - Using the Cloud for Storage
Patterns for Cloud Computing




  “The cloud lets me store infinite data, right?”
Patterns for Cloud Computing




Lots of headaches with data management today
Patterns for Cloud Computing




        “It sounds too good to be true…”
How does Jim do this today on premises?
#4 - Using the Cloud for Storage
         How would Jim do this today on premises?




           File
                     RPC/NFS
Client                                        File Server   Store
#4 - Using the Cloud for Storage
         How would Jim do this today on premises?




           Data   TDS (Tabular Data Stream)
Client                                        DB Server   RDBMS
#4 - Using the Cloud for Storage
          How would Jim do this today on premises?




            Data
                       HTTP POST
Browser                                        Web Server   Database
#4 - Using the Cloud for Storage


   I love                         I love
    you!                         you too!



            Server        Data



Affinity between your data and physical
         hardware that serves it
#4 - Using the Cloud for Storage


        I love                             I love
         you!                             you too!



                  Server           Data



                   Symptoms:
           Which RAID number was that again?
      Tedious to backup exponentially growing data
Crap! I’m at 95% capacity - got to move to a bigger disk
How does the cloud help?
Breaks the affinity between your data and hardware
Blobs, Tables, Relational
Blobs, Tables, Relational
#4 - Using the Cloud for Storage


PutBlob                                                            Blob Container
PUT http://account.blob.core.windows./net/containername/blobname

                                                    REST API
    Client                                                               Azure
                                                                     Blob Storage




                        http://account.blob.core.windows.net/containername/blobname


                        PutBlob = 64Mb MAX
                        MetaData = 8Kb per Blob
#4 - Using the Cloud for Storage


                                                                   Blob Container


                                                   REST API
    Client                                                               Azure
                                                                     Blob Storage
GetBlob
GET http://account.blob.core.windows./net/containername/blobname


                        http://account.blob.core.windows.net/containername/blobname
#4 - Using the Cloud for Storage


                                                                   Blob Container


                                                   REST API
    Client                                                               Azure
                                                                     Blob Storage
GetBlob
GET http://account.blob.core.windows./net/containername/blobname
Range: bytes=329300 - 730000
                        http://account.blob.core.windows.net/containername/blobname
#4 - Using the Cloud for Storage


PutBlock(blobname, blockid, data)                            Blob Container
PutBlockList(blobname, blockid1 …, blockidN)
                               ,
                                               REST API
    Client                                                         Azure
                                                               Blob Storage




                       http://account.blob.core.windows.net/containername/blobname


                       PutBlock = 4Mb MAX to a maximum of 50Gb
                       BlockId = 64 bytes
Blobs, Tables, Relational
#4 - Using the Cloud for Storage
REST:
GET http://account.table.core.windows.net/Customer?$filter=%20PartitionKey%20eq%20value
LINQ:
var customers = from o in context.CreateQuery<customer>(“Customer”) where o.PartitionKey
== value select o;



                     Worker Role                       Azure
                                                   Table Storage




                                           http://account.table.core.windows.net
                   Each Table:

                   PartitionKey (e.g. DocumentName) to ensure
                   scalability
                   RowKey (e.g. version number)
                   [fields] for data
Blobs, Tables, Relational
Codename Sitka (early 2008)
SQL Server Data Services (MIX08)
#4 - Using the Cloud for Storage

         This is what I’m doing on premises...



            Data
                            TDS
Client                                           DB Server   RDBMS
#4 - Using the Cloud for Storage

         So, this is what I would like to do in the cloud...



            Data
                              TDS
Client                                                     DB Server   RDBMS
SQL Data Services (MIX09)
SQL Azure (July 2009)
#4 - Using the Cloud for Storage

         So, this is what I would like to do...



            Data
                              TDS
Client                                            SQL Azure   RDBMS
#4 - Using the Cloud for Storage




          HTTP               TDS
Browser           Web Role         SQL Azure   RDBMS
#4 - Using the Cloud for Storage




          HTTP              Queue                 TDS
Browser          Web Role           Worker Role         SQL Azure   RDBMS
Migration!
#4 - Using the Cloud for Storage


                             “The Data Center”


          HTTP                           TDS
Browser          Web Tier   Bus. Logic         SQL Server   RDBMS
#4 - Using the Cloud for Storage


                                        “The Cloud”


          HTTP              Queue                 TDS
Browser          Web Role           Worker Role         SQL Azure   RDBMS
Demo: SQL Azure CTP
Patterns for Cloud Computing
                   Takeaways

          Storage in the cloud may look the
          same, but breaks the affinity issue

          Understand the pricing model for
          storage on-premises vs. cloud

          SQL Azure as a factor for
          migration/move from on premises
Patterns for Moving to the Cloud




#5 - Using the Cloud for Communications
Patterns for Cloud Computing




 Jim’s organization needs to communicate with
               other organizations
Patterns for Cloud Computing




“This has always been a very tricky and expensive
             process to get working”
Patterns for Cloud Computing




    “Does the cloud offer anything to help?”
How would Jim have done this before?
#5 - Using the Cloud for Communications




                     Telco provided WAN
Company 1                                          Company 2


  Client                                            Server

             FTP                           FTP
            Client                        Server
#5 - Using the Cloud for Communications



                           Internet
                     Telco provided WAN
Company 1                                          Company 2


  Client                                            Server

             FTP                           FTP
            Client                        Server
#5 - Using the Cloud for Communications



                           Internet
                     Telco provided WAN
Company 1                                        Company 2
                                           DMZ

  Client                                             Server

                                          Extranet
           Browser
                                            Site
What does the cloud provide?
#5 - Using the Cloud for Communications


                     http://app.queue.core.windows.net/


                            REST
 Client                                  Azure Queue
#5 - Using the Cloud for Communications
Company 1

                     http://app.queue.core.windows.net/
  Client

                             REST
                                         Azure Queue

Company 2


  Client
#5 - Using the Cloud for Communications
Company 1

                     http://app.queue.core.windows.net/
  Client

                             REST
                                         Azure Queue

Company 2


  Client
#5 - Using the Cloud for Communications
   Company 1

                        http://app.queue.core.windows.net/
     Client

Primary Access Key
                                REST
                                            Azure Queue

   Company 2


      Client

Primary Access Key
#5 - Using the Cloud for Communications
Company 1

                     http://app.queue.core.windows.net/
  Client

                             REST
                       Web Role          Azure Queue

Company 2


  Client
#5 - Using the Cloud for Communications
            Proxy?
Company 1

            Firewall
                        http://app.queue.core.windows.net/
  Client

                                REST
                          Web Role          Azure Queue

Company 2


  Client
             Firewall
#5 - Using the Cloud for Communications
Company 1

                 Firewall
                               http://app.queue.core.windows.net/
   Client

                                       REST
                                 Web Role          Azure Queue

Company 2                      65.55.33.204


   Client
                  Firewall
192.168.14.100

                        NAT?
#5 - Using the Cloud for Communications
Company 1

                 Firewall
                                           http://app.queue.core.windows.net/
   Client

                                                   REST
                                             Web Role          Azure Queue

Company 2                                  65.55.33.204


   Client
                  Firewall
192.168.14.100
                   OK, so I’ll do a HTTP
                    poll every minute
#5 - Using the Cloud for Communications
Company 1

                 Firewall
                                       http://app.queue.core.windows.net/
   Client

                                                 REST
                                          Web Role         Azure Queue

Company 2                               65.55.33.204


   Client
                  Firewall
192.168.14.100
                      …and how about other
                    protocols other than HTTP?
How does the .NET Service Bus help?
#5 - Using the Cloud for Communications
Company 1

                              sb://.../myqueue
  Client



                                     .NET
                                  Service Bus

Company 2


  Client
Two modes: TCP Relay and Message Buffer
Two modes: TCP Relay and Message Buffer
#5 - Using the Cloud for Communications
Company 1

                                                        sb://.../myqueue
  Client



                                                               .NET
                                                            Service Bus

Company 2


  Client
            Firewall
                       Outbound bi-directional socket
                       Kept alive in background
#5 - Using the Cloud for Communications
Company 1

            Firewall
                                                         sb://.../myqueue
  Client               Outbound one-way socket



                                                                .NET
                                                             Service Bus

Company 2

                                                           Message routed
  Client
                                                            accordingly
             Firewall
                        Outbound bi-directional socket
                        Kept alive in background
#5 - Using the Cloud for Communications
This Conference
  Application        Firewall
                                                                  sb://.../myqueue
  My Laptop                     Outbound one-way socket
 Localhost:1000

                                                                         .NET
                                                                      Service Bus

   My Home

                                                                    Message routed
    Home PC
                                                                     accordingly
 192.168.14.193       Firewall
                                 Outbound bi-directional socket
                                 Kept alive in background
            SQL
           Express

         Port 1433
Two modes: TCP Relay and Message Buffer
#5 - Using the Cloud for Communications
Company 1

                                                      sb://.../myqueue
  Client



                                                             .NET
                                                          Service Bus

Company 2
                                ATOMPub via REST

  Client
            Firewall
                       Consumer defines and creates
                       a Message Buffer
#5 - Using the Cloud for Communications
Company 1
                  Producer sends messages to
                  the Message Buffer
                                               sb://.../myqueue
  Client


            Firewall
                                                      .NET
                                                   Service Bus

Company 2
                            ATOMPub via REST

  Client
            Firewall
#5 - Using the Cloud for Communications
Company 1

                                                  sb://.../myqueue
  Client


            Firewall
                                                         .NET
                                                      Service Bus

Company 2
                               ATOMPub via REST

  Client
            Firewall
                       Consumer picks up these messages
                       (retrieve, peek, lock)
Patterns for Cloud Computing
                   Takeaways

          Be careful consuming REST based
          queues using shared secret

          Firewalls/NATs can add additional
          trouble (especially non-HTTP)

          Learn how .NET Service Bus
          traverses in these scenarios
Patterns for Moving to the Cloud




        Putting the Patterns Together
Patterns for Cloud Computing




 We’ve covered 5 patterns, but Jim has one last
                  question…
Patterns for Cloud Computing




   Are there cases where these patterns work
                   together?
Putting the Patterns Together
           Windows Azure
               PHP




           Let’s build an
        application in PHP
       that scales to many
             nodes…
Putting the Patterns Together
Use the principles of     Windows Azure
  multi tenancy to             PHP          (10 nodes)
 create a version of
the application across
  multiple vendors
                         Google AppEngine
                           Java Servlet




                           Amazon EC2
                                            (5 nodes
                             ASP
                               .NET
                                            using ELB)
Putting the Patterns Together
                     Windows Azure
                          PHP




         Job
                    Google AppEngine
Client   Job          Java Servlet
                                       Compute results with
         Job                           a MapReduce-like way
                                        of distributing work
                      Amazon EC2        across all of these
                        ASP
                          .NET              applications
Putting the Patterns Together
Store the results
 in a SQL Azure         Windows Azure

     database                PHP




           Job
                       Google AppEngine
  Client   Job           Java Servlet     SQL Azure
                                           Database
           Job


                         Amazon EC2
                           ASP
                             .NET
Putting the Patterns Together
           .NET Service Bus
                               Windows Azure
                                    PHP




           Job
                              Google AppEngine
  Client   Job                  Java Servlet     SQL Azure
                                                  Database
           Job


   Coordinate                   Amazon EC2
 communication                    ASP
                                    .NET
through the .NET
   Service Bus
Putting the Patterns Together
         .NET Service Bus
                             Windows Azure
                                  PHP




         Job
                            Google AppEngine
Client   Job                  Java Servlet     SQL Azure
                                                Database
         Job


                              Amazon EC2
                                ASP
                                  .NET
Putting the Patterns Together
               .NET Service Bus
                                   Windows Azure     Store results
 How many prime                                      in SQL Azure
 numbers between                        PHP
1 and 10,000,000?                   Compute


               Job
                                  Google AppEngine
  Client       Job                  Java Servlet     SQL Azure
                                                      Database
                                    Compute
               Job


           40 jobs of
                                    Amazon EC2
            250,000
            numbers                   ASP
                                        .NET
                                     Compute
Demo: Prime Solver v2.0
Next Steps
Next Steps




       Obviously, our friend Jim, is fake…
Next Steps

             Make sure you have a clear definition
                    of Cloud Computing


               Explore the 5 usage patterns for
                    your scenarios today


                 Think about the next steps for
                implementation and migration
simon.guest@microsoft.com
   http://simonguest.com

Contenu connexe

Tendances

Cloud computing abstract
Cloud computing abstractCloud computing abstract
Cloud computing abstractJagadeesh Kumar
 
Cc unit 1 ppt
Cc unit 1 pptCc unit 1 ppt
Cc unit 1 pptDr VISU P
 
Cloud computing
Cloud computingCloud computing
Cloud computingJeroen
 
What Is Cloud Computing? | Cloud Computing For Beginners | Cloud Computing Tr...
What Is Cloud Computing? | Cloud Computing For Beginners | Cloud Computing Tr...What Is Cloud Computing? | Cloud Computing For Beginners | Cloud Computing Tr...
What Is Cloud Computing? | Cloud Computing For Beginners | Cloud Computing Tr...Simplilearn
 
Cloud Computing Basics - https://youtu.be/ohK8Nd8Jq_o
Cloud Computing Basics - https://youtu.be/ohK8Nd8Jq_oCloud Computing Basics - https://youtu.be/ohK8Nd8Jq_o
Cloud Computing Basics - https://youtu.be/ohK8Nd8Jq_oRahul Premchand
 
Cloud computing Introduction
Cloud computing IntroductionCloud computing Introduction
Cloud computing IntroductionYash Gajera
 
Introduction to Cloud Computing
Introduction to Cloud ComputingIntroduction to Cloud Computing
Introduction to Cloud ComputingTom Eberle
 
Introduction to Cloud computing
Introduction to Cloud computingIntroduction to Cloud computing
Introduction to Cloud computingMathews Job
 
Evolution of the cloud
Evolution of the cloudEvolution of the cloud
Evolution of the cloudsagaroceanic11
 
Introduction To Cloud Computing
Introduction To Cloud ComputingIntroduction To Cloud Computing
Introduction To Cloud Computingkevnikool
 
Understanding Cloud Computing (basics)
Understanding Cloud Computing (basics)Understanding Cloud Computing (basics)
Understanding Cloud Computing (basics)vvmenon22
 
An Introduction To Infarstructures For Cloud Computing V0.2
An Introduction To Infarstructures For Cloud Computing V0.2An Introduction To Infarstructures For Cloud Computing V0.2
An Introduction To Infarstructures For Cloud Computing V0.2Ignacio M. Llorente
 
Trend and Future of Cloud Computing
Trend and Future of Cloud ComputingTrend and Future of Cloud Computing
Trend and Future of Cloud Computinghybrid cloud
 
Introduction to Cloud Computing
Introduction to Cloud ComputingIntroduction to Cloud Computing
Introduction to Cloud ComputingAlessandro Iudica
 
Cloud Computing and Services | PPT
Cloud Computing and Services | PPTCloud Computing and Services | PPT
Cloud Computing and Services | PPTSeminar Links
 

Tendances (20)

Cloud computing abstract
Cloud computing abstractCloud computing abstract
Cloud computing abstract
 
Cc unit 1 ppt
Cc unit 1 pptCc unit 1 ppt
Cc unit 1 ppt
 
Cloud computing
Cloud computingCloud computing
Cloud computing
 
What Is Cloud Computing? | Cloud Computing For Beginners | Cloud Computing Tr...
What Is Cloud Computing? | Cloud Computing For Beginners | Cloud Computing Tr...What Is Cloud Computing? | Cloud Computing For Beginners | Cloud Computing Tr...
What Is Cloud Computing? | Cloud Computing For Beginners | Cloud Computing Tr...
 
Cloud Computing Basics - https://youtu.be/ohK8Nd8Jq_o
Cloud Computing Basics - https://youtu.be/ohK8Nd8Jq_oCloud Computing Basics - https://youtu.be/ohK8Nd8Jq_o
Cloud Computing Basics - https://youtu.be/ohK8Nd8Jq_o
 
Cloud computing Introduction
Cloud computing IntroductionCloud computing Introduction
Cloud computing Introduction
 
cloud computing basics
cloud computing basicscloud computing basics
cloud computing basics
 
Introduction to Cloud Computing
Introduction to Cloud ComputingIntroduction to Cloud Computing
Introduction to Cloud Computing
 
Introduction to Cloud computing
Introduction to Cloud computingIntroduction to Cloud computing
Introduction to Cloud computing
 
Cloud computing
Cloud computingCloud computing
Cloud computing
 
Evolution of the cloud
Evolution of the cloudEvolution of the cloud
Evolution of the cloud
 
Cloud computing
Cloud computingCloud computing
Cloud computing
 
A Seminar on Cloud Computing
A Seminar on Cloud ComputingA Seminar on Cloud Computing
A Seminar on Cloud Computing
 
Introduction To Cloud Computing
Introduction To Cloud ComputingIntroduction To Cloud Computing
Introduction To Cloud Computing
 
Cloud computing
Cloud computingCloud computing
Cloud computing
 
Understanding Cloud Computing (basics)
Understanding Cloud Computing (basics)Understanding Cloud Computing (basics)
Understanding Cloud Computing (basics)
 
An Introduction To Infarstructures For Cloud Computing V0.2
An Introduction To Infarstructures For Cloud Computing V0.2An Introduction To Infarstructures For Cloud Computing V0.2
An Introduction To Infarstructures For Cloud Computing V0.2
 
Trend and Future of Cloud Computing
Trend and Future of Cloud ComputingTrend and Future of Cloud Computing
Trend and Future of Cloud Computing
 
Introduction to Cloud Computing
Introduction to Cloud ComputingIntroduction to Cloud Computing
Introduction to Cloud Computing
 
Cloud Computing and Services | PPT
Cloud Computing and Services | PPTCloud Computing and Services | PPT
Cloud Computing and Services | PPT
 

En vedette

Enterprise reference architecture v1.2
Enterprise reference architecture   v1.2Enterprise reference architecture   v1.2
Enterprise reference architecture v1.2Ahmed Fattah
 
Cloud Computing Security
Cloud Computing SecurityCloud Computing Security
Cloud Computing Securitysyrinxtech
 
Enterprise reference architecture v1.1.ppt
Enterprise reference architecture   v1.1.pptEnterprise reference architecture   v1.1.ppt
Enterprise reference architecture v1.1.pptAhmed Fattah
 
Fighting The Top 7 Threats to Cloud Cybersecurity
Fighting The Top 7 Threats to Cloud CybersecurityFighting The Top 7 Threats to Cloud Cybersecurity
Fighting The Top 7 Threats to Cloud CybersecurityDavid Zaizar
 
Cloud Computing Architecture
Cloud Computing Architecture Cloud Computing Architecture
Cloud Computing Architecture Vasu Jain
 
Enterprise Architecture Governance for an Enterprise Transformation Journey: ...
Enterprise Architecture Governance for an Enterprise Transformation Journey: ...Enterprise Architecture Governance for an Enterprise Transformation Journey: ...
Enterprise Architecture Governance for an Enterprise Transformation Journey: ...Marcelo Sávio
 
Cloud computing architecture and vulnerabilies
Cloud computing architecture and vulnerabiliesCloud computing architecture and vulnerabilies
Cloud computing architecture and vulnerabiliesVinay Dwivedi
 
Patterns For Cloud Computing
Patterns For Cloud ComputingPatterns For Cloud Computing
Patterns For Cloud ComputingSimon Guest
 
NIST Cloud Computing Reference Architecture
NIST Cloud Computing Reference ArchitectureNIST Cloud Computing Reference Architecture
NIST Cloud Computing Reference ArchitectureThanakrit Lersmethasakul
 
Cloud computing reference architecture from nist and ibm
Cloud computing reference architecture from nist and ibmCloud computing reference architecture from nist and ibm
Cloud computing reference architecture from nist and ibmRichard Kuo
 

En vedette (11)

Enterprise reference architecture v1.2
Enterprise reference architecture   v1.2Enterprise reference architecture   v1.2
Enterprise reference architecture v1.2
 
Cloud Computing Security
Cloud Computing SecurityCloud Computing Security
Cloud Computing Security
 
Enterprise reference architecture v1.1.ppt
Enterprise reference architecture   v1.1.pptEnterprise reference architecture   v1.1.ppt
Enterprise reference architecture v1.1.ppt
 
Fighting The Top 7 Threats to Cloud Cybersecurity
Fighting The Top 7 Threats to Cloud CybersecurityFighting The Top 7 Threats to Cloud Cybersecurity
Fighting The Top 7 Threats to Cloud Cybersecurity
 
Cloud Computing Architecture
Cloud Computing Architecture Cloud Computing Architecture
Cloud Computing Architecture
 
Enterprise Architecture Governance for an Enterprise Transformation Journey: ...
Enterprise Architecture Governance for an Enterprise Transformation Journey: ...Enterprise Architecture Governance for an Enterprise Transformation Journey: ...
Enterprise Architecture Governance for an Enterprise Transformation Journey: ...
 
Cloud computing architecture and vulnerabilies
Cloud computing architecture and vulnerabiliesCloud computing architecture and vulnerabilies
Cloud computing architecture and vulnerabilies
 
Patterns For Cloud Computing
Patterns For Cloud ComputingPatterns For Cloud Computing
Patterns For Cloud Computing
 
Cloud Reference Model
Cloud Reference ModelCloud Reference Model
Cloud Reference Model
 
NIST Cloud Computing Reference Architecture
NIST Cloud Computing Reference ArchitectureNIST Cloud Computing Reference Architecture
NIST Cloud Computing Reference Architecture
 
Cloud computing reference architecture from nist and ibm
Cloud computing reference architecture from nist and ibmCloud computing reference architecture from nist and ibm
Cloud computing reference architecture from nist and ibm
 

Similaire à Patterns for Cloud Computing

Programatori cu capul in nori
Programatori cu capul in noriProgramatori cu capul in nori
Programatori cu capul in noriAlex Popescu
 
Real World Azure - IT Pros
Real World Azure - IT ProsReal World Azure - IT Pros
Real World Azure - IT ProsClint Edmonson
 
DDHS 2009 Microsoft Heads In The Cloud Feet On The Ground Peter de Haas...
DDHS 2009   Microsoft   Heads In The Cloud Feet On The Ground   Peter de Haas...DDHS 2009   Microsoft   Heads In The Cloud Feet On The Ground   Peter de Haas...
DDHS 2009 Microsoft Heads In The Cloud Feet On The Ground Peter de Haas...Peter de Haas
 
클라우드 컴퓨팅에 따른 데이터센터의 변화
클라우드 컴퓨팅에 따른 데이터센터의 변화클라우드 컴퓨팅에 따른 데이터센터의 변화
클라우드 컴퓨팅에 따른 데이터센터의 변화Fanny Lee
 
Personal robot industry v4
Personal robot industry v4Personal robot industry v4
Personal robot industry v436Kr.com
 
2009.05.21.Abiquo.Entrepeneurs.Day
2009.05.21.Abiquo.Entrepeneurs.Day2009.05.21.Abiquo.Entrepeneurs.Day
2009.05.21.Abiquo.Entrepeneurs.DayAbiquo, Inc.
 
Windows Azure Platfom By Soumow Atitallah
Windows Azure Platfom By Soumow AtitallahWindows Azure Platfom By Soumow Atitallah
Windows Azure Platfom By Soumow AtitallahSoumow Dollon
 
cloud computing
cloud computingcloud computing
cloud computingHyderabad
 
Session One Intro
Session One IntroSession One Intro
Session One Introrsnarayanan
 
Architecting & Developing On The Cloud Operating System Windows Azure V3
Architecting & Developing On The Cloud Operating System  Windows Azure  V3Architecting & Developing On The Cloud Operating System  Windows Azure  V3
Architecting & Developing On The Cloud Operating System Windows Azure V3Venkatarangan Thirumalai
 
Real World Azure - Dev
Real World Azure - DevReal World Azure - Dev
Real World Azure - DevClint Edmonson
 
Luis Alves Martins Presentation / CloudViews.Org - Cloud Computing Conference...
Luis Alves Martins Presentation / CloudViews.Org - Cloud Computing Conference...Luis Alves Martins Presentation / CloudViews.Org - Cloud Computing Conference...
Luis Alves Martins Presentation / CloudViews.Org - Cloud Computing Conference...EuroCloud
 
Cloud Computing with .Net
Cloud Computing with .NetCloud Computing with .Net
Cloud Computing with .NetWesley Faler
 
Windows Phone 7 and Windows Azure – A Match Made in the Cloud
Windows Phone 7 and Windows Azure – A Match Made in the CloudWindows Phone 7 and Windows Azure – A Match Made in the Cloud
Windows Phone 7 and Windows Azure – A Match Made in the CloudMichael Collier
 
CloudFest Denver Windows Azure Design Patterns
CloudFest Denver Windows Azure Design PatternsCloudFest Denver Windows Azure Design Patterns
CloudFest Denver Windows Azure Design PatternsDavid Pallmann
 
13h00 p duff-building-applications-with-aws-final
13h00   p duff-building-applications-with-aws-final13h00   p duff-building-applications-with-aws-final
13h00 p duff-building-applications-with-aws-finalLuiz Gustavo Santos
 

Similaire à Patterns for Cloud Computing (20)

Programatori cu capul in nori
Programatori cu capul in noriProgramatori cu capul in nori
Programatori cu capul in nori
 
Real World Azure - IT Pros
Real World Azure - IT ProsReal World Azure - IT Pros
Real World Azure - IT Pros
 
Cloud Computing
Cloud ComputingCloud Computing
Cloud Computing
 
DDHS 2009 Microsoft Heads In The Cloud Feet On The Ground Peter de Haas...
DDHS 2009   Microsoft   Heads In The Cloud Feet On The Ground   Peter de Haas...DDHS 2009   Microsoft   Heads In The Cloud Feet On The Ground   Peter de Haas...
DDHS 2009 Microsoft Heads In The Cloud Feet On The Ground Peter de Haas...
 
Cloud computing
Cloud computingCloud computing
Cloud computing
 
클라우드 컴퓨팅에 따른 데이터센터의 변화
클라우드 컴퓨팅에 따른 데이터센터의 변화클라우드 컴퓨팅에 따른 데이터센터의 변화
클라우드 컴퓨팅에 따른 데이터센터의 변화
 
Personal robot industry v4
Personal robot industry v4Personal robot industry v4
Personal robot industry v4
 
Cloud computing
Cloud computingCloud computing
Cloud computing
 
2009.05.21.Abiquo.Entrepeneurs.Day
2009.05.21.Abiquo.Entrepeneurs.Day2009.05.21.Abiquo.Entrepeneurs.Day
2009.05.21.Abiquo.Entrepeneurs.Day
 
Windows Azure Platfom By Soumow Atitallah
Windows Azure Platfom By Soumow AtitallahWindows Azure Platfom By Soumow Atitallah
Windows Azure Platfom By Soumow Atitallah
 
cloud computing
cloud computingcloud computing
cloud computing
 
Session One Intro
Session One IntroSession One Intro
Session One Intro
 
Architecting & Developing On The Cloud Operating System Windows Azure V3
Architecting & Developing On The Cloud Operating System  Windows Azure  V3Architecting & Developing On The Cloud Operating System  Windows Azure  V3
Architecting & Developing On The Cloud Operating System Windows Azure V3
 
Building a Hybrid Cloud
Building a Hybrid CloudBuilding a Hybrid Cloud
Building a Hybrid Cloud
 
Real World Azure - Dev
Real World Azure - DevReal World Azure - Dev
Real World Azure - Dev
 
Luis Alves Martins Presentation / CloudViews.Org - Cloud Computing Conference...
Luis Alves Martins Presentation / CloudViews.Org - Cloud Computing Conference...Luis Alves Martins Presentation / CloudViews.Org - Cloud Computing Conference...
Luis Alves Martins Presentation / CloudViews.Org - Cloud Computing Conference...
 
Cloud Computing with .Net
Cloud Computing with .NetCloud Computing with .Net
Cloud Computing with .Net
 
Windows Phone 7 and Windows Azure – A Match Made in the Cloud
Windows Phone 7 and Windows Azure – A Match Made in the CloudWindows Phone 7 and Windows Azure – A Match Made in the Cloud
Windows Phone 7 and Windows Azure – A Match Made in the Cloud
 
CloudFest Denver Windows Azure Design Patterns
CloudFest Denver Windows Azure Design PatternsCloudFest Denver Windows Azure Design Patterns
CloudFest Denver Windows Azure Design Patterns
 
13h00 p duff-building-applications-with-aws-final
13h00   p duff-building-applications-with-aws-final13h00   p duff-building-applications-with-aws-final
13h00 p duff-building-applications-with-aws-final
 

Plus de Simon Guest

10 Life Hacks for Better Productivity
10 Life Hacks for Better Productivity10 Life Hacks for Better Productivity
10 Life Hacks for Better ProductivitySimon Guest
 
Building a Great Engineering Culture
Building a Great Engineering CultureBuilding a Great Engineering Culture
Building a Great Engineering CultureSimon Guest
 
Interviewing Techniques
Interviewing TechniquesInterviewing Techniques
Interviewing TechniquesSimon Guest
 
Presentation Anti-Patterns
Presentation Anti-PatternsPresentation Anti-Patterns
Presentation Anti-PatternsSimon Guest
 
10 Life Hacks for Better Productivity
10 Life Hacks for Better Productivity10 Life Hacks for Better Productivity
10 Life Hacks for Better ProductivitySimon Guest
 
Automated Web Testing using JavaScript
Automated Web Testing using JavaScriptAutomated Web Testing using JavaScript
Automated Web Testing using JavaScriptSimon Guest
 
Advanced Tips & Tricks for using Angular JS
Advanced Tips & Tricks for using Angular JSAdvanced Tips & Tricks for using Angular JS
Advanced Tips & Tricks for using Angular JSSimon Guest
 
Indoor location in mobile applications using iBeacons
Indoor location in mobile applications using iBeaconsIndoor location in mobile applications using iBeacons
Indoor location in mobile applications using iBeaconsSimon Guest
 
Creating Context-Aware Applications
Creating Context-Aware ApplicationsCreating Context-Aware Applications
Creating Context-Aware ApplicationsSimon Guest
 
Automated Testing using JavaScript
Automated Testing using JavaScriptAutomated Testing using JavaScript
Automated Testing using JavaScriptSimon Guest
 
Enterprise Social Networking - Myth or Magic?
Enterprise Social Networking - Myth or Magic?Enterprise Social Networking - Myth or Magic?
Enterprise Social Networking - Myth or Magic?Simon Guest
 
Objective View of MEAPs
Objective View of MEAPsObjective View of MEAPs
Objective View of MEAPsSimon Guest
 
Top Ten Tips for HTML5/Mobile Web Development
Top Ten Tips for HTML5/Mobile Web DevelopmentTop Ten Tips for HTML5/Mobile Web Development
Top Ten Tips for HTML5/Mobile Web DevelopmentSimon Guest
 
Windows Azure Toolkit for iOS
Windows Azure Toolkit for iOSWindows Azure Toolkit for iOS
Windows Azure Toolkit for iOSSimon Guest
 
Developing Enterprise-Grade Mobile Applications
Developing Enterprise-Grade Mobile ApplicationsDeveloping Enterprise-Grade Mobile Applications
Developing Enterprise-Grade Mobile ApplicationsSimon Guest
 
My customers are using iPhone/Android, but I'm a Microsoft Guy.
My customers are using iPhone/Android, but I'm a Microsoft Guy.My customers are using iPhone/Android, but I'm a Microsoft Guy.
My customers are using iPhone/Android, but I'm a Microsoft Guy.Simon Guest
 
Developing iPhone and iPad apps that leverage Windows Azure
Developing iPhone and iPad apps that leverage Windows AzureDeveloping iPhone and iPad apps that leverage Windows Azure
Developing iPhone and iPad apps that leverage Windows AzureSimon Guest
 
iPhone and iPad Security
iPhone and iPad SecurityiPhone and iPad Security
iPhone and iPad SecuritySimon Guest
 
Building solutions on the Microsoft platform that target iPhone, iPad, and An...
Building solutions on the Microsoft platform that target iPhone, iPad, and An...Building solutions on the Microsoft platform that target iPhone, iPad, and An...
Building solutions on the Microsoft platform that target iPhone, iPad, and An...Simon Guest
 
Future of Mobility
Future of MobilityFuture of Mobility
Future of MobilitySimon Guest
 

Plus de Simon Guest (20)

10 Life Hacks for Better Productivity
10 Life Hacks for Better Productivity10 Life Hacks for Better Productivity
10 Life Hacks for Better Productivity
 
Building a Great Engineering Culture
Building a Great Engineering CultureBuilding a Great Engineering Culture
Building a Great Engineering Culture
 
Interviewing Techniques
Interviewing TechniquesInterviewing Techniques
Interviewing Techniques
 
Presentation Anti-Patterns
Presentation Anti-PatternsPresentation Anti-Patterns
Presentation Anti-Patterns
 
10 Life Hacks for Better Productivity
10 Life Hacks for Better Productivity10 Life Hacks for Better Productivity
10 Life Hacks for Better Productivity
 
Automated Web Testing using JavaScript
Automated Web Testing using JavaScriptAutomated Web Testing using JavaScript
Automated Web Testing using JavaScript
 
Advanced Tips & Tricks for using Angular JS
Advanced Tips & Tricks for using Angular JSAdvanced Tips & Tricks for using Angular JS
Advanced Tips & Tricks for using Angular JS
 
Indoor location in mobile applications using iBeacons
Indoor location in mobile applications using iBeaconsIndoor location in mobile applications using iBeacons
Indoor location in mobile applications using iBeacons
 
Creating Context-Aware Applications
Creating Context-Aware ApplicationsCreating Context-Aware Applications
Creating Context-Aware Applications
 
Automated Testing using JavaScript
Automated Testing using JavaScriptAutomated Testing using JavaScript
Automated Testing using JavaScript
 
Enterprise Social Networking - Myth or Magic?
Enterprise Social Networking - Myth or Magic?Enterprise Social Networking - Myth or Magic?
Enterprise Social Networking - Myth or Magic?
 
Objective View of MEAPs
Objective View of MEAPsObjective View of MEAPs
Objective View of MEAPs
 
Top Ten Tips for HTML5/Mobile Web Development
Top Ten Tips for HTML5/Mobile Web DevelopmentTop Ten Tips for HTML5/Mobile Web Development
Top Ten Tips for HTML5/Mobile Web Development
 
Windows Azure Toolkit for iOS
Windows Azure Toolkit for iOSWindows Azure Toolkit for iOS
Windows Azure Toolkit for iOS
 
Developing Enterprise-Grade Mobile Applications
Developing Enterprise-Grade Mobile ApplicationsDeveloping Enterprise-Grade Mobile Applications
Developing Enterprise-Grade Mobile Applications
 
My customers are using iPhone/Android, but I'm a Microsoft Guy.
My customers are using iPhone/Android, but I'm a Microsoft Guy.My customers are using iPhone/Android, but I'm a Microsoft Guy.
My customers are using iPhone/Android, but I'm a Microsoft Guy.
 
Developing iPhone and iPad apps that leverage Windows Azure
Developing iPhone and iPad apps that leverage Windows AzureDeveloping iPhone and iPad apps that leverage Windows Azure
Developing iPhone and iPad apps that leverage Windows Azure
 
iPhone and iPad Security
iPhone and iPad SecurityiPhone and iPad Security
iPhone and iPad Security
 
Building solutions on the Microsoft platform that target iPhone, iPad, and An...
Building solutions on the Microsoft platform that target iPhone, iPad, and An...Building solutions on the Microsoft platform that target iPhone, iPad, and An...
Building solutions on the Microsoft platform that target iPhone, iPad, and An...
 
Future of Mobility
Future of MobilityFuture of Mobility
Future of Mobility
 

Dernier

From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationSafe Software
 
A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?Igalia
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingEdi Saputra
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdflior mazor
 
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...Principled Technologies
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerThousandEyes
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...apidays
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoffsammart93
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...apidays
 
Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyKhushali Kathiriya
 
MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MIND CTI
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodJuan lago vázquez
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘RTylerCroy
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century educationjfdjdjcjdnsjd
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024The Digital Insurer
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonAnna Loughnan Colquhoun
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Miguel Araújo
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityPrincipled Technologies
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...Martijn de Jong
 

Dernier (20)

From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdf
 
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : Uncertainty
 
MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 

Patterns for Cloud Computing

  • 1. Patterns for Cloud Computing Simon Guest Senior Director, Technical Strategy Microsoft Corporation
  • 2. Patterns for Cloud Computing
  • 3. Patterns for Cloud Computing This is Jim
  • 4. Patterns for Cloud Computing Jim has many questions about cloud computing
  • 5. Patterns for Cloud Computing The more he reads, the more confused he gets
  • 6. Patterns for Cloud Computing “What is cloud computing?”
  • 7. Patterns for Cloud Computing “What are vendors doing in this space?”
  • 8. Patterns for Cloud Computing “What applications make sense in the cloud?”
  • 10. Session Objectives Build on Stefan’s introduction of of cloud computing Provide you with 5 patterns for cloud-based applications Show implementations of these patterns
  • 12. Defining Cloud Computing Application runs on-premises • Bring my own machines, Buy my own connectivity, software, etc.and hardware, • manage my own Complete control data center and responsibility • Upfront capital costs for the infrastructure
  • 13. Defining Cloud Computing Application runs Application runs at a on-premises hoster • Bring my own • Rent machines, machines, connectivity, Buy my own Pay someone to software connectivity, software, etc.and hardware, host my application • Less control, but • manage my own Complete control using hardware that fewer data center and responsibility I specify responsibilities • Upfront capital • Lower capital costs, costs for the but pay for fixed infrastructure capacity, even if idle
  • 14. Defining Cloud Computing Application runs Application runs at a Application runs using on-premises hoster cloud platform • Bring my own • Rent machines, • Shared, machines, connectivity, multi-tenant Pay someone for a Buy my own Pay someone to software environment connectivity, pool of computing software, etc.and hardware, host my application • Less control, but • Offers pool of resources that can • manage my own Complete control using hardware that fewer computing be applied to a set data center and responsibility I specify responsibilities resources, of applications abstracted from • Upfront capital • Lower capital costs, costs for the but pay for fixed infrastructure infrastructure capacity, even if idle • Pay as you go
  • 15. Defining Cloud Computing Cloud “Variants”
  • 16. Defining Cloud Computing Public Cloud
  • 17. Defining Cloud Computing Pool of computing resources offered by a vendor, typically using a “pay as you go” model
  • 18. Defining Cloud Computing Private Cloud
  • 19. Defining Cloud Computing Pool of computing resources that lives within a self managed datacenter
  • 20. Defining Cloud Computing Pool of computing resources that lives within a datacenter with no sharing
  • 21. Defining Cloud Computing Compute: Virtualized compute based on Windows Server Storage: Durable, scalable, & available storage Management: Automated, management of the service Database: Relational processing for structured/ unstructured data Service Bus: General purpose application bus Access Control: Rules-driven, claims-based access control
  • 22. Defining Cloud Computing Different Models Infrastructure as a Service (IaaS) vs. Platform as a Service (PaaS)
  • 23. Defining Cloud Computing Your Application Deployment Frameworks Deployment Web Server OS Services Provided by Windows Azure Operating System Provided Virtualized Instance By Amazon Hardware EC2
  • 24. Defining Cloud Computing Deployment Your Application Deployment Frameworks Web Server Provided by OS Services Provided by Google Windows Azure AppEngine Operating System Virtualized Instance Hardware
  • 25. Patterns for Cloud Computing #1 - Using the Cloud for Scale
  • 26. Patterns for Cloud Computing “Isn’t the cloud good for applications that need to scale dynamically?”
  • 27. Patterns for Cloud Computing “For example, applications that have spikes or peak loads”
  • 28. Patterns for Cloud Computing “How does this work?”
  • 29. Patterns for Cloud Computing Let’s do some white boarding for Jim…
  • 30. …and when I say white boarding, I really mean it
  • 31. #1 - Using the Cloud for Scale “Wow! What a great site!” Request Browser Web Tier B/L Tier Database Response
  • 32. #1 - Using the Cloud for Scale Browser Browser Browser Web Tier B/L Tier Database “Server Busy” Browser Browser
  • 33. #1 - Using the Cloud for Scale Browser Browser Browser Web Tier B/L Tier Database Browser “Timeout” Browser
  • 34. How would Jim do this today on premises?
  • 35. #1 - Using the Cloud for Scale How would Jim do this today on premises? Browser Browser Web Tier N Browser L Web Tier B/L Tier Database B Browser Web Tier Browser
  • 36. #1 - Using the Cloud for Scale How would Jim do this today on premises? Browser Browser B/L Tier N Browser Web Tier L B/L Tier Database B Browser B/L Tier Browser
  • 37. #1 - Using the Cloud for Scale How would Jim do this today on premises? Browser Browser Web Tier B/L Tier N N Browser L Web Tier L B/L Tier Database B B Browser Web Tier B/L Tier Browser
  • 38. #1 - Using the Cloud for Scale How would Jim do this today on premises? Browser p1 p2 p3 Browser Web Tier B/L Tier N N Browser L Web Tier L B/L Tier Database B B Browser Web Tier B/L Tier Browser
  • 40. #1 - Using the Cloud for Scale How would Jim do this today on premises? Browser p1 p2 p3 Browser Web Tier B/L Tier N N Browser L Web Tier L B/L Tier Database B B Browser Web Tier B/L Tier Browser “That took a lot of work - and money!”
  • 41. #1 - Using the Cloud for Scale How would Jim do this today on premises? p1 p2 p3 “Not so great now…” Web Tier B/L Tier N N Browser L Web Tier L B/L Tier Database B B Web Tier B/L Tier “That took a lot of work - and money!” “Hmmm... Most of this stuff is sitting idle...”
  • 42. #1 - Using the Cloud for Scale Datacenter peak load Usage Idle time Jan Apr Jul Oct
  • 43. How can cloud computing help?
  • 44. #1 - Using the Cloud for Scale “Wow! What a great site!” Request Browser Web Role Worker Role Azure Storage Response
  • 45. #1 - Using the Cloud for Scale Browser Browser Browser Web Role Worker Role Azure Storage “Server Busy” Browser Browser
  • 46.
  • 47.
  • 48. #1 - Using the Cloud for Scale Browser Browser Web Role N Browser L Web Role Worker Role Azure B Storage Browser Web Role Browser You don’t see this bit
  • 49. #1 - Using the Cloud for Scale Browser Browser Web Role Worker Role N N Browser L Web Role L Worker Role Azure B B Storage Browser Web Role Worker Role Browser
  • 50. OK, so changing config is easy... …but what else do I need to know?
  • 51. #1 - Using the Cloud for Scale Browser Browser Web Role Worker Role N N Browser L Web Role L Worker Role Azure B B Storage Browser Web Role Worker Role Browser
  • 52. #1 - Using the Cloud for Scale Browser Browser Web Role Worker Role N N Browser L Web Role L Worker Role Azure B B Storage Browser Web Role Worker Role Browser Tight coupling between web and worker role is an anti-pattern
  • 53. #1 - Using the Cloud for Scale 4. Process Web Role Worker Role 2. Respond to UI Req 1 Place on queue . 3. Pickup from queue Queue
  • 54. #1 - Using the Cloud for Scale 4. Process Web Role Worker Role Req 5. Add result to table Queue 6. Query table on refresh Table
  • 56. How many web and worker roles do you need?
  • 57. How many web and worker roles do you need?
  • 58. #1 - Using the Cloud for Scale WMI_Win32_PerfFormattedData_ASPNET_ASPNETApplications /RequestsPerSecond Browser Browser Web Role N Browser L Web Role Worker Role Azure B Storage Browser Web Role Browser Management API Log Worker Role or Email
  • 59. How many web and worker roles do you need?
  • 60. #1 - Using the Cloud for Scale Web Role Web Role Web Role Worker Role Req Req Req Queue Web Role Web Role Monitor queue length against user’s Web Role expectations
  • 61. #1 - Using the Cloud for Scale Web Role Worker Role Web Role Worker Role Web Role Worker Role Req Req Req Queue Web Role Worker Role Web Role Monitor queue Worker Role length against user’s Web Role expectations Worker Role
  • 62. Patterns for Cloud Computing Takeaways A core tenet of cloud computing is the ability to scale up/down Understand how to communicate between roles and nodes Strategy on when to scale up/down roles in production
  • 63. Patterns for Moving to the Cloud #2 - Using the Cloud for Multi Tenancy
  • 64. Patterns for Cloud Computing “I like the idea of scaling Web roles…”
  • 65. Patterns for Cloud Computing “…but need to serve multiple customers”
  • 66. Patterns for Cloud Computing “Without creating separate codebases!”
  • 67. How would Jim do this today on premises?
  • 68. #2 - Using the Cloud for Multi Tenancy How would Jim do this today on premises? Browser Web Tier B/L Tier Database Customer #1 Browser Web Tier B/L Tier Database Customer #2 Browser Web Tier B/L Tier Database Customer #3
  • 70. #2 - Using the Cloud for Multi Tenancy Browser Customer #1 Browser Web Tier B/L Tier Database Customer #2 Browser Customer #3
  • 71. Schema Customizations UI Customizations
  • 72. Schema Customizations UI Customizations
  • 73. 3 options for data in multi tenant environment
  • 74. #2 - Using the Cloud for Multi Tenancy Browser Fixed Schema Customer #1 Browser Web Tier B/L Tier Database Customer #2 Browser Option 1: Everyone Uses the Same Database/Schema Customer #3 Pros: Simplest approach, easy to maintain/upgrade. Cons: No customizations. Restoring of tenant data.
  • 75. #2 - Using the Cloud for Multi Tenancy Browser Database Customer #1 Customer #1 Browser Web Tier B/L Tier Database Customer #2 Customer #2 Browser Database Customer #3 Customer #3 Option 2: Give Each Customer Their Own Database/Schema Pros: Flexible. Tenant restore is easier. High Isolation. Cons: Can be costly. Difficult to upgrade db schemas.
  • 76. #2 - Using the Cloud for Multi Tenancy Browser Fixed Schema with Customizations Customer #1 Browser Web Tier B/L Tier Database Customer #2 Browser Option 3: Fixed Database/Schema, with customizations Customer #3 Pros: Customers can add their own custom fields Cons: Non standard way of customizing the schema. Tenant restore is difficult.
  • 77. #2 - Using the Cloud for Multi Tenancy Tenant * 1 TenantID int TenantName nvarchar * Employee EmployeeId int TypeID * Type int FirstName nvarchar Name nvarchar LastName nvarchar CLRType nvarchar 1 1 Customization * int * CustomizationID Value nvarchar
  • 78. #2 - Using the Cloud for Multi Tenancy Tenant * 1 TenantID 1 TenantName UK Branch * Employee EmployeeId 1 TypeID * Type 1 FirstName Gordon Name PostalCode LastName Brown CLRType string 1 1 Customization * 1 * CustomizationID Value SW1 2AA A
  • 79. #2 - Using the Cloud for Multi Tenancy Tenant * 1 TenantID 2 TenantName US Branch * Employee EmployeeId 2 TypeID * Type 2 FirstName Barack Name ZipCode LastName Obama CLRType string 1 1 Customization * 2 * CustomizationID Value 20500
  • 80. #2 - Using the Cloud for Multi Tenancy Tenant * 1 Fixed Schema TenantID 2 Applies to All Could be both TenantName US Branch * * Tenants Employee Type EmployeeId 2 TypeID 2 Customizable FirstName Barack Tenant by Tenant Name ZipCode LastName Obama Basis CLRType string 1 1 Customization * 2 * CustomizationID Value 20500
  • 81. Schema Customizations UI Customizations
  • 82. #2 - Using the Cloud for Multi Tenancy Browser Customer #1 Browser Web Tier B/L Tier Database Customer #2 Browser Customer #3
  • 84. Routing using MVC approach
  • 85. #2 - Using the Cloud for Multi Tenancy http://hr.contoso.co.uk Browser Customer #1 http://employeedata.cloudapp.net Browser Web Tier B/L Tier Database Customer #2 Browser Customer #3 http://hr.fabrikam.com
  • 86. #2 - Using the Cloud for Multi Tenancy http://hr.contoso.co.uk -> CNAME (employeedata.cloudapp.net) Browser Customer #1 http://employeedata.cloudapp.net Browser Web Tier B/L Tier Database Customer #2 Browser Customer #3 http://hr.fabrikam.com -> CNAME (employeedata.cloudapp.net)
  • 87. #2 - Using the Cloud for Multi Tenancy http://hr.contoso.co.uk -> CNAME (employeedata.cloudapp.net) Browser Customer #1 http://employeedata.cloudapp.net Browser Web Tier B/L Tier Database Customer #2 Use custom route to controller mapping Browser Customer #3 http://hr.fabrikam.com -> CNAME (employeedata.cloudapp.net)
  • 88. Demo: Multi Tenant Schema and UI
  • 89. Patterns for Cloud Computing Takeaways Always consider Multi Tenancy first, even if only one customer Design considerations must include both data and UI Many other considerations, such as identity – p&p guidance
  • 90. Patterns for Moving to the Cloud #3 - Using the Cloud for Compute
  • 91. Patterns for Cloud Computing Jim sees how cloud computing supports scaling up/down nodes
  • 92. Patterns for Cloud Computing “Can I use all of these nodes in parallel?”
  • 93. Patterns for Cloud Computing “I’ve got this complex calculation I would like to share across these multiple nodes…”
  • 94. #3 - Using the Cloud for Compute Data Data Worker Data Client Master Worker Data Worker
  • 95. #3 - Using the Cloud for Compute Result Worker Result Client Master Worker Result Worker Result
  • 96. Popularized by the term “MapReduce”* * 2004 OSDI paper by Jeff Dean and Sanjay Ghemawat (Google)
  • 97. #3 - Using the Cloud for Compute How many ”e”’s in “The quick brown fox jumps over the lazy dog”? M<k,v> Data Worker M<k,v> Client Master Worker M<k.v> Worker “Map” M<“the quick brown”.”e”> M<“fox jumps over”.”e”> M<“the lazy dog”.”e”>
  • 98. #3 - Using the Cloud for Compute L<k,v> Worker L<k,v> Client Master Worker Result Worker L<k,v> 3 x ”e”s found “Reduce” L<”e”,”1”> L<”e”,”1”> L<”e”,”1”>
  • 99. And it’s definitely popular...
  • 100. #3 - Using the Cloud for Compute Google 20pb of data analyzed every day using MapReduce Yahoo! 10k+ cores, 4pb of data using MapReduce Facebook 2500+ cores, 1pb of data using MapReduce
  • 102. #3 - Using the Cloud for Compute Apache Hadoop Open Source Java “Inspired by MapReduce” (Core, HDFS, many more) Cloudera Consulting, training, distribution of Hadoop Amazon Elastic MapReduce Hadoop implementation on EC2
  • 103. How would Jim do this today on premises?
  • 104. #3 - Using the Cloud for Compute How would Jim do this today on premises? Data Data Worker Data Client Master Worker Client Application Job/Task Scheduler Worker Data Remote Service
  • 105. How about implementing this on Windows Azure?
  • 106. #3 - Using the Cloud for Compute Data Worker Data Data Worker Client Web Role Data Client Application Job/Task Scheduler Worker Remote Service Req Queue Table
  • 107. Demo: Windows Azure Demo “Inspired by MapReduce”
  • 108. Patterns for Cloud Computing Takeaways MapReduce very visible, although can be difficult to initially grasp Learn about existing frameworks, especially Apache Hadoop Read up on Dryad (DryadLINQ) for future direction
  • 109. Patterns for Moving to the Cloud #4 - Using the Cloud for Storage
  • 110. Patterns for Cloud Computing “The cloud lets me store infinite data, right?”
  • 111. Patterns for Cloud Computing Lots of headaches with data management today
  • 112. Patterns for Cloud Computing “It sounds too good to be true…”
  • 113. How does Jim do this today on premises?
  • 114. #4 - Using the Cloud for Storage How would Jim do this today on premises? File RPC/NFS Client File Server Store
  • 115. #4 - Using the Cloud for Storage How would Jim do this today on premises? Data TDS (Tabular Data Stream) Client DB Server RDBMS
  • 116. #4 - Using the Cloud for Storage How would Jim do this today on premises? Data HTTP POST Browser Web Server Database
  • 117. #4 - Using the Cloud for Storage I love I love you! you too! Server Data Affinity between your data and physical hardware that serves it
  • 118. #4 - Using the Cloud for Storage I love I love you! you too! Server Data Symptoms: Which RAID number was that again? Tedious to backup exponentially growing data Crap! I’m at 95% capacity - got to move to a bigger disk
  • 119. How does the cloud help?
  • 120. Breaks the affinity between your data and hardware
  • 123. #4 - Using the Cloud for Storage PutBlob Blob Container PUT http://account.blob.core.windows./net/containername/blobname REST API Client Azure Blob Storage http://account.blob.core.windows.net/containername/blobname PutBlob = 64Mb MAX MetaData = 8Kb per Blob
  • 124. #4 - Using the Cloud for Storage Blob Container REST API Client Azure Blob Storage GetBlob GET http://account.blob.core.windows./net/containername/blobname http://account.blob.core.windows.net/containername/blobname
  • 125. #4 - Using the Cloud for Storage Blob Container REST API Client Azure Blob Storage GetBlob GET http://account.blob.core.windows./net/containername/blobname Range: bytes=329300 - 730000 http://account.blob.core.windows.net/containername/blobname
  • 126. #4 - Using the Cloud for Storage PutBlock(blobname, blockid, data) Blob Container PutBlockList(blobname, blockid1 …, blockidN) , REST API Client Azure Blob Storage http://account.blob.core.windows.net/containername/blobname PutBlock = 4Mb MAX to a maximum of 50Gb BlockId = 64 bytes
  • 128. #4 - Using the Cloud for Storage REST: GET http://account.table.core.windows.net/Customer?$filter=%20PartitionKey%20eq%20value LINQ: var customers = from o in context.CreateQuery<customer>(“Customer”) where o.PartitionKey == value select o; Worker Role Azure Table Storage http://account.table.core.windows.net Each Table: PartitionKey (e.g. DocumentName) to ensure scalability RowKey (e.g. version number) [fields] for data
  • 131. SQL Server Data Services (MIX08)
  • 132. #4 - Using the Cloud for Storage This is what I’m doing on premises... Data TDS Client DB Server RDBMS
  • 133. #4 - Using the Cloud for Storage So, this is what I would like to do in the cloud... Data TDS Client DB Server RDBMS
  • 134. SQL Data Services (MIX09)
  • 135. SQL Azure (July 2009)
  • 136. #4 - Using the Cloud for Storage So, this is what I would like to do... Data TDS Client SQL Azure RDBMS
  • 137. #4 - Using the Cloud for Storage HTTP TDS Browser Web Role SQL Azure RDBMS
  • 138. #4 - Using the Cloud for Storage HTTP Queue TDS Browser Web Role Worker Role SQL Azure RDBMS
  • 140. #4 - Using the Cloud for Storage “The Data Center” HTTP TDS Browser Web Tier Bus. Logic SQL Server RDBMS
  • 141. #4 - Using the Cloud for Storage “The Cloud” HTTP Queue TDS Browser Web Role Worker Role SQL Azure RDBMS
  • 143. Patterns for Cloud Computing Takeaways Storage in the cloud may look the same, but breaks the affinity issue Understand the pricing model for storage on-premises vs. cloud SQL Azure as a factor for migration/move from on premises
  • 144. Patterns for Moving to the Cloud #5 - Using the Cloud for Communications
  • 145. Patterns for Cloud Computing Jim’s organization needs to communicate with other organizations
  • 146. Patterns for Cloud Computing “This has always been a very tricky and expensive process to get working”
  • 147. Patterns for Cloud Computing “Does the cloud offer anything to help?”
  • 148. How would Jim have done this before?
  • 149. #5 - Using the Cloud for Communications Telco provided WAN Company 1 Company 2 Client Server FTP FTP Client Server
  • 150. #5 - Using the Cloud for Communications Internet Telco provided WAN Company 1 Company 2 Client Server FTP FTP Client Server
  • 151. #5 - Using the Cloud for Communications Internet Telco provided WAN Company 1 Company 2 DMZ Client Server Extranet Browser Site
  • 152. What does the cloud provide?
  • 153. #5 - Using the Cloud for Communications http://app.queue.core.windows.net/ REST Client Azure Queue
  • 154. #5 - Using the Cloud for Communications Company 1 http://app.queue.core.windows.net/ Client REST Azure Queue Company 2 Client
  • 155. #5 - Using the Cloud for Communications Company 1 http://app.queue.core.windows.net/ Client REST Azure Queue Company 2 Client
  • 156. #5 - Using the Cloud for Communications Company 1 http://app.queue.core.windows.net/ Client Primary Access Key REST Azure Queue Company 2 Client Primary Access Key
  • 157. #5 - Using the Cloud for Communications Company 1 http://app.queue.core.windows.net/ Client REST Web Role Azure Queue Company 2 Client
  • 158. #5 - Using the Cloud for Communications Proxy? Company 1 Firewall http://app.queue.core.windows.net/ Client REST Web Role Azure Queue Company 2 Client Firewall
  • 159. #5 - Using the Cloud for Communications Company 1 Firewall http://app.queue.core.windows.net/ Client REST Web Role Azure Queue Company 2 65.55.33.204 Client Firewall 192.168.14.100 NAT?
  • 160. #5 - Using the Cloud for Communications Company 1 Firewall http://app.queue.core.windows.net/ Client REST Web Role Azure Queue Company 2 65.55.33.204 Client Firewall 192.168.14.100 OK, so I’ll do a HTTP poll every minute
  • 161. #5 - Using the Cloud for Communications Company 1 Firewall http://app.queue.core.windows.net/ Client REST Web Role Azure Queue Company 2 65.55.33.204 Client Firewall 192.168.14.100 …and how about other protocols other than HTTP?
  • 162. How does the .NET Service Bus help?
  • 163. #5 - Using the Cloud for Communications Company 1 sb://.../myqueue Client .NET Service Bus Company 2 Client
  • 164. Two modes: TCP Relay and Message Buffer
  • 165. Two modes: TCP Relay and Message Buffer
  • 166. #5 - Using the Cloud for Communications Company 1 sb://.../myqueue Client .NET Service Bus Company 2 Client Firewall Outbound bi-directional socket Kept alive in background
  • 167. #5 - Using the Cloud for Communications Company 1 Firewall sb://.../myqueue Client Outbound one-way socket .NET Service Bus Company 2 Message routed Client accordingly Firewall Outbound bi-directional socket Kept alive in background
  • 168. #5 - Using the Cloud for Communications This Conference Application Firewall sb://.../myqueue My Laptop Outbound one-way socket Localhost:1000 .NET Service Bus My Home Message routed Home PC accordingly 192.168.14.193 Firewall Outbound bi-directional socket Kept alive in background SQL Express Port 1433
  • 169. Two modes: TCP Relay and Message Buffer
  • 170. #5 - Using the Cloud for Communications Company 1 sb://.../myqueue Client .NET Service Bus Company 2 ATOMPub via REST Client Firewall Consumer defines and creates a Message Buffer
  • 171. #5 - Using the Cloud for Communications Company 1 Producer sends messages to the Message Buffer sb://.../myqueue Client Firewall .NET Service Bus Company 2 ATOMPub via REST Client Firewall
  • 172. #5 - Using the Cloud for Communications Company 1 sb://.../myqueue Client Firewall .NET Service Bus Company 2 ATOMPub via REST Client Firewall Consumer picks up these messages (retrieve, peek, lock)
  • 173. Patterns for Cloud Computing Takeaways Be careful consuming REST based queues using shared secret Firewalls/NATs can add additional trouble (especially non-HTTP) Learn how .NET Service Bus traverses in these scenarios
  • 174. Patterns for Moving to the Cloud Putting the Patterns Together
  • 175. Patterns for Cloud Computing We’ve covered 5 patterns, but Jim has one last question…
  • 176. Patterns for Cloud Computing Are there cases where these patterns work together?
  • 177. Putting the Patterns Together Windows Azure PHP Let’s build an application in PHP that scales to many nodes…
  • 178. Putting the Patterns Together Use the principles of Windows Azure multi tenancy to PHP (10 nodes) create a version of the application across multiple vendors Google AppEngine Java Servlet Amazon EC2 (5 nodes ASP .NET using ELB)
  • 179. Putting the Patterns Together Windows Azure PHP Job Google AppEngine Client Job Java Servlet Compute results with Job a MapReduce-like way of distributing work Amazon EC2 across all of these ASP .NET applications
  • 180. Putting the Patterns Together Store the results in a SQL Azure Windows Azure database PHP Job Google AppEngine Client Job Java Servlet SQL Azure Database Job Amazon EC2 ASP .NET
  • 181. Putting the Patterns Together .NET Service Bus Windows Azure PHP Job Google AppEngine Client Job Java Servlet SQL Azure Database Job Coordinate Amazon EC2 communication ASP .NET through the .NET Service Bus
  • 182. Putting the Patterns Together .NET Service Bus Windows Azure PHP Job Google AppEngine Client Job Java Servlet SQL Azure Database Job Amazon EC2 ASP .NET
  • 183. Putting the Patterns Together .NET Service Bus Windows Azure Store results How many prime in SQL Azure numbers between PHP 1 and 10,000,000? Compute Job Google AppEngine Client Job Java Servlet SQL Azure Database Compute Job 40 jobs of Amazon EC2 250,000 numbers ASP .NET Compute
  • 186. Next Steps Obviously, our friend Jim, is fake…
  • 187. Next Steps Make sure you have a clear definition of Cloud Computing Explore the 5 usage patterns for your scenarios today Think about the next steps for implementation and migration
  • 188. simon.guest@microsoft.com http://simonguest.com