SlideShare a Scribd company logo
1 of 42
More Cache for Less Cash
Michael S. Collier
@MichaelCollier
CodeMash – January 10, 2014
Michael S. Collier
• Principal Cloud Architect, Aditi

• michaelc@aditi.com
• @MichaelCollier
• www.MichaelSCollier.com
Today’s Agenda
•
•
•
•
•
•

6

Why Cache?
Cache Options in Windows Azure
What’s New in the Windows Azure Cache Service
Demos
Monitoring and Scaling
Pricing and Features
Why Cache?

7
Why Cache?

8
What is Windows Azure Cache?

A distributed, in-memory,
flexible cache for all data
types that can be used to
speed up Windows Azure
applications and reduce
database load.
Basically, cache helps your app
become faster.
10

Windows Azure Cache
A Cache Story

Shared Cache

In-Role Cache

• Cloud Services

• Cloud Services

• Shared – quotas

• Co-located (free)

• Lacked feature parity

• Dedicated ($$)

• Multiple size options

• Feature parity

• Expensive
• Performance challenged
• Throttling

• Good performance

• Deprecated August 2014

11

• Not multi-tenant

Cache Service
• Cloud Services, Web Sites,
or VMs

• Feature parity
• Managed infrastructure
• Price/capacity tiers

• Good performance (1ms
read)
A Cache Story

Shared Cache

In-Role Cache

• Cloud Services

• Cloud Services

• Shared – quotas

• Co-located (free)

• Lacked feature parity

• Dedicated ($$)

• Multiple size options

• Feature parity

• Expensive
• Performance challenged
• Throttling

• Good performance

• Deprecated August 2014

12

• Not multi-tenant

Cache Service
• Cloud Services, Web Sites,
or VMs

• Feature parity
• Managed infrastructure
• Price/capacity tiers

• Good performance (1ms
read)
A Cache Story

Shared Cache

In-Role Cache

• Cloud Services

• Cloud Services

• Shared – quotas

• Co-located (free)

• Lacked feature parity

• Dedicated ($$)

• Multiple size options

• Feature parity

• Expensive
• Performance challenged
• Throttling

• Good performance

• Deprecated August 2014

http://aka.ms/MigrateFromSharedCaching
13

• Not multi-tenant

Cache Service
• Cloud Services, Web Sites,
or VMs

• Feature parity
• Managed infrastructure
• Price/capacity tiers

• Good performance (1ms
read)
In-Role Cache (Co-located)

Source: Windows Azure Training Kit

14
In-Role Cache (Dedicated)

Source: Windows Azure Training Kit

15
In-Role Cache (Dedicated)

Source: Windows Azure Training Kit

16
In-Role Cache
•
•
•
•
•

Released w/ Oct. 2012 release of Azure SDK 1.8
Cache part of your Cloud Service application
No quotas or throttling
Isolation, flexibility, and control
High performance

• Features: named cache, regions, tagging, HA, local, notifications
• Pro: You manage as part of your application
• Con: You manage it; only available to Cloud Service roles in
same deployment
17
Create and Configure In-Role Cache
Configure a Role in the Cloud Service to host the cache

18
Configure the Cache Clients
• Use NuGet to configure the cache clients
• Microsoft.WindowsAzure.Caching
• Settings placed in web.config or app.config
• Modify to point to the cache server role
<dataCacheClients>
<dataCacheClient name="default">
<!--To use the in-role flavor of Windows Azure Cache, set identifier to be the cache cluster role name -->
<!--To use the Windows Azure Cache Service, set identifier to be the endpoint of the cache cluster -->
<autoDiscover isEnabled="true" identifier="MyScores.Web" />
<!--<localCache isEnabled="true" sync="TimeoutBased" objectCount="100000" ttlValue="300" />-->
</dataCacheClient>
</dataCacheClients>

Role Name
19
DEMO TIME!!!
20
Monitoring the Cache
Diagnostic Data Collected
Level
0
Critical/catastrophic server logs only
1
Data to help in assessing usage patterns, cache health, and potential errors.
Default.
2
3
4

Fine grain data for all requests and important system information
Diagnostic data with more verboseness and system information
Highest verbosity logs for all requests and system information

Provides a single setting for cache servers and clients
Configures levels for logs, traces, performance counters & crash dumps
Full details at http://aka.ms/CacheDiagnostics
21
Monitoring the Cache
• Set cache diagnostic level in configuration or portal
• Level (1-4) controls verbosity, perf counters, &
crash dumps.
• Start at 1 and increase as needed
<Role name="WorkerRole1">
<Instances count="1" />
<ConfigurationSettings>
<!– Cache Server -->
<Setting name="Microsoft.WindowsAzure.Plugins.Caching.DiagnosticLevel“ value="1" />
<!– Cache Client-->
<Setting name="Microsoft.WindowsAzure.Plugins.Caching.ClientDiagnosticLevel" value="1" />
</ConfigurationSettings>
</Role>

Full details at http://mcollier.net/AzureCacheDiag

22
Monitoring the Cache
public class WebRole : RoleEntryPoint
{
public override bool OnStart()
{
// Enable cache diagnostics
DiagnosticMonitorConfiguration dmConfig =
DiagnosticMonitor.GetDefaultInitialConfiguration();

// Configure collection of cache diagnostic data.
CacheDiagnostics.ConfigureDiagnostics(dmConfig);
DiagnosticMonitor.Start("Microsoft.WindowsAzure.Plugins.Diagnostics.ConnectionString",
dmConfig);
return base.OnStart();
}
}

23
Considerations
• Unable to create DataCache in RoleEntryPoint
• Max object size is 8MB post serialized
• Default serializer is NetDataContractSerializer

• Cost only for role instances
• Only accessible from within same Cloud Service
• Deployment will impact the cache (instances recycle)
24
What’s New in Windows Azure Cache?

App1

VM

VM

App2

VM

Shared Azure
Website Stamp

IaaS VMs

Cloud Services

Windows Azure Cache
25

1. SLA backed
2. Microsoft Managed
3. Scalable & Resilient
Create and Configure the Cache Service
• Create via management portal
• Choose an offering
• Basic (128MB to 1GB in 128MB
units, 1 named cache)
• Standard (1GB to 10GB in 1GB
units, notifications, and 10
named caches)
• Premium (5GB to 150GB in
5GB units, notifications, HA, and
10 named caches)

• Locate in same region as client
for best perf and cost
26
DEMO TIME!!!
27
Monitoring the Cache

28
Scaling the Cache

Dynamically scale without loosing any existing data
29
High Availability

Client

Read / Write

Primary

Premium only
Doubles required memory

Write

Secondary

Increased latency & decreased throughput
30
Where Can You Use the New Azure Cache?
Cloud Service Windows Azure Web Site Windows Azure VM Windows Azure
Mobile Service
.NET
Applications
PHP
(PECL)

Java
(spymemcached)

Node.js
C++
(libmemcached)





















Hopefully addressed by GA
31
Pricing Details
Basic

Standard

Premium

$12.50/month
(prorated hourly)

$50/month
(prorated hourly)

$200/month
(prorated hourly)

128 MB

1 GB

5 GB

Up to 8 units

Up to 10 units

Up to 30 units

Named Caches

1

10

10

High Availability







Notifications







Price Per Unit
(Preview)
Cache Size
Scale

Price includes a 50% preview discount.
Technical support through forums only (during preview)

See http://mcollier.net/AzureCachePricing
34
Benefits of the Windows Azure Cache
• Use from any app types (VM, Web Site, Mobile Service*, Cloud Service)
• Each instance deployed within dedicated VMs (fast, predictable
performance)
• No quotas or throttling
• Store up to 150GB per cache instance
• Avg. retrieval time of 1ms. Insert in about 1.2ms
• Highly available / distributed across multiple servers
• Managed service – focus on apps not infrastructure
• Same .NET cache API used with in-role cache for Cloud Services
• Support for ASP.NET Session State and Page Output Caching
• Unique cache service instance for each app, or share across apps
35
Common Architecture
Web Roles

2. Read

1. Read

3. Write

Storage Table

Windows Azure Cache

36
Common Architecture
Worker Roles

Read

Web Roles

Read

Windows Azure Load Balancer

Preload the cache
Carefully choose expiration
and eviction settings

37

Windows Azure Cache

SQL Database
(Windows Azure)
Common Architecture
Windows Azure Load Balancer

Web Roles

Read

Write

Read

Write

Write

Worker Roles

Storage Queue

Windows Azure Cache
Storage Table

38

SQL Database
(Windows Azure)
Guidelines - Configuration
• Multiple named caches for different cache settings
(HA, notifications, TTL, etc.)

40
Guidelines - Features

• Local Cache
• Pro:
• Fastest performance

• Con:
• Stale data (compensate w/ notification invalidation)
• Additional memory pressure

41
Guidelines – High Availability & Regions
• High Availability
• Pro: More durable cached data
• Con: 2x the writes (memory / performance)

• Regions
• Pro: Supports organization, tagging, and searching
• Con: Lives on a single cache server

42
Cloud Service Fundamentals - Caching
• Factory implementation
• Custom BinarySerializer class
• protobuf-net
• Fast and small

http://mcollier.net/AzureCSF

43
Where to Cache?
Cache Service

Usage Scenarios
Pricing

SDK/Language Support

In-Role Cache

Cloud Services, Mobile Services,
Web Sites, and VMs
Pay per Month

Cloud Services
Co-located – free
Dedicated – pay per hour

.NET SDK

1 Medium Cloud Service instance (3.5 GB RAM): $119/month
2 GB Standard cache (2, 1GB units): $100/month
3 A7 dedicated instances (56 GB RAM each): $3,147/month
150GB Premium cache (30, 5GB units): $6,000/month

44

.NET SDK
Where to Cache?
Mix cache solutions for price / manageability / features
Windows Azure Load Balancer

Web Roles
•

Data shared by other
services/apps

•

General application
data

Read

In-role
cache
•
•

45

Session / Page Output Cache
FREE!

Windows Azure Cache
Summary
• In-Role Cache
• Cloud Services only
• Co-located (free) or Dedicated ($$$)
• Isolated cache-related workload

• Cache Service
• Microsoft managed service, dedicated tenant, SLA backed
• Cloud Services, Web Sites, and VMs
• Full parity with in-role cache (SDK)

• Shared Caching Service to be deprecated
46
More Resources
•

Scott Guthrie’s blog
•

•

Windows Azure Cache Service (Preview)
•

•

http://blogs.msdn.com/b/windowsazure/archive/2013/10/03/cloud-service-fundamentals-cachingbasics.aspx

Capacity Planning Spreadsheet
•

47

http://code.msdn.microsoft.com/Windows-Azure-Caching-NFL-e2a534a5

Cloud Service Fundamentals – Caching Basics
•

•

http://msdn.microsoft.com/library/hh916611.aspx

Windows Azure Cache Sample
•

•

http://msdn.microsoft.com/en-us/library/windowsazure/dn386094.aspx

Optimization Guidance for Windows Azure Caching
•

•

http://weblogs.asp.net/scottgu/archive/2013/09/03/windows-azure-new-distributed-dedicated-highperformance-cache-service-more-cool-improvements.aspx

http://msdn.microsoft.com/en-us/library/hh914129
Ask your questions
Thank You!
• Michael S. Collier
• Principal Cloud Architect, Aditi

• michaelc@aditi.com
• @MichaelCollier
• www.MichaelSCollier.com

More Related Content

What's hot

What's New for the Windows Azure Developer? Lots!!
What's New for the Windows Azure Developer?  Lots!!What's New for the Windows Azure Developer?  Lots!!
What's New for the Windows Azure Developer? Lots!!Michael Collier
 
Using Windows Azure for Solving Identity Management Challenges
Using Windows Azure for Solving Identity Management ChallengesUsing Windows Azure for Solving Identity Management Challenges
Using Windows Azure for Solving Identity Management ChallengesMichael Collier
 
Windows Azure for Developers - Service Management
Windows Azure for Developers - Service ManagementWindows Azure for Developers - Service Management
Windows Azure for Developers - Service ManagementMichael Collier
 
Using Windows Azure for Solving Identity Management Challenges (Visual Studio...
Using Windows Azure for Solving Identity Management Challenges (Visual Studio...Using Windows Azure for Solving Identity Management Challenges (Visual Studio...
Using Windows Azure for Solving Identity Management Challenges (Visual Studio...Michael Collier
 
Windows Azure: Lessons From the Field
Windows Azure: Lessons From the FieldWindows Azure: Lessons From the Field
Windows Azure: Lessons From the FieldMichael Collier
 
Windows Azure for Developers - Building Block Services
Windows Azure for Developers - Building Block ServicesWindows Azure for Developers - Building Block Services
Windows Azure for Developers - Building Block ServicesMichael Collier
 
10 Ways to Gaurantee Your Azure Project will Fail
10 Ways to Gaurantee Your Azure Project will Fail10 Ways to Gaurantee Your Azure Project will Fail
10 Ways to Gaurantee Your Azure Project will FailMichael Collier
 
Inside Azure Resource Manager
Inside Azure Resource ManagerInside Azure Resource Manager
Inside Azure Resource ManagerMichael Collier
 
Infrastructure as Code for Beginners
Infrastructure as Code for BeginnersInfrastructure as Code for Beginners
Infrastructure as Code for BeginnersDavid Völkel
 
ECS & ECR Deep Dive - 김기완 솔루션즈 아키텍트 :: AWS Container Day
ECS & ECR Deep Dive - 김기완 솔루션즈 아키텍트 :: AWS Container DayECS & ECR Deep Dive - 김기완 솔루션즈 아키텍트 :: AWS Container Day
ECS & ECR Deep Dive - 김기완 솔루션즈 아키텍트 :: AWS Container DayAmazon Web Services Korea
 
AWS Infrastructure as Code - September 2016 Webinar Series
AWS Infrastructure as Code - September 2016 Webinar SeriesAWS Infrastructure as Code - September 2016 Webinar Series
AWS Infrastructure as Code - September 2016 Webinar SeriesAmazon Web Services
 
Microsoft Windows Server AppFabric
Microsoft Windows Server AppFabricMicrosoft Windows Server AppFabric
Microsoft Windows Server AppFabricMark Ginnebaugh
 
Windows Phone 7 and Windows Azure – A Match Made in the Cloud
Windows Phone 7 and Windows Azure – A Match Made in the CloudWindows Phone 7 and Windows Azure – A Match Made in the Cloud
Windows Phone 7 and Windows Azure – A Match Made in the CloudMichael Collier
 
Deep Dive - Infrastructure as Code
Deep Dive - Infrastructure as CodeDeep Dive - Infrastructure as Code
Deep Dive - Infrastructure as CodeAmazon Web Services
 
AWS January 2016 Webinar Series - Managing your Infrastructure as Code
AWS January 2016 Webinar Series - Managing your Infrastructure as CodeAWS January 2016 Webinar Series - Managing your Infrastructure as Code
AWS January 2016 Webinar Series - Managing your Infrastructure as CodeAmazon Web Services
 
Building Highly Scalable Java Applications on Windows Azure - JavaOne S313978
Building Highly Scalable Java Applications on Windows Azure - JavaOne S313978Building Highly Scalable Java Applications on Windows Azure - JavaOne S313978
Building Highly Scalable Java Applications on Windows Azure - JavaOne S313978David Chou
 
[PL] Code Europe 2016 - Python and Microsoft Azure
[PL] Code Europe 2016 - Python and Microsoft Azure[PL] Code Europe 2016 - Python and Microsoft Azure
[PL] Code Europe 2016 - Python and Microsoft AzureMichał Smereczyński
 
AWS와 Docker Swarm을 이용한 쉽고 빠른 컨테이너 오케스트레이션 - AWS Summit Seoul 2017
AWS와 Docker Swarm을 이용한 쉽고 빠른 컨테이너 오케스트레이션 - AWS Summit Seoul 2017AWS와 Docker Swarm을 이용한 쉽고 빠른 컨테이너 오케스트레이션 - AWS Summit Seoul 2017
AWS와 Docker Swarm을 이용한 쉽고 빠른 컨테이너 오케스트레이션 - AWS Summit Seoul 2017Amazon Web Services Korea
 
Building infrastructure with Azure Resource Manager using PowerShell
Building infrastructure with Azure Resource Manager using PowerShell Building infrastructure with Azure Resource Manager using PowerShell
Building infrastructure with Azure Resource Manager using PowerShell K.Mohamed Faizal
 

What's hot (20)

What's New for the Windows Azure Developer? Lots!!
What's New for the Windows Azure Developer?  Lots!!What's New for the Windows Azure Developer?  Lots!!
What's New for the Windows Azure Developer? Lots!!
 
Using Windows Azure for Solving Identity Management Challenges
Using Windows Azure for Solving Identity Management ChallengesUsing Windows Azure for Solving Identity Management Challenges
Using Windows Azure for Solving Identity Management Challenges
 
Windows Azure for Developers - Service Management
Windows Azure for Developers - Service ManagementWindows Azure for Developers - Service Management
Windows Azure for Developers - Service Management
 
Using Windows Azure for Solving Identity Management Challenges (Visual Studio...
Using Windows Azure for Solving Identity Management Challenges (Visual Studio...Using Windows Azure for Solving Identity Management Challenges (Visual Studio...
Using Windows Azure for Solving Identity Management Challenges (Visual Studio...
 
Windows Azure: Lessons From the Field
Windows Azure: Lessons From the FieldWindows Azure: Lessons From the Field
Windows Azure: Lessons From the Field
 
Windows Azure for Developers - Building Block Services
Windows Azure for Developers - Building Block ServicesWindows Azure for Developers - Building Block Services
Windows Azure for Developers - Building Block Services
 
10 Ways to Gaurantee Your Azure Project will Fail
10 Ways to Gaurantee Your Azure Project will Fail10 Ways to Gaurantee Your Azure Project will Fail
10 Ways to Gaurantee Your Azure Project will Fail
 
Inside Azure Resource Manager
Inside Azure Resource ManagerInside Azure Resource Manager
Inside Azure Resource Manager
 
infrastructure as code
infrastructure as codeinfrastructure as code
infrastructure as code
 
Infrastructure as Code for Beginners
Infrastructure as Code for BeginnersInfrastructure as Code for Beginners
Infrastructure as Code for Beginners
 
ECS & ECR Deep Dive - 김기완 솔루션즈 아키텍트 :: AWS Container Day
ECS & ECR Deep Dive - 김기완 솔루션즈 아키텍트 :: AWS Container DayECS & ECR Deep Dive - 김기완 솔루션즈 아키텍트 :: AWS Container Day
ECS & ECR Deep Dive - 김기완 솔루션즈 아키텍트 :: AWS Container Day
 
AWS Infrastructure as Code - September 2016 Webinar Series
AWS Infrastructure as Code - September 2016 Webinar SeriesAWS Infrastructure as Code - September 2016 Webinar Series
AWS Infrastructure as Code - September 2016 Webinar Series
 
Microsoft Windows Server AppFabric
Microsoft Windows Server AppFabricMicrosoft Windows Server AppFabric
Microsoft Windows Server AppFabric
 
Windows Phone 7 and Windows Azure – A Match Made in the Cloud
Windows Phone 7 and Windows Azure – A Match Made in the CloudWindows Phone 7 and Windows Azure – A Match Made in the Cloud
Windows Phone 7 and Windows Azure – A Match Made in the Cloud
 
Deep Dive - Infrastructure as Code
Deep Dive - Infrastructure as CodeDeep Dive - Infrastructure as Code
Deep Dive - Infrastructure as Code
 
AWS January 2016 Webinar Series - Managing your Infrastructure as Code
AWS January 2016 Webinar Series - Managing your Infrastructure as CodeAWS January 2016 Webinar Series - Managing your Infrastructure as Code
AWS January 2016 Webinar Series - Managing your Infrastructure as Code
 
Building Highly Scalable Java Applications on Windows Azure - JavaOne S313978
Building Highly Scalable Java Applications on Windows Azure - JavaOne S313978Building Highly Scalable Java Applications on Windows Azure - JavaOne S313978
Building Highly Scalable Java Applications on Windows Azure - JavaOne S313978
 
[PL] Code Europe 2016 - Python and Microsoft Azure
[PL] Code Europe 2016 - Python and Microsoft Azure[PL] Code Europe 2016 - Python and Microsoft Azure
[PL] Code Europe 2016 - Python and Microsoft Azure
 
AWS와 Docker Swarm을 이용한 쉽고 빠른 컨테이너 오케스트레이션 - AWS Summit Seoul 2017
AWS와 Docker Swarm을 이용한 쉽고 빠른 컨테이너 오케스트레이션 - AWS Summit Seoul 2017AWS와 Docker Swarm을 이용한 쉽고 빠른 컨테이너 오케스트레이션 - AWS Summit Seoul 2017
AWS와 Docker Swarm을 이용한 쉽고 빠른 컨테이너 오케스트레이션 - AWS Summit Seoul 2017
 
Building infrastructure with Azure Resource Manager using PowerShell
Building infrastructure with Azure Resource Manager using PowerShell Building infrastructure with Azure Resource Manager using PowerShell
Building infrastructure with Azure Resource Manager using PowerShell
 

Similar to More Cache for Less Cash

Adelaide Global Azure Bootcamp 2018 - Azure 101
Adelaide Global Azure Bootcamp 2018 - Azure 101Adelaide Global Azure Bootcamp 2018 - Azure 101
Adelaide Global Azure Bootcamp 2018 - Azure 101Balabiju
 
AWS Webcast - Webinar Series for State and Local Government #2: Discover the ...
AWS Webcast - Webinar Series for State and Local Government #2: Discover the ...AWS Webcast - Webinar Series for State and Local Government #2: Discover the ...
AWS Webcast - Webinar Series for State and Local Government #2: Discover the ...Amazon Web Services
 
AWS Webcast - Website Hosting in the Cloud
AWS Webcast - Website Hosting in the CloudAWS Webcast - Website Hosting in the Cloud
AWS Webcast - Website Hosting in the CloudAmazon Web Services
 
VMworld 2013: Maximize Database Performance in Your Software-Defined Data Center
VMworld 2013: Maximize Database Performance in Your Software-Defined Data CenterVMworld 2013: Maximize Database Performance in Your Software-Defined Data Center
VMworld 2013: Maximize Database Performance in Your Software-Defined Data CenterVMworld
 
AWS Webcast - AWS Webinar Series for Education #3 - Discover the Ease of AWS ...
AWS Webcast - AWS Webinar Series for Education #3 - Discover the Ease of AWS ...AWS Webcast - AWS Webinar Series for Education #3 - Discover the Ease of AWS ...
AWS Webcast - AWS Webinar Series for Education #3 - Discover the Ease of AWS ...Amazon Web Services
 
Azure-Backup-Presentation-Chico-7-22-2019-1.pdf
Azure-Backup-Presentation-Chico-7-22-2019-1.pdfAzure-Backup-Presentation-Chico-7-22-2019-1.pdf
Azure-Backup-Presentation-Chico-7-22-2019-1.pdfbhavyanm2
 
AWS Webcast - AWS Webinar Series for Education #2 - Getting Started with AWS
AWS Webcast - AWS Webinar Series for Education #2 - Getting Started with AWSAWS Webcast - AWS Webinar Series for Education #2 - Getting Started with AWS
AWS Webcast - AWS Webinar Series for Education #2 - Getting Started with AWSAmazon Web Services
 
Road to cloud-iaas
Road to cloud-iaasRoad to cloud-iaas
Road to cloud-iaasHatem Al Sum
 
Nuts and bolts of running a popular site in the aws cloud
Nuts and bolts of running a popular site in the aws cloudNuts and bolts of running a popular site in the aws cloud
Nuts and bolts of running a popular site in the aws cloudDavid Veksler
 
Microsoft Azure Veri Servisleri
Microsoft Azure Veri ServisleriMicrosoft Azure Veri Servisleri
Microsoft Azure Veri ServisleriÖnder Değer
 
AWS Webcast - Explore the AWS Cloud
AWS Webcast - Explore the AWS CloudAWS Webcast - Explore the AWS Cloud
AWS Webcast - Explore the AWS CloudAmazon Web Services
 
Hacking apache cloud stack
Hacking apache cloud stackHacking apache cloud stack
Hacking apache cloud stackNitin Mehta
 
Better, faster, cheaper infrastructure with apache cloud stack and riak cs redux
Better, faster, cheaper infrastructure with apache cloud stack and riak cs reduxBetter, faster, cheaper infrastructure with apache cloud stack and riak cs redux
Better, faster, cheaper infrastructure with apache cloud stack and riak cs reduxJohn Burwell
 
AWS Webcast - Build Agile Applications in AWS Cloud
AWS Webcast - Build Agile Applications in AWS CloudAWS Webcast - Build Agile Applications in AWS Cloud
AWS Webcast - Build Agile Applications in AWS CloudAmazon Web Services
 
Sql Start! 2020 - SQL Server Lift & Shift su Azure
Sql Start! 2020 - SQL Server Lift & Shift su AzureSql Start! 2020 - SQL Server Lift & Shift su Azure
Sql Start! 2020 - SQL Server Lift & Shift su AzureMarco Obinu
 
Azure Databricks – Customer Experiences and Lessons Denzil Ribeiro Madhu Ganta
Azure Databricks – Customer Experiences and Lessons Denzil Ribeiro Madhu GantaAzure Databricks – Customer Experiences and Lessons Denzil Ribeiro Madhu Ganta
Azure Databricks – Customer Experiences and Lessons Denzil Ribeiro Madhu GantaDatabricks
 
Cloud and Windows Azure
Cloud and Windows AzureCloud and Windows Azure
Cloud and Windows AzureRadu Vunvulea
 

Similar to More Cache for Less Cash (20)

IaaS azure_vs_amazon
IaaS azure_vs_amazonIaaS azure_vs_amazon
IaaS azure_vs_amazon
 
Adelaide Global Azure Bootcamp 2018 - Azure 101
Adelaide Global Azure Bootcamp 2018 - Azure 101Adelaide Global Azure Bootcamp 2018 - Azure 101
Adelaide Global Azure Bootcamp 2018 - Azure 101
 
AWS Webcast - Webinar Series for State and Local Government #2: Discover the ...
AWS Webcast - Webinar Series for State and Local Government #2: Discover the ...AWS Webcast - Webinar Series for State and Local Government #2: Discover the ...
AWS Webcast - Webinar Series for State and Local Government #2: Discover the ...
 
AWS Webcast - Website Hosting in the Cloud
AWS Webcast - Website Hosting in the CloudAWS Webcast - Website Hosting in the Cloud
AWS Webcast - Website Hosting in the Cloud
 
VMworld 2013: Maximize Database Performance in Your Software-Defined Data Center
VMworld 2013: Maximize Database Performance in Your Software-Defined Data CenterVMworld 2013: Maximize Database Performance in Your Software-Defined Data Center
VMworld 2013: Maximize Database Performance in Your Software-Defined Data Center
 
AWS Webcast - AWS Webinar Series for Education #3 - Discover the Ease of AWS ...
AWS Webcast - AWS Webinar Series for Education #3 - Discover the Ease of AWS ...AWS Webcast - AWS Webinar Series for Education #3 - Discover the Ease of AWS ...
AWS Webcast - AWS Webinar Series for Education #3 - Discover the Ease of AWS ...
 
AWS Webcast - Website Hosting
AWS Webcast - Website HostingAWS Webcast - Website Hosting
AWS Webcast - Website Hosting
 
Azure-Backup-Presentation-Chico-7-22-2019-1.pdf
Azure-Backup-Presentation-Chico-7-22-2019-1.pdfAzure-Backup-Presentation-Chico-7-22-2019-1.pdf
Azure-Backup-Presentation-Chico-7-22-2019-1.pdf
 
AWS Webcast - AWS Webinar Series for Education #2 - Getting Started with AWS
AWS Webcast - AWS Webinar Series for Education #2 - Getting Started with AWSAWS Webcast - AWS Webinar Series for Education #2 - Getting Started with AWS
AWS Webcast - AWS Webinar Series for Education #2 - Getting Started with AWS
 
Road to cloud-iaas
Road to cloud-iaasRoad to cloud-iaas
Road to cloud-iaas
 
Nuts and bolts of running a popular site in the aws cloud
Nuts and bolts of running a popular site in the aws cloudNuts and bolts of running a popular site in the aws cloud
Nuts and bolts of running a popular site in the aws cloud
 
Microsoft Azure Veri Servisleri
Microsoft Azure Veri ServisleriMicrosoft Azure Veri Servisleri
Microsoft Azure Veri Servisleri
 
AWS Webcast - Explore the AWS Cloud
AWS Webcast - Explore the AWS CloudAWS Webcast - Explore the AWS Cloud
AWS Webcast - Explore the AWS Cloud
 
Hacking apache cloud stack
Hacking apache cloud stackHacking apache cloud stack
Hacking apache cloud stack
 
Better, faster, cheaper infrastructure with apache cloud stack and riak cs redux
Better, faster, cheaper infrastructure with apache cloud stack and riak cs reduxBetter, faster, cheaper infrastructure with apache cloud stack and riak cs redux
Better, faster, cheaper infrastructure with apache cloud stack and riak cs redux
 
AWS Webcast - Build Agile Applications in AWS Cloud
AWS Webcast - Build Agile Applications in AWS CloudAWS Webcast - Build Agile Applications in AWS Cloud
AWS Webcast - Build Agile Applications in AWS Cloud
 
Sql Start! 2020 - SQL Server Lift & Shift su Azure
Sql Start! 2020 - SQL Server Lift & Shift su AzureSql Start! 2020 - SQL Server Lift & Shift su Azure
Sql Start! 2020 - SQL Server Lift & Shift su Azure
 
Azure Databricks – Customer Experiences and Lessons Denzil Ribeiro Madhu Ganta
Azure Databricks – Customer Experiences and Lessons Denzil Ribeiro Madhu GantaAzure Databricks – Customer Experiences and Lessons Denzil Ribeiro Madhu Ganta
Azure Databricks – Customer Experiences and Lessons Denzil Ribeiro Madhu Ganta
 
Cloud and Windows Azure
Cloud and Windows AzureCloud and Windows Azure
Cloud and Windows Azure
 
Cloud stack for_beginners
Cloud stack for_beginnersCloud stack for_beginners
Cloud stack for_beginners
 

Recently uploaded

Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Scriptwesley chun
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024The Digital Insurer
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking MenDelhi Call girls
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024The Digital Insurer
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...apidays
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking MenDelhi Call girls
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountPuma Security, LLC
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationSafe Software
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfEnterprise Knowledge
 
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Igalia
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Servicegiselly40
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Enterprise Knowledge
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Miguel Araújo
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking MenDelhi Call girls
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024The Digital Insurer
 
A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024Results
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...Neo4j
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonetsnaman860154
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityPrincipled Technologies
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024The Digital Insurer
 

Recently uploaded (20)

Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path Mount
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
 
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Service
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024
 

More Cache for Less Cash

  • 1. More Cache for Less Cash Michael S. Collier @MichaelCollier CodeMash – January 10, 2014
  • 2. Michael S. Collier • Principal Cloud Architect, Aditi • michaelc@aditi.com • @MichaelCollier • www.MichaelSCollier.com
  • 3. Today’s Agenda • • • • • • 6 Why Cache? Cache Options in Windows Azure What’s New in the Windows Azure Cache Service Demos Monitoring and Scaling Pricing and Features
  • 6. What is Windows Azure Cache? A distributed, in-memory, flexible cache for all data types that can be used to speed up Windows Azure applications and reduce database load. Basically, cache helps your app become faster. 10 Windows Azure Cache
  • 7. A Cache Story Shared Cache In-Role Cache • Cloud Services • Cloud Services • Shared – quotas • Co-located (free) • Lacked feature parity • Dedicated ($$) • Multiple size options • Feature parity • Expensive • Performance challenged • Throttling • Good performance • Deprecated August 2014 11 • Not multi-tenant Cache Service • Cloud Services, Web Sites, or VMs • Feature parity • Managed infrastructure • Price/capacity tiers • Good performance (1ms read)
  • 8. A Cache Story Shared Cache In-Role Cache • Cloud Services • Cloud Services • Shared – quotas • Co-located (free) • Lacked feature parity • Dedicated ($$) • Multiple size options • Feature parity • Expensive • Performance challenged • Throttling • Good performance • Deprecated August 2014 12 • Not multi-tenant Cache Service • Cloud Services, Web Sites, or VMs • Feature parity • Managed infrastructure • Price/capacity tiers • Good performance (1ms read)
  • 9. A Cache Story Shared Cache In-Role Cache • Cloud Services • Cloud Services • Shared – quotas • Co-located (free) • Lacked feature parity • Dedicated ($$) • Multiple size options • Feature parity • Expensive • Performance challenged • Throttling • Good performance • Deprecated August 2014 http://aka.ms/MigrateFromSharedCaching 13 • Not multi-tenant Cache Service • Cloud Services, Web Sites, or VMs • Feature parity • Managed infrastructure • Price/capacity tiers • Good performance (1ms read)
  • 10. In-Role Cache (Co-located) Source: Windows Azure Training Kit 14
  • 11. In-Role Cache (Dedicated) Source: Windows Azure Training Kit 15
  • 12. In-Role Cache (Dedicated) Source: Windows Azure Training Kit 16
  • 13. In-Role Cache • • • • • Released w/ Oct. 2012 release of Azure SDK 1.8 Cache part of your Cloud Service application No quotas or throttling Isolation, flexibility, and control High performance • Features: named cache, regions, tagging, HA, local, notifications • Pro: You manage as part of your application • Con: You manage it; only available to Cloud Service roles in same deployment 17
  • 14. Create and Configure In-Role Cache Configure a Role in the Cloud Service to host the cache 18
  • 15. Configure the Cache Clients • Use NuGet to configure the cache clients • Microsoft.WindowsAzure.Caching • Settings placed in web.config or app.config • Modify to point to the cache server role <dataCacheClients> <dataCacheClient name="default"> <!--To use the in-role flavor of Windows Azure Cache, set identifier to be the cache cluster role name --> <!--To use the Windows Azure Cache Service, set identifier to be the endpoint of the cache cluster --> <autoDiscover isEnabled="true" identifier="MyScores.Web" /> <!--<localCache isEnabled="true" sync="TimeoutBased" objectCount="100000" ttlValue="300" />--> </dataCacheClient> </dataCacheClients> Role Name 19
  • 17. Monitoring the Cache Diagnostic Data Collected Level 0 Critical/catastrophic server logs only 1 Data to help in assessing usage patterns, cache health, and potential errors. Default. 2 3 4 Fine grain data for all requests and important system information Diagnostic data with more verboseness and system information Highest verbosity logs for all requests and system information Provides a single setting for cache servers and clients Configures levels for logs, traces, performance counters & crash dumps Full details at http://aka.ms/CacheDiagnostics 21
  • 18. Monitoring the Cache • Set cache diagnostic level in configuration or portal • Level (1-4) controls verbosity, perf counters, & crash dumps. • Start at 1 and increase as needed <Role name="WorkerRole1"> <Instances count="1" /> <ConfigurationSettings> <!– Cache Server --> <Setting name="Microsoft.WindowsAzure.Plugins.Caching.DiagnosticLevel“ value="1" /> <!– Cache Client--> <Setting name="Microsoft.WindowsAzure.Plugins.Caching.ClientDiagnosticLevel" value="1" /> </ConfigurationSettings> </Role> Full details at http://mcollier.net/AzureCacheDiag 22
  • 19. Monitoring the Cache public class WebRole : RoleEntryPoint { public override bool OnStart() { // Enable cache diagnostics DiagnosticMonitorConfiguration dmConfig = DiagnosticMonitor.GetDefaultInitialConfiguration(); // Configure collection of cache diagnostic data. CacheDiagnostics.ConfigureDiagnostics(dmConfig); DiagnosticMonitor.Start("Microsoft.WindowsAzure.Plugins.Diagnostics.ConnectionString", dmConfig); return base.OnStart(); } } 23
  • 20. Considerations • Unable to create DataCache in RoleEntryPoint • Max object size is 8MB post serialized • Default serializer is NetDataContractSerializer • Cost only for role instances • Only accessible from within same Cloud Service • Deployment will impact the cache (instances recycle) 24
  • 21. What’s New in Windows Azure Cache? App1 VM VM App2 VM Shared Azure Website Stamp IaaS VMs Cloud Services Windows Azure Cache 25 1. SLA backed 2. Microsoft Managed 3. Scalable & Resilient
  • 22. Create and Configure the Cache Service • Create via management portal • Choose an offering • Basic (128MB to 1GB in 128MB units, 1 named cache) • Standard (1GB to 10GB in 1GB units, notifications, and 10 named caches) • Premium (5GB to 150GB in 5GB units, notifications, HA, and 10 named caches) • Locate in same region as client for best perf and cost 26
  • 25. Scaling the Cache Dynamically scale without loosing any existing data 29
  • 26. High Availability Client Read / Write Primary Premium only Doubles required memory Write Secondary Increased latency & decreased throughput 30
  • 27. Where Can You Use the New Azure Cache? Cloud Service Windows Azure Web Site Windows Azure VM Windows Azure Mobile Service .NET Applications PHP (PECL) Java (spymemcached) Node.js C++ (libmemcached)                 Hopefully addressed by GA 31
  • 28. Pricing Details Basic Standard Premium $12.50/month (prorated hourly) $50/month (prorated hourly) $200/month (prorated hourly) 128 MB 1 GB 5 GB Up to 8 units Up to 10 units Up to 30 units Named Caches 1 10 10 High Availability    Notifications    Price Per Unit (Preview) Cache Size Scale Price includes a 50% preview discount. Technical support through forums only (during preview) See http://mcollier.net/AzureCachePricing 34
  • 29. Benefits of the Windows Azure Cache • Use from any app types (VM, Web Site, Mobile Service*, Cloud Service) • Each instance deployed within dedicated VMs (fast, predictable performance) • No quotas or throttling • Store up to 150GB per cache instance • Avg. retrieval time of 1ms. Insert in about 1.2ms • Highly available / distributed across multiple servers • Managed service – focus on apps not infrastructure • Same .NET cache API used with in-role cache for Cloud Services • Support for ASP.NET Session State and Page Output Caching • Unique cache service instance for each app, or share across apps 35
  • 30. Common Architecture Web Roles 2. Read 1. Read 3. Write Storage Table Windows Azure Cache 36
  • 31. Common Architecture Worker Roles Read Web Roles Read Windows Azure Load Balancer Preload the cache Carefully choose expiration and eviction settings 37 Windows Azure Cache SQL Database (Windows Azure)
  • 32. Common Architecture Windows Azure Load Balancer Web Roles Read Write Read Write Write Worker Roles Storage Queue Windows Azure Cache Storage Table 38 SQL Database (Windows Azure)
  • 33. Guidelines - Configuration • Multiple named caches for different cache settings (HA, notifications, TTL, etc.) 40
  • 34. Guidelines - Features • Local Cache • Pro: • Fastest performance • Con: • Stale data (compensate w/ notification invalidation) • Additional memory pressure 41
  • 35. Guidelines – High Availability & Regions • High Availability • Pro: More durable cached data • Con: 2x the writes (memory / performance) • Regions • Pro: Supports organization, tagging, and searching • Con: Lives on a single cache server 42
  • 36. Cloud Service Fundamentals - Caching • Factory implementation • Custom BinarySerializer class • protobuf-net • Fast and small http://mcollier.net/AzureCSF 43
  • 37. Where to Cache? Cache Service Usage Scenarios Pricing SDK/Language Support In-Role Cache Cloud Services, Mobile Services, Web Sites, and VMs Pay per Month Cloud Services Co-located – free Dedicated – pay per hour .NET SDK 1 Medium Cloud Service instance (3.5 GB RAM): $119/month 2 GB Standard cache (2, 1GB units): $100/month 3 A7 dedicated instances (56 GB RAM each): $3,147/month 150GB Premium cache (30, 5GB units): $6,000/month 44 .NET SDK
  • 38. Where to Cache? Mix cache solutions for price / manageability / features Windows Azure Load Balancer Web Roles • Data shared by other services/apps • General application data Read In-role cache • • 45 Session / Page Output Cache FREE! Windows Azure Cache
  • 39. Summary • In-Role Cache • Cloud Services only • Co-located (free) or Dedicated ($$$) • Isolated cache-related workload • Cache Service • Microsoft managed service, dedicated tenant, SLA backed • Cloud Services, Web Sites, and VMs • Full parity with in-role cache (SDK) • Shared Caching Service to be deprecated 46
  • 40. More Resources • Scott Guthrie’s blog • • Windows Azure Cache Service (Preview) • • http://blogs.msdn.com/b/windowsazure/archive/2013/10/03/cloud-service-fundamentals-cachingbasics.aspx Capacity Planning Spreadsheet • 47 http://code.msdn.microsoft.com/Windows-Azure-Caching-NFL-e2a534a5 Cloud Service Fundamentals – Caching Basics • • http://msdn.microsoft.com/library/hh916611.aspx Windows Azure Cache Sample • • http://msdn.microsoft.com/en-us/library/windowsazure/dn386094.aspx Optimization Guidance for Windows Azure Caching • • http://weblogs.asp.net/scottgu/archive/2013/09/03/windows-azure-new-distributed-dedicated-highperformance-cache-service-more-cool-improvements.aspx http://msdn.microsoft.com/en-us/library/hh914129
  • 42. Thank You! • Michael S. Collier • Principal Cloud Architect, Aditi • michaelc@aditi.com • @MichaelCollier • www.MichaelSCollier.com

Editor's Notes

  1. Principal Cloud ArchitectWindows Azure MVPHelp customers nationwide with their Windows Azure projects. This can include architectural design sessions, training, development, evangelism, etc.Reach me via email, Twitter, or my blog.
  2. SQL DB can often be a limiting factor in WA applications.Can get slow and throttle as pressure increases
  3. Similar feature parity with Windows Server AppFabric Cache (on-premises)
  4. Similar feature parity with Windows Server AppFabric Cache (on-premises)
  5. Similar feature parity with Windows Server AppFabric Cache (on-premises)
  6. A region is a subgroup for cached items. Regions also support the annotation of cached items with additional descriptive strings called tags. Regions support the ability to perform search operations on any tagged items in that region.
  7. Add In-Role Cache to an existing Cloud ServiceShow adding package via NuGetShow pre-deployed version in management portal. Show metrics.Install-package Microsoft.WindowsAzure.Caching
  8. http://msdn.microsoft.com/en-us/library/windowsazure/hh914135.aspx
  9. Server – added by Visual StudioClient – added by NuGet packagehttp://msdn.microsoft.com/en-us/library/windowsazure/jj136940.aspxhttp://msdn.microsoft.com/en-us/library/windowsazure/hh914135.aspx
  10. Unable to create DataCache in RoleEntryPoint“Server collection cannot be empty”WA Cache settings not automatically available in the web.cong in context of RoleEntryPointProgrammatic onlyhttp://msdn.microsoft.com/en-us/library/windowsazure/jj852128.aspx
  11. Scale Units for Cloud Services
  12. Create a new cache in the cloudDevelop simple web app in VS and run against IIS expressDeploy to azure web site and run in cloud
  13. Scale cache units w/o losing data. Changing offerings will cause cache data loss.
  14. Show adding session management to cacheShow using the same cache across Web Site, Cloud Service, and VMEnable HAEnable detailed metrics
  15. Ability to use the Cache Service from any app type (VM, Web Site, Mobile Service, Cloud Service)Each Cache Service instance is deployed within dedicated VMs that are separated/isolated from other customers – which means you get fast, predictable performance. There are no quotas or throttling behaviors with the Cache Service – you can access your dedicated Cache Service instances as much or as hard as you want. Each Cache Service instance you create can store (as of today’s preview) up to 150GB of in-memory data objects or content. You can dynamically increase or shrink the memory used by a Cache Service instance without having to redeploy your apps. Web Sites, VMs and Cloud Service can retrieve objects from the Cache Service on average in about 1ms end-to-end (including the network round-trip to the cache service and back). Items can be inserted into the cache in about ~1.2ms end-to-end (meaning the Web Site/VM/Cloud Service can persist the object in the remote Cache Service and gets the ACK back in 1.2ms end-to-end). Each Cache Service instance is run as a highly available service that is distributed across multiple servers. This means that your Cache Service will remain up and available even if a server on which it is running crashes or if one of the VM instances needs to be upgraded for patching.The VMs that the cache service instances run within are managed as a service by Windows Azure – which means we handle patching and service lifetime of the instances. This allows you to focus on building great apps without having to worry about managing infrastructure details.The new Cache Service supports the same .NET Cache API that we use today with the in-role cache option that we support with Cloud Services. So code you’ve already written against that is compatible with the new managed Cache Service.The new Cache Service comes with built-in provider support for ASP.NET Session State and ASP.NET Output Page Caching. This enables you to easily scale-out your ASP.NET applications across multiple web servers and still share session state and/or cached page output regardless of which customer hit which server. The new Cache Service supports the ability to either use a separate Cache Service instance for each of your apps, or instead share a single Cache Service instance across multiple apps at once (which enables easy data sharing as well as app partitioning). This can be very useful for scenarios where you want to partition your app up across several deployment units.
  16. Basic – cache-aside pattern
  17. Pre-load the cache
  18. Architecture diagram – read from cache; other process updates cache dataReference - http://blog.cynapta.com/2013/11/building-cynapta-services-part-ii-architecture-drilldown/
  19. http://blogs.msdn.com/b/windowsazure/archive/2013/10/03/cloud-service-fundamentals-caching-basics.aspx
  20. Cache (Preview) Features - http://msdn.microsoft.com/en-us/library/windowsazure/dn386143.aspx
  21. Principal Cloud ArchitectWindows Azure MVPHelp customers nationwide with their Windows Azure projects. This can include architectural design sessions, training, development, evangelism, etc.Reach me via email, Twitter, or my blog.
  22. http://msdn.microsoft.com/en-us/library/windowsazure/hh697523.aspx