Cloud Computing Architectures
Cloud Computing Architectures
AWS architecture
• 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
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
& Access
Identity
Web
Networking
Compute
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
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
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
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
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
Nod
e
3-Tier service pattern
Load Balancer
• Scale with
partitioned Front End
storage (Stateless
Web)
• Increase reliability
with queues
Load Balancer
• Application state
lives in the Front End
compute tier (Stateless
Web)
• Built in
transactions
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
• Example:
– Create a tweet when a file is saved to Dropbox
• Introduction Video
• Tutorial
API App – Create, Consume and Host API
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
Windows
8.x Windows
Windows Phone HTML5 &
10 iOS 8/10 Android Javascript
Azure Mobile Apps vs. Azure Mobile Services
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
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
• 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
• 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