Tuesday, January 06, 2015

Read a Thin Book - Cloud Architecture Patterns - 2

CDN

Content Delivery Network

Definition

A service that provide global caching.

Benefits


Reduce latency by routing client to nearest data node.
Distribute load to multiple nodes
Redundancy by replication
Availability
scalability

Drawbacks


First access to the file is slower(subsequent access is faster by accessing local region cache)

Mechanics

Edge caching. providing content to user from closest location. CDN's role is to provide edge caching.

Cache content (files) on many nodes globally around the world.

Only master copy matters.

It differs from multisite deployment in term of content vs application, reading vs reading and writing.

Using URL provided by CDN provider so that CDS can determine when to use cache

Whenever user want to access content controlled by CDN service, CDN will determine closest CDN node to serve client. anycast protocal)

Cached content has expiration period, and changes will be propagated by CDN service.

Challenges

Cache can be out of dated. Sync needs time to happen. (example of eventual consistency. immediate consistency is traded off to availability ad scalability)

Usage

Good for repeatedly used files,  big multimedia files such as video and voice content

Misc

Usually this can be enabled in cloud storage service. E.g. Windows Azure Blob Storage.

No comments: