windows azure storage services

Post on 20-May-2015

1.886 Views

Category:

Technology

1 Downloads

Preview:

Click to see full reader

DESCRIPTION

This presentation shows overview about storage services (tables, queues, blob) in Windows Azure platform. The demo project can be found here: http://cid-fb4ac1330711a759.skydrive.live.com/redir.aspx?resid=FB4AC1330711A759!119

TRANSCRIPT

WINDOWS AZURE STORAGE SERVICESDuy Lam

Cloud computing

Cloud Application

Cloud Platforms

Cloud Infrastructure

2

Windows Azure platform• A group of cloud technologies, each providing a specific set of services to

application developers• Windows Azure Platform Offers

3

Windows Azure• “Compute” to run Windows applications• “Storage” to store the data in the cloud

4

Compute

5

• Implemented using ASP.NET, WCF, or another technology that works with IISWeb role

• Not being hosted in IISWorker role

Storage

6

• Unstructured dataBlobs• Literally table, not relational tableTables• Communicate between Web role and Worker roleQueues

<http|https>://<account-name>.<service>.core.windows.net/<resource-path>

blobqueuetable

• This “tables” is not relational tables. It’s structured storage and flexible schema: form of Tables, which contain a set of Entities, which contains a set of named Properties

• Work with LINQ, WCF (ADO .NET) Data Services and REST

• Practice:• Visual Studio Project Template• “Hello world” Window Azure Table

7

Tables Service

How to debug

Observe underline REST request with Fiddler: DevelopmentStorageProxyUri=http://ipv4.fiddler

8

Fun with properties• Timestamp property:

• Read only• Optimistic Concurrency

• PartitionKey & RowKey properties• Provide the uniqueness for an entity in a table• Scale the table• Sorting

9

10

PartitionKey(Category)

RowKey(Title)

Timestamp ReleaseDate

Action Fast & Furious

… 2009

Action The Bourne Ultimatum

… 2007

… … … …

Animation Open Season 2

… 2009

Animation The Ant Bully

… 2006

… … … …

Comedy Office Space

… 1999

… … … …

SciFi X-Men Origins: Wolverine

… 2009

… … … …

War Defiance … 2008

Partitioning

11

PartitionKey(Category)

RowKey(Title)

Timestamp

ReleaseDate

Action Fast & Furious … 2009

Action The Bourne Ultimatum

… 2007

… … … …

Animation Open Season 2 … 2009

Animation The Ant Bully … 2006PartitionKey(Category)

RowKey(Title)

Timestamp

ReleaseDate

Comedy Office Space … 1999

… … … …

SciFi X-Men Origins: Wolverine

… 2009

… … … …

War Defiance … 2008

Partitioning

Other features• Entity group transactions (EGT)

• Atomically manipulate entities in same partition in a single transaction

• 100 commands in a single transaction and payload < 4 MB

• Continuation Tokens x-ms-continuation-NextPartitionKey x-ms-continuation-NextRowKey

12

Remember• Support query operators: From, Where, Take, First,

FirstOrDefault• Cross-Table Consistency

13

14

Queues Service

Benefits

Scalability

Traffic Bursts

Decoupling Front-End Roles from Back-End Roles

15

How it works

16

VisibilityTimeout

Notes• Queue

• No limit on the number of messages• A message is stored for at most a week• Can have metadata associated in the form of <name, value>

pairs(up to 8KB in size per queue)• Messages

• Up to 8KB in size• VisibilityTimeout: 30 seconds by default, 2 hours maximum• PopReceipt: is required when deleting a message• No guaranteed return order of the messages from a queue

17

18

19

Blob Service

Models

20

Notes• Use directory-like hierarchy for the blob names and then

list all the "directories“ by using CloudBlobContainer.GetDirectoryReference() method

• Permission on blob containers

21

var storageAccount = CloudStorageAccount.FromConfigurationSetting("DataConnection").CreateCloudBlobClient().GetContainerReference("movies");

var blobContainer = storageAccount.CreateCloudBlobClient().GetContainerReference("movies");

blobContainer.CreateIfNotExist();

var blobPermissions = blobContainer.GetPermissions();blobPermissions.PublicAccess = BlobContainerPublicAccessType.Container;blobContainer.SetPermissions(blobPermissions);

Action/Rocky1.wmvAction/Rocky2.wmvAction/Rocky3.wmv

22

Q & AThank you

To start with• Install Windows Azure SDK• Microsoft Whitepapers:

• Introducing the Windows Azure Platform• Windows Azure Table – Programming Table Storage• Windows Azure Blob – Programming Blob Storage• Windows Azure Queue - Programming Queue Storage

• Windows Azure Tables and Queues Deep Dive - PDC09• Windows Azure Blob and Drive Deep Dive - PDC09• Neil Mackenzie blog

24

top related