0% found this document useful (0 votes)
252 views81 pages

Cloud Computing Architectures

The document describes key components of AWS and Microsoft Azure cloud architectures. It outlines services like EC2, S3, and ELB in AWS, which provide compute, storage, and load balancing. In Azure, it mentions various management, developer, analytics and IoT services, as well as global data center regions. Common elements between the platforms include virtual machines, storage, databases, analytics tools, and content delivery networks.

Uploaded by

Ayush Shah
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
252 views81 pages

Cloud Computing Architectures

The document describes key components of AWS and Microsoft Azure cloud architectures. It outlines services like EC2, S3, and ELB in AWS, which provide compute, storage, and load balancing. In Azure, it mentions various management, developer, analytics and IoT services, as well as global data center regions. Common elements between the platforms include virtual machines, storage, databases, analytics tools, and content delivery networks.

Uploaded by

Ayush Shah
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 81

Cloud Architectures

AWS architecture

*In the above diagram S3 stands for Simple Storage Service.


Description
• This is the basic structure of AWS EC2,
where EC2 stands for Elastic Compute Cloud. EC2
allow users to use virtual machines of different
configurations as per their requirement. It allows
various configuration options, mapping of
individual server, various pricing options, etc. We
will discuss these in detail in AWS Products
section. Following is the diagrammatic
representation of the architecture.
Load Balancing
• Load balancing simply means to hardware or software
load over web servers, that improver's the efficiency
of the server as well as the application.
• Hardware load balancer is a very common network
appliance used in traditional web application
architectures.
• AWS provides the Elastic Load Balancing service, it
distributes the traffic to EC2 instances across multiple
available sources, and dynamic addition and removal
of Amazon EC2 hosts from the load-balancing rotation.
Elastic Load Balancing
• Elastic Load Balancing can dynamically grow
and shrink the load-balancing capacity to
adjust to traffic demands and also support
sticky sessions to address more advanced
routing needs.
Amazon Cloud-front

• It is responsible for content delivery, i.e. used to deliver website.


It may contain dynamic, static, and streaming content using a
global network of edge locations. Requests for content at the
user's end are automatically routed to the nearest edge location,
which improves the performance.
• Amazon Cloud-front is optimized to work with other Amazon
Web Services, like Amazon S3 and Amazon EC2. It also works
fine with any non-AWS origin server and stores the original files
in a similar manner.
• In Amazon Web Services, there are no contracts or monthly
commitments. We pay only for as much or as little content as we
deliver through the service.
Elastic Load Balancer

• It is used to spread the traffic to web servers, which


improves performance. AWS provides the Elastic
Load Balancing service, in which traffic is distributed
to EC2 instances over multiple available zones, and
dynamic addition and removal of Amazon EC2 hosts
from the load-balancing rotation.
• Elastic Load Balancing can dynamically grow and
shrink the load-balancing capacity as per the traffic
conditions.
Security Management

• Amazon’s Elastic Compute Cloud (EC2) provides a


feature called security groups, which is similar to an
inbound network firewall, in which we have to
specify the protocols, ports, and source IP ranges
that are allowed to reach your EC2 instances.
• Each EC2 instance can be assigned one or more
security groups, each of which routes the
appropriate traffic to each instance. Security groups
can be configured using specific subnets or IP
addresses which limits access to EC2 instances.
Elastic Caches

• Amazon Elastic Cache is a web service that


manages the memory cache in the cloud. In
memory management, cache has a very
important role and helps to reduce the load
on the services, improves the performance
and scalability on the database tier by caching
frequently used information.
Amazon RDS

• Amazon RDS (Relational Database Service) provides


a similar access as that of MySQL, Oracle, or
Microsoft SQL Server database engine. The same
queries, applications, and tools can be used with
Amazon RDS.
• It automatically patches the database software and
manages backups as per the user’s instruction. It
also supports point-in-time recovery. There are no
up-front investments required, and we pay only for
the resources we use.
Hosting RDMS on EC2 Instances

• Amazon RDS allows users to install RDBMS (Relational Database


Management System) of your choice like MySQL, Oracle, SQL Server,
DB2, etc. on an EC2 instance and can manage as required.
• Amazon EC2 uses Amazon EBS (Elastic Block Storage) similar to
network-attached storage. All data and logs running on EC2 instances
should be placed on Amazon EBS volumes, which will be available even
if the database host fails.
• Amazon EBS volumes automatically provide redundancy within the
availability zone, which increases the availability of simple disks. Further
if the volume is not sufficient for our databases needs, volume can be
added to increase the performance for our database.
• Using Amazon RDS, the service provider manages the storage and we
only focus on managing the data.
Storage & Backups

• AWS cloud provides various options for storing, accessing, and backing up web
application data and assets. The Amazon S3 (Simple Storage Service) provides a simple
web-services interface that can be used to store and retrieve any amount of data, at any
time, from anywhere on the web.
• Amazon S3 stores data as objects within resources called buckets. The user can store as
many objects as per requirement within the bucket, and can read, write and delete
objects from the bucket.
• Amazon EBS is effective for data that needs to be accessed as block storage and requires
persistence beyond the life of the running instance, such as database partitions and
application logs.
• Amazon EBS volumes can be maximized up to 1 TB, and these volumes can be striped
for larger volumes and increased performance. Provisioned IOPS volumes are designed
to meet the needs of database workloads that are sensitive to storage performance and
consistency.
• Amazon EBS currently supports up to 1,000 IOPS per volume. We can stripe multiple
volumes together to deliver thousands of IOPS per instance to an application.
Auto Scaling

• The difference between AWS cloud architecture and the


traditional hosting model is that AWS can dynamically
scale the web application fleet on demand to handle
changes in traffic.
• In the traditional hosting model, traffic forecasting models
are generally used to provision hosts ahead of projected
traffic. In AWS, instances can be provisioned on the fly
according to a set of triggers for scaling the fleet out and
back in. Amazon Auto Scaling can create capacity groups
of servers that can grow or shrink on demand.
Key Considerations for Web Hosting in AWS

• No physical network devices needed


– In AWS, network devices like firewalls, routers, and
load-balancers for AWS applications no longer
reside on physical devices and are replaced with
software solutions.
– Multiple options are available to ensure quality
software solutions. For load balancing choose
Zeus, HAProxy, Nginx, Pound, etc. For establishing
a VPN connection choose OpenVPN, OpenSwan,
Vyatta, etc.
Contd..
• No security concerns
– AWS provides a more secured model, in which every host is
locked down. In Amazon EC2, security groups are designed for
each type of host in the architecture, and a large variety of
simple and tiered security models can be created to enable
minimum access among hosts within your architecture as per
requirement.
• Availability of data centers
– EC2 instances are easily available at most of the availability
zones in AWS region and provides model for deploying your
application across data centers for both high availability and
reliability.
Microsoft Azure
Microsoft Azure – 17 Regions Worldwide in
Mid 2015

Azure
footprin
t
Data Centers

Regional Partners
Microsoft Azure Services

Management

Marketplace
Developer
Services

Visual …
Studio Applicatio Automatio Operation
Online n Insights Scheduler n al Insights Key Vault

Integration
Analytics

Hybrid
& IoT

Media & CDN


Machine Stream Data Event BizTalk Service Site Media
HDInsight Learning Analytics Factory Hubs Services Bus Backup Recovery Services
& Mobile

& Access
Identity
Web

API Mobile Azure Multi-


App Web Mobile API Logic Managem Notificatio Engageme Active Factor
Service App App App App ent n Hubs nt Directory Authent CDN

Networking
Compute

Virtual Cloud Service RemoteAp Virtual ExpressRo Traffic Applicatio


Machines Services Batch Fabric p Network ute Manager DNS n Gateway
& Storage
Data

Data
Blobs Tables Queu Files SQL Document Redis Warehous
Storage es Database Search DB Cache StorSimple Data Lake e
Availability Sets
Availability
set
SLA High Availabilit
Hardware and
SQL
SQL
Server Server Software
Seconda
Primary
Virtual ry
Virtual
Virtual
Windows and Linux
Machine Machine

SLA 99.95
Load Balancing

Internal and External PORT VM1


80 LBHTTP
/healthcheck.aspx
TCP/UDP
ACLs PORT 80 LB PORT VM2
80
LBHTTP
/healthcheck.aspx
Client Affinity
PORT
80
VM3
LBHTTP
/healthcheck.aspx
ARM – Resource Group
• Container for multiple resources
• Resources exist in one and only one resource
group
• Resource groups can span regions
• Resource groups can span services

22
PaaS Services
There are many PaaS services such as:
– Application & Web site deployment to an existing VM Image
– Authentication, Identity & Access Control
– Application Services
• Web, Mobile, Logic
– Cloud Containers
• Docker, Service Fabric
– Databases (SQL & No SQL)
– Content Delivery Network (CDN)
– Messaging, Queues & Service Bus
– Distributed Cache
– Business Workflows
– Video (Media) Transcoding &
Streaming
– Business Analytics, BI & Reporting
– HPC & Big Data
– IoT event streaming
Compute Continuum
IaaS PaaS

VM
Service App
VMs Extension
Fabric Service
s

Ultima Rapid
te Developme
Control nt

NDA Confidential
Cloud Storage - Azure BLOB Storage
• BLOB – Binary Large OBject
• Storage for any type of entity such as binary files and text
documents
• Distributed File Service (DFS)
– Scalability and High availability
• BLOB file is distributed between multiple server and
replicated at least 3 times

• Get Started with Storage Account


• Get Started with Blob Storage
Azure Blob Storage Concepts
http://<account>.blob.core.windows.net/<container>/
<blobname>

Account Container Blob Pages/


Blocks
PIC01.JP
G
Block/Pa
images
ge
PIC02.JP
G
contoso
Block/Pa
ge
videos VID1.AVI

26
Blob Operations

PutBlob

REST
GetBlob
DeleteBlob
CopyBlob
SnapshotBl
ob Windows Azure
LeaseBlob Storage
Cloud Storage - SQL Azure
• SQL Server in the cloud
• No administrative overheads
• Shared or Reserved (Dedicated) Hardware
• High Availability
• pay-as-you-grow pricing
• Familiar Development Model

• Create your first Azure SQL database


Cloud Storage - Table Storage
• Not RDBMS
– No relationships between entities
– NoSql
• Entity can have up to 255 properties - Up to 1MB per entity
• Mandatory Properties for every entity
– PartitionKey & RowKey (only indexed properties)
• Uniquely identifies an entity
• Same RowKey can be used in different PartitionKey
• Defines the sort order

– Timestamp - Optimistic Concurrency


• Strongly consistent
• Get Started with Table Storage
Table Storage Concepts
Account Table Entity
Name =…
Email = …
custome
rs Name =…
EMailAdd=
contoso Photo ID
=…
Date =…
photos
Photo ID
=…
Date =…

30
Cloud Storage - DocumentDB
• A fully managed, highly scalable, queryable, schema-free
document database, delivered as a service, for modern
applications Query against Schema-Free JSON

Multi-Document transactions

Tunable, High Performance

Designed for cloud first

Get started with the


DocumentDB .NET SD
PaaS - Azure Service Fabric
Battle-hardened for over 5 years
Skype
Azure
for
Docume
Intun Busines
nt DB
Azure e s
Core billions
800k Hybrid
Infrastruct transacti
device Ops
ure ons/we
ek s Event
thousands Hubs
of Bing
machines Cortana 20bn
Azure events/d
SQL ay
Databas 500m
Pow
e evals/sec
er BI
1.4
million
What is a Microservice?
• Is (logic + state) that is independently versioned, deployed, and scaled
• Has a unique name that can be resolved
e.g. fabric:/myapplication/myservice
• Interacts with other microservices over well defined interfaces and
protocols like REST
• Remains always logically consistent in the presence of failures
• Hosted inside a “container” (code + config)
• Can be written in any language and framework
– node.js, Java VMs, any EXE
• Developed by a small engineering team

34
Types of microservices
• Stateless microservice
– Has either no state or it can be retrieved from an external store
– There can be N instances
– e.g. web frontends, protocol gateways, Azure Cloud Services etc.

• Stateful microservice
– Maintain hard, authoritative state
– N consistent copies achieved through replication and local
persistence
– e.g. database, documents, workflow, user profile, shopping cart
etc.

35
Cluster: A federation of machines
A set of machines
that Service Fabric Nod
e

stitches together
to form a cluster
Nod Nod
e e

Clusters can scale


to
1000s of machines Nod
e Nod
e

Nod
e
3-Tier service pattern
Load Balancer

• Scale with
partitioned Front End
storage (Stateless
Web)

• Increase reliability
with queues

• Reduce read Stateless


latency with Middle-tier
caches Compute

• Manage your own


transactions for Cache
state consistency

• Many moving Queues Storage


parts each
managed
differently
Stateful services: Simplify design, reduce latency

Load Balancer

• Application state
lives in the Front End
compute tier (Stateless
Web)

• Low Latency reads


and writes

• Partitions are first Stateful


class for scale-out Middle-tier
Compute

• Built in
transactions

• Fewer moving data stores used for analytics and disaster


parts recovery
Stateful Microservices are Reliable and
Consistent
• Each service is backed by replica set to make its
internal state reliable
• All replicas are logically consistent – meaning all
replicas see the same linearized order of read
and write operations to initial state
• Read-Write quorums are supported and are
dynamically adjusted
• Replica set is dynamically reconfigured to
account for replica arrivals and departures
39
Microservices placement and failover

Node Node Node Node Node Node


100 101 102 103 104 105

P S P P S P
S S S S S
P S
S P S S S S
S S S S
S
Get Started
– Reliable Actors: The canonical HelloWorld
walk-through scenario
– Reliable Services: Getting Started with
Microsoft Azure Service Fabric Reliable
Services
PaaS - Azure App Service
Azure App Service: One Integrated Offering

Web Apps Mobile Apps


Web apps that scale Build Mobile apps
with your business for any device

Logic Apps API Apps


Automate business Easily build and
process across SaaS consume APIs in the
and on-premises cloud
Azure App Service
• A new offering, consolidating and replacing existing services:
– Azure Web Sites, Azure BizTalk Services, Azure Web API Authoring,
Azure Mobile Services
• Create web and mobile experiences that share data access
and business logic
• Automate business processes with logic apps
• Build custom APIs or consume connectors from Marketplace
• One common billing model for all of your App Services
• Use a common Gateway to authenticate
Logic App – Easy Automation and Integration

• No code designer for rapid creation


• Dozens of pre-built templates to get started
• Out of box support for popular SaaS and on-premises apps
• Use with custom API apps of your own
• Biztalk APIs for expert integration scenarios

• Example:
– Create a tweet when a file is saved to Dropbox
• Introduction Video
• Tutorial
API App – Create, Consume and Host API

• Dozens of built-in APIs for popular SaaS


• An ecosystem of APIs for any need
• Create and publish custom, reusable APIs
• Visual Studio tooling with one click publish
and remote debugging
• Automatic client SDK generation for many
languages
Built-in API Connectors
Connectors
• Box • QuickBooks • Azure Web Jobs
• Chatter • SalesForce • Yammer
• Delay • Sugar CRM • Dynamics CRM
• Dropbox • SAP • Dynamics AX
• Azure HD Insight • Azure Service Bus • Hybrid
• Marketo • Azure Storage Connectivity
• Azure Media • Timer /
Services Recurrence
• OneDrive • Twilio
• SharePoint • Twitter
• SQL Server • IBM DB2
• Office 365 • Informix
• Oracle • Websphere MQ

Protocols BizTalk Services


• HTTP, HTTPS • Batching / • X12
Debatching • EDIFACT
• File
• Validate • AS2
• Flat File • Extract (XPath) • TPMOM
• FTP, SFTP • Transform • Rules Engine
• POP3/IMAP (+Mapper)
• SMTP • Convert (XML-
JSON)
• SOAP + WCF
• Convert (XML-
FF)
Azure Web Apps
• Rich monitoring and • Share capacity across Web
alerting and Mobile
• Traffic manager • Staging slots
• Custom CNAMEs – Validate changes in your
staging environment before
• VNET and VPN publishing to production
• Backup and restore • More DevOps features
• Many VM size and – Support for BitBucket and
instance options Visual Studio Online;
seamless integration with
• In production A/B testing GitHub
• Auto load-balance • Web Jobs
Azure Mobile App
Azure Mobile App
Offline SyncData Backend code
connections

SQ Table Mongo O365 API


L s Apps

Mobile
User Authentication
REST API

SDKs
Windows Xamarin
iOS PhoneGap
Android Sencha
HTML 5/JS Faceb Twitt Micros Goo Azure
ook er oft gle Active
Director
y
Offline
sync
Push Notifications

iOS Andr Windo Kindle In-App


OSX oid ws
Chro
me
Azure Mobile App / Mobile Services

• A Turnkey Backend for Employee Mobile Apps


• Deliver Native & Cross Platform Apps
• Enable Corporate Single Sign-On
• Integrate w/ O365 and On-Premise Enterprise
Systems
• Connect To Any Data Source
• Enable Offline and Real-Time Sync
• Leverage Your Existing Skills with .NET Web API
Supported Platforms

Windows
8.x Windows
Windows Phone HTML5 &
10 iOS 8/10 Android Javascript
Azure Mobile Apps vs. Azure Mobile Services

• Mobile Services – in classic portal


• Mobile Apps – preview portal
• When Mobile Apps is GA, will have all the features of
Mobile Services

• Your investment is safe!


– Azure Mobile App is still in preview
– New features will go into Mobile Apps
– Azure Mobile Services is still supported
– After GA, Microsoft to offer a seamless migration experience
JavaScript vs .NET
JavaScript
• Based on server side scripts
– Node.JS Scripts
• Intercept CRUD requests to tables
• Passes through to SQL by default
• Fully customizable logic flow
• Edit in Azure Portal or via GIT integration
• Currently (October 15) limited support in the
new Mobile App
.NET
• Based on ASP.NET Web API 2
• Full .NET support
• Intercept CRUD requests to tables
– Custom APIs available using Web API 2
• Fully customizable logic flow
• Standard VS tooling & support
• Local debugging
• Standard MS Deploy to Azure
Data Storage
New Data Model

SQL Database

TableController
BYOD
DTO

DataManager
DTO
Table Storage
Device Mobile Service/App

MongoDB
Azure SQL DB
• Out-of-the-box implementation
• Easily store relational data
• Fully integrated with Mobile Services
Azure Table Storage
• Azure Table Storage is a highly-scalable cost-
effective key-value data store
– NoSQL
– Every item is addressable by combination of:
• Partition Key
• Row Key
• Store non-relational data
• .NET backend only
Azure Blob Storage
• Storing Blobs in a database is inefficient
– BLOB storage is much cheaper and scalable
• Can manually integrate the backend
(C#/JavaScript) with Blob storage to store
blobs
• Only store a reference to the blob (URI) in the
DB
Existing SQL Database

TableController
Existi System
DTO ng Properti
Table es
DataManager Table
DTO Model s

Device Mobile App/Service SQL Azure/BYOD

AutoMapper
On-Premise SQL Database
• Hybrid Connections Your
Enterprise
Microsoft
Azure
Hybrid
Connec
tion 1433
Manage
r
Connection string
points to My-
Database:1433
My-Database
The REST API
Base REST API Endpoint URL
https://Mobileservice.azure-
mobile.net/tables/*
Data Operations and their REST Equivalents
Action HTTP Verb URL Suffix
Create POST /TodoItem
Read GET /TodoItem?$filter=id
%3D42
Update PATCH /TodoItem/id
Delete DELETE /TodoItem/id
Authentication & Authorization
Social Authentication
• Authenticate against Microsoft Account, Twitter,
Facebook, Google
• Table level permissions for each CRUD operation
– Everyone
– Anyone with the Application Key
– Only Authenticated Users
– Only Scripts and Admins
• More granular control with server side code
– User Level: Admin, Authenticated, Anonymous
– User Id: Id or undefined if not authenticated
Social Authentication
R
Provid
er E
G
Token S
A Valid
T
User ID
APP T +
Token
User ID + E A
Auth
Token W P
I
A
Y
Enterprise Authentication
• Use Azure Active Directory
• Extend line-of-business to mobile
• Bring turn-key login experience with corporate
credentials to mobile developers
• Enable applications built around
organizational structures
Offline Access & Synchronization
Offline Data Sync
• The best mobile apps handle network
interruptions gracefully
• Adding offline sync to an app is usually hard
• With Azure Mobile App, it’s easy
Why Use Mobile Offline Sync?
• Improve app responsiveness by caching server
data locally on the device
• Make apps resilient against intermittent network
connectivity
• Allow end-users to create and modify data even
when there is no network access
• Sync data across multiple devices
• Detect and handle conflicts when the same
record is modified by more than one client
Push Notifications
Push is Transforming Businesses
Broadcast breaking news Send notifications based
to millions of customers on account changes or
using their preferences actions

Engage customer to Increase employee


improve your brand, productivity and
customer satisfaction, responsiveness
and business metrics
Push Notification
• Register device handle at app launch
101
1. Client app retrieves handle from Platform 1
Notification Service (PNS)
4
2. Client app sends handle to your custom backend
Client app

• Send Notification
3. Your backend connects to PNS and requests push
2
Your code has to map between logical users and 3 Platform
device handles Notificatio
n
4. PNS pushes notification to device Service
5

• Maintain backend device handles


5. Your code must delete expired handles when
App back-
PNS rejects them end
6
6. Your code must map between logical users and device
handles
Azure Notification
• Register device handle at app launch
Hub
1. Client app retrieves handle from Platform Notification Service
2. Client sends handle to your backend
Backend registers with Notification Hub using tags to
represent logical users and groups 1 4

• Send Notification
3. Backend sends request to Notification Hub using a tag Client app PNS
Notification Hub manages scale
Notification Hub maps logical users/groups to device
handles 4 5
4. Notification Hub delivers notifications to matching 2
devices via PNS
• Maintain backend device handles
5. Notification Hub deletes expired handles when PNS 6
2 3
rejects them Notification
App back-
6. Notification Hub maintains mapping between logical end Hub
users/groups and device handles
Advantages of Notification Hub
• X-plat: one API to notify on any mobile platform
– Backend can be on-prem or in the cloud, .NET, Java, PHP, Node, you name it
– Support iOS, Android, Windows Phone, Windows, Kindle
• Avoid storing device information in your tables
• Work with logical users and segments
• Personalization and localization
– Templates
• Broadcast at scale, multicast, unicast
• Rich Telemetry
• Get Started with Windows App
• Blog Post
SignalR
SignalR
• A library for ASP.NET developers
• Simplifies the process of adding real-time
web functionality to applications
– Stock tickers
– Notifications
– Any real-time server to client information
• SDKs are available in various platforms
• Azure Mobile Services allows integrating
SignalR communication
– Easily integrate web based clients
– .NET Backend Only

You might also like