microsoft azure throttling

15
Windows Azure Throttling

Upload: julien-plee

Post on 05-Aug-2015

176 views

Category:

Software


0 download

TRANSCRIPT

Windows Azure Throttling

TalentSoft

Windows Azure Throttling

Julien PLEEResponsable R&D

TalentSoft

[email protected], @julplee

TalentSoft#talentsoft

AZURE THROTTLING

What is throttling?

TalentSoft#talentsoft

• Multi-Tenant• Resource Management

– Resource Governance– Resource Limits– Engine Throttling

• Affects multiples services• Sql Database Network

Topology

Windows Azure Sql Database Case

TalentSoft#talentsoft

Windows Azure Sql DatabaseUne seule base de données logique

Plusieurs réplicas

physiques

Primaire unique P

lusi

eu

rs c

ible

s se

con

dair

es

Réplic

a 1

Réplic

a 2

Réplic

a 3

Pare

-feu

TalentSoft#talentsoft

Soft Throttling

• Throttles the activities of a subset of Sql Databases that consume most resources

Hard Throttling

• Final Stage. • No more connections

are allowed until resources are freed up

Engine Throttling

40501: The service is currently busy. Retry the request after 10 seconds. Incident ID: <ID>. Code: <code>.

TalentSoft#talentsoft

• Worker Threads and Sessions limits• Depends on Web/Business/Premium

mode• Error code differs from Engine

Throttling (10928)

Resource Governance

TalentSoft#talentsoft

• Database Size• Transaction Duration• Transaction Lock Count• tempdb• Transaction Log Length• Memory Usage

Resource Limits

démo

TalentSoft#talentsoft

AZURE THROTTLING

TalentSoft#talentsoft

AZURE THROTTLING

How to solve problems?

TalentSoft#talentsoft

Solutions• Entity Framework 6• Enterprise Library 5.0 Integration

Pack for Windows Azure• More money: Sql Database Premium

Azure Throttling & Transient Fault Handling

TalentSoft#talentsoft

Sql Database Premium

Reservation Size

CPU Cores

Worker Threads

Active Sessions

Disk IO (IOPS)

Memory (GB)

P1 1 200 2000 150 8

P2 2 400 4000 300 16

démo

TalentSoft#talentsoft

AZURE THROTTLING

Manage throttling

TalentSoft#talentsoft

Hello Talent Case: TransactionInterceptor.cspublic void Intercept(IInvocation invocation){

...

if (Transaction.Current == null){RetryPolicy policy = new RetryPolicy<SqlDatabaseTransientErrorDetectionStrategy>(...);

var transactionOptions = ...

policy.ExecuteAction(() =>{using (var transactionScope = new TransactionScope(...)){invocation.Proceed();transactionScope.Complete();}});}

}