All artwork on this slide deck created by Josh Twist. If you steal it please provide credit and a...

16
All artwork on this slide deck created by Josh Twist . If you steal it please provide credit and a link to http://www.thejoyofcode.com/clo ud_artwork.aspx

Transcript of All artwork on this slide deck created by Josh Twist. If you steal it please provide credit and a...

All artwork on this slide deck created by Josh Twist. If you steal it please

provide credit and a link to http://www.thejoyofcode.com/cloud_artwork.aspx

CLOUDS, GUIDs and HOUNDS

Josh TwistPrincipal ADM

Premier Support for Developers (PSfD)Microsoft UK

www.thejoyofcode.com@joshtwist

[email protected]

The Scenario

Predictable Bursting

High level stuff you already know

Web Roles Worker Roles

Table Storage Blob Storage SQL Azure

The Architecture

Push

LOTS of

users

Problem 1: Seriously? A guid?

Internet Explorer 9

Possible Solutions

Use SQL Azure

Create a global counter

Configure Partitions0-

1,000,000

1,000,001 -

2,000,000

2,000,001 -

3,000,000

The problem(s) with configuration

X

XX

Our Solution

R = 1,000

R = 1,000

Write back new max identifier where eTag is

the same.

Request current max identifier

3,000

eTag = XCV243987243KD

Nice!

• Rate of requests to storage = Rate of requests / R(not related to the number of nodes)

• Entirely self managing• Produces relatively sequential

identifiers• Incredibly fast• Configuration can be modified at

runtime if necessary

Problem 2: Release the Hounds!

Solution 1: Polling

Poll

Poll

Poll

Unleash!

Go!

Polling Approach

Pros Cons

Easy Peasy Polling always feels a bit… ‘naff’?

Cheap Inherent latency (up to T)

Solution 2: Listening

Connect

Connect

Connect

Unleash!

Unleash!

Unleash!

Unleash!

Listening Approach

Pros Cons

Direct! Feels good.

Costs money to open connections from your ‘n’ nodes

No Latency? Actual Latency

No state. A freshly provisioned node could miss the ‘unleash’ signal.

Thanks!

This story will feature in November’s MSDN magazine

www.thejoyofcode.com@joshtwist

[email protected]

Want to know more about PSfD?

Mail me.

Any Qs? Get me on

Twitter