austin code camp 2010 asp.net apps with azure table storage presented by chander shekhar dhall...
TRANSCRIPT
![Page 1: Austin code camp 2010 asp.net apps with azure table storage PRESENTED BY CHANDER SHEKHAR DHALL csdhall@ChanderDhall.com](https://reader036.vdocuments.mx/reader036/viewer/2022062516/56649e655503460f94b6017f/html5/thumbnails/1.jpg)
Austin code camp 2010
asp.net apps with
azure table storage
PRESENTED BYCHANDER SHEKHAR DHALL
csdhall@ChanderDhall.comwww.welcometoyoga.comwww.ChanderDhall.com
Twitter @csdhall
![Page 3: Austin code camp 2010 asp.net apps with azure table storage PRESENTED BY CHANDER SHEKHAR DHALL csdhall@ChanderDhall.com](https://reader036.vdocuments.mx/reader036/viewer/2022062516/56649e655503460f94b6017f/html5/thumbnails/3.jpg)
wARNING
• THIS PRESENTATION IS ON A MAC
![Page 4: Austin code camp 2010 asp.net apps with azure table storage PRESENTED BY CHANDER SHEKHAR DHALL csdhall@ChanderDhall.com](https://reader036.vdocuments.mx/reader036/viewer/2022062516/56649e655503460f94b6017f/html5/thumbnails/4.jpg)
• Worked on Azure?
Counts
![Page 5: Austin code camp 2010 asp.net apps with azure table storage PRESENTED BY CHANDER SHEKHAR DHALL csdhall@ChanderDhall.com](https://reader036.vdocuments.mx/reader036/viewer/2022062516/56649e655503460f94b6017f/html5/thumbnails/5.jpg)
• Specifically Azure Table Storage?
Counts
![Page 6: Austin code camp 2010 asp.net apps with azure table storage PRESENTED BY CHANDER SHEKHAR DHALL csdhall@ChanderDhall.com](https://reader036.vdocuments.mx/reader036/viewer/2022062516/56649e655503460f94b6017f/html5/thumbnails/6.jpg)
• Planning to use Azure?
Counts
![Page 7: Austin code camp 2010 asp.net apps with azure table storage PRESENTED BY CHANDER SHEKHAR DHALL csdhall@ChanderDhall.com](https://reader036.vdocuments.mx/reader036/viewer/2022062516/56649e655503460f94b6017f/html5/thumbnails/7.jpg)
• Working for Start-Up?
Counts
![Page 8: Austin code camp 2010 asp.net apps with azure table storage PRESENTED BY CHANDER SHEKHAR DHALL csdhall@ChanderDhall.com](https://reader036.vdocuments.mx/reader036/viewer/2022062516/56649e655503460f94b6017f/html5/thumbnails/8.jpg)
• Attended PDC?
Counts
![Page 9: Austin code camp 2010 asp.net apps with azure table storage PRESENTED BY CHANDER SHEKHAR DHALL csdhall@ChanderDhall.com](https://reader036.vdocuments.mx/reader036/viewer/2022062516/56649e655503460f94b6017f/html5/thumbnails/9.jpg)
• Attending Tech-ED?
Counts
![Page 10: Austin code camp 2010 asp.net apps with azure table storage PRESENTED BY CHANDER SHEKHAR DHALL csdhall@ChanderDhall.com](https://reader036.vdocuments.mx/reader036/viewer/2022062516/56649e655503460f94b6017f/html5/thumbnails/10.jpg)
• Anyone Recording?
Counts
![Page 11: Austin code camp 2010 asp.net apps with azure table storage PRESENTED BY CHANDER SHEKHAR DHALL csdhall@ChanderDhall.com](https://reader036.vdocuments.mx/reader036/viewer/2022062516/56649e655503460f94b6017f/html5/thumbnails/11.jpg)
Why Azure?
![Page 12: Austin code camp 2010 asp.net apps with azure table storage PRESENTED BY CHANDER SHEKHAR DHALL csdhall@ChanderDhall.com](https://reader036.vdocuments.mx/reader036/viewer/2022062516/56649e655503460f94b6017f/html5/thumbnails/12.jpg)
azure
• Windows Azure is the foundation of Microsoft’s Cloud Platform
• It is an “Operating System in the Cloud” and provides Essential Services for the cloud Virtualized Computation Scalable Storage Automatic Management Developer SDK
![Page 13: Austin code camp 2010 asp.net apps with azure table storage PRESENTED BY CHANDER SHEKHAR DHALL csdhall@ChanderDhall.com](https://reader036.vdocuments.mx/reader036/viewer/2022062516/56649e655503460f94b6017f/html5/thumbnails/13.jpg)
azure
![Page 14: Austin code camp 2010 asp.net apps with azure table storage PRESENTED BY CHANDER SHEKHAR DHALL csdhall@ChanderDhall.com](https://reader036.vdocuments.mx/reader036/viewer/2022062516/56649e655503460f94b6017f/html5/thumbnails/14.jpg)
azure
![Page 15: Austin code camp 2010 asp.net apps with azure table storage PRESENTED BY CHANDER SHEKHAR DHALL csdhall@ChanderDhall.com](https://reader036.vdocuments.mx/reader036/viewer/2022062516/56649e655503460f94b6017f/html5/thumbnails/15.jpg)
Azure Roles
• An Azure application is implemented with a Web and/or a Worker role. Developer defines what the role does. Azure takes care of the rest. Each VM assigner to a role.
![Page 16: Austin code camp 2010 asp.net apps with azure table storage PRESENTED BY CHANDER SHEKHAR DHALL csdhall@ChanderDhall.com](https://reader036.vdocuments.mx/reader036/viewer/2022062516/56649e655503460f94b6017f/html5/thumbnails/16.jpg)
Azure Roles
![Page 17: Austin code camp 2010 asp.net apps with azure table storage PRESENTED BY CHANDER SHEKHAR DHALL csdhall@ChanderDhall.com](https://reader036.vdocuments.mx/reader036/viewer/2022062516/56649e655503460f94b6017f/html5/thumbnails/17.jpg)
Stateless
• Azure Web Roles must be designer to be stateless Request from the same user may reach different
web role instances. Store state in Azure storage or client side.
![Page 18: Austin code camp 2010 asp.net apps with azure table storage PRESENTED BY CHANDER SHEKHAR DHALL csdhall@ChanderDhall.com](https://reader036.vdocuments.mx/reader036/viewer/2022062516/56649e655503460f94b6017f/html5/thumbnails/18.jpg)
Stateless
![Page 19: Austin code camp 2010 asp.net apps with azure table storage PRESENTED BY CHANDER SHEKHAR DHALL csdhall@ChanderDhall.com](https://reader036.vdocuments.mx/reader036/viewer/2022062516/56649e655503460f94b6017f/html5/thumbnails/19.jpg)
Windows Azure data storage
• Azure allow data to be stored in: Blobs (large items of user data) Tables(simple tables, caches) Queues(service communicationz)
• Massive scale, availability and durability.
• Everything is accessible via RESTful services.
![Page 20: Austin code camp 2010 asp.net apps with azure table storage PRESENTED BY CHANDER SHEKHAR DHALL csdhall@ChanderDhall.com](https://reader036.vdocuments.mx/reader036/viewer/2022062516/56649e655503460f94b6017f/html5/thumbnails/20.jpg)
Fundamental data abstractions• Blobs – Provide a simple interface for storing
named files along with metadata for the file
• Tables – Provide structured storage; A Table is a set of entities, which contain a set of properties
• Queues – Provide reliable storage and delivery of messages for an application
![Page 21: Austin code camp 2010 asp.net apps with azure table storage PRESENTED BY CHANDER SHEKHAR DHALL csdhall@ChanderDhall.com](https://reader036.vdocuments.mx/reader036/viewer/2022062516/56649e655503460f94b6017f/html5/thumbnails/21.jpg)
Windows Azure data storage
![Page 22: Austin code camp 2010 asp.net apps with azure table storage PRESENTED BY CHANDER SHEKHAR DHALL csdhall@ChanderDhall.com](https://reader036.vdocuments.mx/reader036/viewer/2022062516/56649e655503460f94b6017f/html5/thumbnails/22.jpg)
Windows azure tables
• Provides Structured Storage Massively Scalable Tables
• Billions of entities (rows) and TBs of data• Can use thousands of servers as traffic grows
Highly Available• Can always access your data
Durable• Data is replicated several times
• Familiar and Easy to use API ADO.NET Data Services – .NET 3.5 SP1
• .NET classes and LINQ• REST – with any platform or language
![Page 23: Austin code camp 2010 asp.net apps with azure table storage PRESENTED BY CHANDER SHEKHAR DHALL csdhall@ChanderDhall.com](https://reader036.vdocuments.mx/reader036/viewer/2022062516/56649e655503460f94b6017f/html5/thumbnails/23.jpg)
Agenda
• Data model
• Demo – creating Tables
• Demo – creating Blobs
• Demo – creating Queues
• Basic CRUD using .NET and REST
• Best Practices
• Demo – A better Approach
![Page 24: Austin code camp 2010 asp.net apps with azure table storage PRESENTED BY CHANDER SHEKHAR DHALL csdhall@ChanderDhall.com](https://reader036.vdocuments.mx/reader036/viewer/2022062516/56649e655503460f94b6017f/html5/thumbnails/24.jpg)
Data model
• TableA Storage Account can create many tablesTable name is scoped by Account
• Data is stored in TablesA Table is a set of Entities (rows)An Entity is a set of Properties (columns)
• EntityTwo “key” properties that together
are the unique ID of the entity• PartitionKey – enables scalability• RowKey – uniquely identifies
the entity within the partition
![Page 25: Austin code camp 2010 asp.net apps with azure table storage PRESENTED BY CHANDER SHEKHAR DHALL csdhall@ChanderDhall.com](https://reader036.vdocuments.mx/reader036/viewer/2022062516/56649e655503460f94b6017f/html5/thumbnails/25.jpg)
partition
Table Partition – all entities in table with same partition key value
Application controls granularity of partition
![Page 26: Austin code camp 2010 asp.net apps with azure table storage PRESENTED BY CHANDER SHEKHAR DHALL csdhall@ChanderDhall.com](https://reader036.vdocuments.mx/reader036/viewer/2022062516/56649e655503460f94b6017f/html5/thumbnails/26.jpg)
partition
Table Partition – all entities in table with same partition key value
Application controls granularity of partition
Partition KeyItem
Row KeyModelNo
Property 3Sold
Property 4
Laptop M1.0.0.0 10/1/2010
Laptop M1.0.0.1 23/1/2010
PC V1.0 5/2/2007
PC V1.0.1 7/6/2007
PC V1.0.2 8/1/2007
![Page 27: Austin code camp 2010 asp.net apps with azure table storage PRESENTED BY CHANDER SHEKHAR DHALL csdhall@ChanderDhall.com](https://reader036.vdocuments.mx/reader036/viewer/2022062516/56649e655503460f94b6017f/html5/thumbnails/27.jpg)
Partiton guidelines
• Performance Use a PartitionKey that is
common in your queries• Entities with same partition key value are
clustered
• Scalability We monitor partition traffic Automatically load balance partitions
• Each partition can potentially be served by a different storage node
• Scale to meet the traffic needs of your application More partitions – makes it easier
to balance load
![Page 28: Austin code camp 2010 asp.net apps with azure table storage PRESENTED BY CHANDER SHEKHAR DHALL csdhall@ChanderDhall.com](https://reader036.vdocuments.mx/reader036/viewer/2022062516/56649e655503460f94b6017f/html5/thumbnails/28.jpg)
DEMO
TALK IS CHEAP. SHOW ME THE CODE
- LINUS TORVALDS
![Page 29: Austin code camp 2010 asp.net apps with azure table storage PRESENTED BY CHANDER SHEKHAR DHALL csdhall@ChanderDhall.com](https://reader036.vdocuments.mx/reader036/viewer/2022062516/56649e655503460f94b6017f/html5/thumbnails/29.jpg)
entities and properties
• Each Entity can have up to 255 properties
• Every Entity has fixed key properties Partition key Row key
• No fixed schema for rest of properties 2 entities in the same table
can have different properties Properties stored as <Name, TypedValue> pairs
• Each entity has a system maintained version
![Page 30: Austin code camp 2010 asp.net apps with azure table storage PRESENTED BY CHANDER SHEKHAR DHALL csdhall@ChanderDhall.com](https://reader036.vdocuments.mx/reader036/viewer/2022062516/56649e655503460f94b6017f/html5/thumbnails/30.jpg)
Automated service management• Our responsibilities
Develop and model the service. Deploy the service to the cloud. Configure the settings and constraints.
• Azure’s responsibilities Run the service. Maintain the service’s health. Configure the settings and constraints.
![Page 31: Austin code camp 2010 asp.net apps with azure table storage PRESENTED BY CHANDER SHEKHAR DHALL csdhall@ChanderDhall.com](https://reader036.vdocuments.mx/reader036/viewer/2022062516/56649e655503460f94b6017f/html5/thumbnails/31.jpg)
Azure services
![Page 32: Austin code camp 2010 asp.net apps with azure table storage PRESENTED BY CHANDER SHEKHAR DHALL csdhall@ChanderDhall.com](https://reader036.vdocuments.mx/reader036/viewer/2022062516/56649e655503460f94b6017f/html5/thumbnails/32.jpg)
Azure services
![Page 33: Austin code camp 2010 asp.net apps with azure table storage PRESENTED BY CHANDER SHEKHAR DHALL csdhall@ChanderDhall.com](https://reader036.vdocuments.mx/reader036/viewer/2022062516/56649e655503460f94b6017f/html5/thumbnails/33.jpg)
Property types
• Partition key and Row key String (up to 64KB)
• Other properties String (up to 64KB) Binary (up to 64KB) Bool DateTime GUID Int Int64 Double
![Page 34: Austin code camp 2010 asp.net apps with azure table storage PRESENTED BY CHANDER SHEKHAR DHALL csdhall@ChanderDhall.com](https://reader036.vdocuments.mx/reader036/viewer/2022062516/56649e655503460f94b6017f/html5/thumbnails/34.jpg)
References (bing it out)
• Azure Team Blog.
• Channel 9 webcast/RSS.
• For beginners – Azure platform toolkits
• White papers on Azure Storage.
• Twitter @csdhall
![Page 35: Austin code camp 2010 asp.net apps with azure table storage PRESENTED BY CHANDER SHEKHAR DHALL csdhall@ChanderDhall.com](https://reader036.vdocuments.mx/reader036/viewer/2022062516/56649e655503460f94b6017f/html5/thumbnails/35.jpg)
Questions