The Windows Azure Platform (MSDN Events Series)


Published on

This presentation was delivered as part of the MSDN Events series of technical seminars and provides a deep dive into cloud computing and the Windows Azure Platform. It starts with a developer-focused overview of the Windows Azure Platform and the cloud computing services that can be used either together or independently to build highly scalable applications. From there, the discussion explores data storage, SQL Azure, and the basics of deployment with Windows Azure.

Published in: Technology
  • Be the first to comment

No Downloads
Total views
On SlideShare
From Embeds
Number of Embeds
Embeds 0
No embeds

No notes for slide
  • Welcome everyone my name is Dave Bost and I’m here today to introduce you to one of the most important new developer technologies starting off our new decade… Microsoft Windows Azure
  • Our agenda for this session will be to show you Windows Azure in action using Visual Studio.Next, we’ll explore the Windows Azure Services PlatformWe’ll become familiar with the core services of Windows AzureWe’ll learn about Windows Azure RolesAnd we’ll use Visual Studio to develop our first Azure application
  • This is the first session of a three part series. My objective is to have you leave the third session ready to develop Windows Azure applicationsThis session will give you the basics of what you need to know, and the next two will build up your knowledge of application development targeting the Windows Azure Platform.In this session, you will gain an understanding of the Windows Azure platform components… including Windows Azure, Windows Azure Data Services, and SQL Azure… and you’ll learn what tools and software libraries you’ll need to start constructing applications for the cloud.
  • Cloud computing is a confusing term to many people, and even many of us in the industry wonder if it is real. So what is it?Cloud computing is a new consumption based style of computing, where you pay according to the quantity of resources that you consume.What services does cloud computing provide? Hosting applications, database storage, and non-database storage are the services used the most. Depending on which platform you look at, you may also have communication, security, and content services available to you.A related term you’ll hear a lot is “Software as a Service”, or SaaS. This simply means applications can be offered as a service, where consumers pay based on usage rather than buying a license. Microsoft’s CRM Online is an example of a SaaS application: you pay each month based on the number of users.You might be wondering how cloud computing differs from traditional hosting. Hosting is one of the primary uses of cloud computing, but is not the only service available. In traditional hosting, you have a contract reserving a certain number of machines for a certain amount of time. In cloud computing, you are free to change the number of virtual machines reserved for you whenever you wish—we call that On-Demand Scale. In a month-to-month arrangement you’re also free to walk away without residual financial or contractual obligations. Cloud computing also gives you reliability and high availability. Cloud data centers have smart infrastructures that monitor your applications and safeguard your data. Redundancy is a key part of this: redundant VMs to run applications and redundant copies of the data you store.A big part of the appeal of cloud computing is that it is a self-service platform. You can make things happen all on your own, which is tremendously empowering.Cloud computing is real, and it’s here to stay. I’ll give you some concrete examples in my next slide.Cloud computing is not going to replace enterprise I.T.—it is additive to the enterprise, not a substitute for it. Bringing cloud computing alongside enterprise I.T. gives us new options without giving up anything.
  • Headless multiple worker roles Create, test, debug, and distribute web services quickly and inexpensivelyWeb role + worker role Add web services capabilities to existing packaged applicationsScalable web app or service Reduce the effort and cost of IT management Use Microsoft web technologies such as, IIS, and Visual Studio 2008On Premises app and web storage Use Windows Azure as a line of credit----Alternative text 1:For developers, building a Windows Azure application looks much like building a traditional .NET application. Microsoft provides Visual Studio 2008 project templates for creating Windows Azure Web roles, Worker roles, and combinations of the twoDevelopers are free to use any .NET language. Also, the Windows Azure software development kit includes a version of the Windows Azure environment that runs on the developer’s machine. This Windows Azure-in-a-box includes Windows Azure storage, a Windows Azure agent, and everything else seen by an application running in the cloud.Perform large-volume storage, batch processing, intense or large-volume computations off premisesUse Microsoft Web technologies such as ASP.NET, IIS, and Visual Studio 2008Add web services capabilities to existing packaged applications.Respond to business needs quickly and easily without worrying about operational constraintsReduce the effort and costs of IT managementAlternative text 2:At its core, “Building Intelligence” is an energy auditing and tracking solution. But like all companies, “Building Intelligence” wears a lot of hats. It has a web start-up division creating a new social networking website to collaborate around energy consumption. Because Windows Azure supports both Web-facing services and background processes, the application can provide an interactive user interface as well as executing work for users asynchronously. Rather than spending time and money worrying about infrastructure, the start-up can instead focus solely on creating code that provides value to its users and investors. The company can also start small, incurring low costs while its application has only a few users. If their application catches on and usage increases, Windows Azure can scale the application as needed.“Building Intelligence” is also an ISV because it is creating a software-as-a-service (SaaS) version of an existing on-premises, customer facing, .NET application, and in this case chooses to do it on Windows Azure. Because Windows Azure mostly provides a standard .NET environment, moving the application’s .NET business logic to this cloud platform won’t typically pose many problems. And once again, building on an existing platform lets the Building Intelligence focus on their business logic—the thing that makes them money—rather than spending time on infrastructure. “Building Intelligence is also an Enterprise player. Because Windows Azure is .NET-based, developers with the right skills aren’t difficult to find, nor are they prohibitively expensive. Running the application in Microsoft’s data centers frees the enterprise from the responsibility and expense of managing its own servers, turning capital expenses into operating expenses. And especially because application has spikes in usage, letting Microsoft maintain the large server base required for this can make economic sense.
  • To give you an idea of the magnitude of cloud computing, here are just a few numbers from Microsoft’s own cloud computing service offerings.Over a billion Windows Live authentications occur every single day!… 3 to 4 billion emails are filtered by forefront from 6 million mail boxes… 2 billion Bing queries happen every single month, 450 million Hotmail users, 20 million XBOX Live users, and 100 million Windows Update users!For you, the software developer: this represents a whole new paradigm in computing!
  • Slide objectives: Explain what the cloud is in relationship to on-premises servers and hosted severs. Speaking Points: To put the cloud in perspective, let’s first think about the available options for deploying and running your application today. Today, there are a few established approaches for deploying and running applications.ServerOn one side you have on-premises servers or a self-hosted model. With on-premises servers, you bring your own machines, connectivity, software, and in some cases software licenses.You have complete control of the environment, the software stack, the hardware, etc.However, you also have complete responsibility. Your organization must have the skills and expertise to operate and manage the environment and software. You must take on the responsibility of patching the environment, replacing hardware, etc.These days, very few people want to be in this business. However, on-premises servers are not going away anytime soon. In some cases organizations have to maintain solutions running in an on-premises environment due to regulatory, data, or privacy requirements.Hosted ServersAn established alternative to the on-premises model is with a hosted environment.With hosted servers, you are effectively renting capacity – including machines, connectivity, and in some cases software.With this model, you have less control then when you’re managing your own servers. For instance, you can’t walk up to a machine, and plug in an external drive to load data. Or easily make hardware or software adjustments to optimize for performance. However, you also have fewer responsibilities when it comes to operating, updating, patching, and managing the environment. What is generally much more attractive about a hosted model is the cost model.The upfront capital costs can be much lower then building out your own infrastructure. However, one of the downsides is that you generally pay for the fixed capacity on a monthly basis – even if your application is idle. CloudWhat we are starting to see in the industry is the emergency of the cloud as a platform for building and running applications. So what is the cloud and how does it relate to these established options for running your apps?A cloud platform is designed as a shared, multi-tenant infrastructure.Cloud platforms utilize virtualization to: share hardware resources, provide isolation of applications or tenants, and also to provide a more dynamic infrastructure.Ability to scale out your application over multiple server instances.Because it is a shared infrastructure, there is even less control compared to a hosted environment. As this is an emerging space, there is a wide range of different types of cloud solutions. Some of the solutions focus purely on providing virtualized infrastructure. Servers you can remote into. However, many cloud platforms are starting to focus on raising the level of abstraction – so you can focus on building and deploying applications rather than remoting into machines and maintaining or patching servers. Old:Level of abstraction varies greatly today with the solutions in the marketWithin the cloud, there are things that are delivered as an infrastructureServices – services provided by the infrastructure and services you would consume programmaticallyFinally, one of the primary reasons why organizations ranging from startups, independent software vendors, and large enterprises are starting to investigate the cloud is the pricing model. With a cloud platform, you can expect a pay as you go pricing model – where you pay for what you use. [build arrow] I believe it’s important to understand that the cloud is part of a continuum. It is one ofpotential approaches that you can begin to use to deploy and run your applications. However, it’s important to understand that the cloud is not the silver bullet. It is not the perfect solution for every application. Notes:We view cloud as scale out, automated service management, high availability and multi-tenantBut cloud has other considerations: location, infrastructure, business model, ownership and management
  • You may have heard the term “Software as a Service” or SaaS. There are several “as a service” terms associated with cloud computing: Infrastructure as a Service, or IaaS, is where you pay for infrastructure resources such as servers, storage devices, and network equipment. Platform as a Service, or PaaS, is where you pay for a platform that includes an operating system and application stack. PaaS is inclusive of IaaS. Software as a Service, or SaaS, is where you pay to use an application. SaaS is inclusive of both PaaS and IaaS.An example of PaaS is Windows Azure.An example of SaaS is Microsoft Exchange Online.
  • Let’s look at a few examples of cloud computing to get the idea. If you have an online application meant for consumers—such as a web site or an e-store—you could host that in the cloud. If you have a corporate application meant for your employees—such as an HR benefits management portal—you could host that in cloud and secure it to your enterprise. If you need to electronically integrate with customers or vendors—such as a shipping partner—you can use the cloud for shared applications, data, or messaging between organizations.There are lots of other ways to use the cloud. We’ll look at more scenarios later on.
  • To give you sense for how this impacts us as developers, here are just a few of the business opportunities driving our development efforts towards cloud applications… ISVs & SaaS Applications. For independent software vendors, cloud computing makes lots of sense as products transition into Software-as-a-Service offerings where quick scale is needed. Multi-tenancy makes cloud computing particularly cost effective. Mid-Market Enterprise. Analysts have identified mid-market enterprise as most likely to use cloud computing early on. Often this may be a single department taking the initiative. Enterprise application migration. Many enterprises will first put cloud computing to use by migrating existing applications in order to reduce operating costs or avoid the need to make further data center investment. Start-ups & Experimental Initiatives. The cloud is ideal for experimenting with projects that may succeed rapidly or may need to be shut down rapidly (“scale fast or fail fast”). This applies not only to start-ups but also to experimental initiatives within established companies. Fast Lane. Some companies will see the cloud as a “fast lane” to get around the lead time, obstacles, and project competition they face internally. Seasonal Businesses. Companies whose computing needs vary based on season are ideal candidates for the cloud. For example, a tax preparation service needs a lot of capacity in the Spring but not so much other times of year. Cloud Seen As A Competitive Edge. Azure is a playground for innovation, both technically and financially. Companies who seek a competitive edge will find the cloud a rich environment for innovation.
  • This reference chart may help us to recognize opportunities for using cloud computing within our own organizations or our vendors or customers.A new social networking sight may need a massive amount of scalability…A 911 call center may require that last “9” of reliability…A tax preparation package may require varying amounts of computational power, storage, and bandwidth…A hurricane relief site may need to launch on a moment’s notice and be available for a duration that is hard to predict at the onset of the disaster.A genome sequencing project or perhaps a search for extraterrestrial planets to live on in our future might require massive amounts of parallel processing power.A new online startup may need to begin business with little or no capital investment and fail fast with little or no financial lossSo with the terrific list of “great fits” … are there any “bad fits”? Well… yes… there are a few… at the present time…Frequently updated applications are not very good candidates. Primarily I say this because as a developer … the time that it takes to deploy is longer than if you had your own local on premise or hosted servers; however, you must take this with a grain of salt as you’ll have to compare it against the level of effort the you presently invest to make deployments in order to gauge the applicability of this advice.Applications needing external data storage are also not very good candidates at the present time.Of course, this is a moving target… and as cloud computing evolves further… even these bullets (and others like them) may move from the not-so-good list to the good-list. We are entering a new era of software development where we will once again be inspired and excited about our profession as software developers!
  • Many of us have been working with software for years, and some of us even decades. As such, we have an implicit understanding of our environment… we know what kind of architectural patterns to apply and what kind of code to write for our environments that will work. We are delighted that we don’t have to involve ourselves in the nitty-gritty details of how a network load balancer is configured or what kind of firewall is required. We are happy that there are other non-application developers taking care of these details for us so that we can focus on the architectural design of our software and writing code to implement those designs.All this having been said… we certainly would all agree that our software environment has an influence on the style of code that we write… without understanding our environment (at least at the macroscopic level)… we would likely make many missteps in the design and coding of our software. It is for this reason that I am spending a brief amount of time telling you a little more about your environment… to help us design and write applications better for the cloud.Microsoft Data Centers are a big part of the Azure story. Microsoft is building large, sophisticated cloud data centers around the world to complement its existing data centers. Two cloud data centers are in operation in the U.S. in Chicago and San Antonio. In 2010 we’ll see European data centers in Dublin and Amsterdam and Asian data centers in Hong Kong and Singapore.
  • Windows Azure provides hosting and storage and management.The Windows Azure data center infrastructure is called the Fabric and manages instances of your applications. The Fabric detects if something goes wrong and allocates replacement resources if necessary.You can host HTTP-accessed software such as web applications and web services in Windows Azure. You can also host background worker software.Windows Azure also provides non-database storage. This comes in 3 forms: blobs, queues, and data tables. Blobs are similar to files, queues are similar to enterprise queues, and data tables are record-based storage.The Windows Azure management portal allows you to create projects, deploy software, change number of instances, upgrade software, and promote between Staging and Production environments.
  • SQL Azure provides a database in the cloud. In fact it is based on SQL Server 2008. You can think of SQL Azure as a large subset of SQL Server 2008.Just to be clear though, SQL Azure only includes core database functionality, not Reporting Services, Analysis Services, or Service Broker. A lot of .NET software written for SQL Server will also work with SQL Azure. There are some features of SQL Server not available in SQL Azure such as user defined types. SQL Azure does supports stored procedures, which is another opportunity to leverage existing code. Later on I will show you some tools and techniques for migrating your existing Microsoft SQL Server databases to SQL Azure.The SQL Azure management portal allows you to create or drop databases and to configure a firewall to restrict database access. I will also demonstrate this later.Another SQL Azure feature is SQL Data Sync, which is a service that allows you to set up synchronization between cloud and on-premise databases or mobile devices.
  • AppFabric is what makes theAzure platform enterprise-ready.Windows Server AppFabric and Windows Azure platform AppFabric enable users to build and manage applications more easily both on-premises and in the cloud.Windows Azure platform AppFabric, formerly called “.NET Services”, helps developers connect applications and services in the cloud or on-premises. This includes applications running on Windows Azure, Windows Server and a number of other platforms including Java, Ruby, PHP and others. It provides a Service Bus for connectivity across network and organizational boundaries, and Access Control for federated authorization as a service. Windows Azure platform AppFabric is in CTP now.Service Bus helps to provide secure connectivity between loosely-coupled services and applications, enabling them to navigate firewalls or network boundaries and to use a variety of communication patterns. Services that register on Service Bus can easily be discovered and accessed, across any network topology.The Microsoft® Access Control helps you build federated authorization into your applications and services, without the complicated programming that is normally required to secure applications that extend beyond organizational boundaries. With its support for a simple declarative model of rules and claims, Access Control rules can easily and flexibly be configured to cover a variety of security needs and different identity-management infrastructures.Management of the Service Bus and the Access Control Service is done through the web portal. The Windows Azure Platform AppFabric is still in CTP, and at the time of this video some of the specifics were in transition.
  • The Windows Azure Cloud Fabric is what provides all of this…We get multiple virtual server instances provisioning on-the-fly.We get failure detection when one or more of these virtual server instances fails. Failures are rare, but when they happen, the Windows Azure Cloud Fabric will automatically spin up new server instances to replace failing ones.It’s the Windows Azure Cloud Fabric that controls how many instances are created and what role each instance plays. Of course it takes its queues from the configuration data that we supply.The Windows Azure Cloud Fabric also automatically configures load balancing for multiple service instances… and it does so in a very dynamic and flexible manner… allowing quick increases and decreases in available service capacity.
  • Here’s the datacenter in the cloudA collection of commodity hardwareA collection of storage servers; triple replicationLoad BalancersFabric Controller: the “Brains” behind it all. Web Portal: where to deploy and manage applicationsService – any app you want to run is the service.It’s about running your service in the Microsoft datacenter. Windows Azure is not a SKU that you would install onsite.
  • = Service Deployment (So easy, even a CEO can do it) =Service, the application you want to runModel, service configuration; tells what the service looks like, how many you want to run, etc.Today, you must deploy your service through the portal. In the future, there will be an API available that will you to deploy your service through command-line, TFS build procedures, and other types of automation In this scenario, we are deploying our service through the portal. We upload the two files (the service package and model configuration). The Fabric Controller reads the model configuration which describes how to deploy our service. In this case, we are deploying our service to 3 machines. The Fabric Controller determines which 3 machines to deploy to, copies the service package to the 3 machines, and fires up the services. [Transition] The Fabric Controller then configures the DNS so you have an endpoint exposed for your services for the outside world to communicate with your services. From there, it configures the load balancers and routers. That’s it. It’s completed automated.
  • So that’s what the Windows Azure Cloud Fabric is all about… We’re developers… and we want to write software that targets the Windows Azure Platform… but we don’t have all of this incredible infrastructure on our development machines. It’s unclear for example, just exactly how we might go about building an application that required Blob Storage without actually having Blob Storage.Microsoft create a Windows Azure Cloud Fabric simulation environment just for that purpose… to give the .NET developer a familiar environment to work in that simulates all of the environmental characteristics of the actual Windows Azure Cloud Fabric.The “DevFabric” as it is called, runs locally on our boxes and interfaces with Visual Studio to give us an interactive debugger, simulated data storage, and other cloud services.
  • As was hopefully evident, the Azure developer experience leverages what you’re already familiar with.If you’re a .NET developer and your favorite technologies are ASP.NET, Silverlight, Windows Communication Foundation, or SQL Server you’re going to be able to use those same technologies in the cloud.You also continue to use familiar tools including Visual Studio and SQL Server Management Studio.Azure isn’t just for .NET developers, however. Most of the services in the cloud are accessible as RESTful HTTP calls. That means Java developers, PHP developers, Python developers can also use Azure.For .NET developers, the Windows Azure SDK and tools for Visual Studio gives you a cloud simulator. The Development Fabric simulates the hosting environment and Developer Storage along with SQL Express simulate cloud data storage. This means you can develop cloud applications locally, even when offline.
  • To start building applications for the Microsoft Windows Azure cloud, you will need to download and install the Windows Azure SDK.You’ll find the link for downloading this in the Windows Azure Platform developers area located at the URL on this slide.You’ll also need to setup your Windows Azure Platform account, which you can do from the same page.The process is simple and not very interesting to developers, so I’m not going to walk through it. The only information that you will need is that when you create your Windows Azure account you will associate a Windows Live ID with it for authentication purposes. You must also provide credit card information for billing purposes.NOTE to presenters: you will need to setup your Windows Live and Windows Azure accounts ahead of time.
  • The Windows Azure platform is strong on application and service management.First off, the infrastructure of the cloud—called the Fabric—provides important management services for you, many of them automatic. This includes provisioning of machines, patching of operating systems, and deployment of applications and upgrades.Next, we have the management portal which allows self-management of your application in the cloud. From the portal, you can deploy your applications, promote between Staging and Production, scale your application up or down, and upload software updates.Finally, there are the diagnostic and management APIs which allow program code to see execution traces, monitor performance counters, and initiate actions in the cloud such as starting a deployment or increasing the number of instances for an application.
  • TODO: (insert this audio): “Once your Windows Azure Platform Services account has been setup, you’ll be able to manage your services through the portal.”The Azure management experience is one of its hallmarks. It’s very easy to set up new cloud projects for hosting, storage, database, communication, or security.The Windows Azure management portal shown here allows you to upload applications and deploy them to a Staging or Production environment. You can change the number of instances from here should you want to scale up or scale down. Promoting an application from Staging to Production is a 1-click affair. You’ll see much more about this in the Visual Studio demos and promotions that we’ll do.
  • The Windows Azure SDK will install several things that we need to create, test, and deploy new Windows Azure Cloud Services.First, we get a new project template for Visual Studio to create Web and Worker Role projects with. We will demonstrate these shortly…Second, we get the Local Developer Fabric to simulate our applications running in the cloud without ever having the bits leave our desktop. We can think of the Local DevFabric as “Cassini for the Cloud”…Third, we get the Local Development Storage Services to simulate the highly scalable data storage options in the cloud… Blobs, Tables, and Queues. Just to be clear… it does not install SQL Azure.. We’ll talk more on that in a bit.Fourth, support for debugging our cloud services. We can attach our Visual Studio debugger to our applications through the Local Developer Fabric, and then debug them just as we do any other kind of .NET application.Finally, we get a packaging tool, which is integrated into Visual Studio to pull all of our content and binaries together and prepare a Cloud Service package ready to be deployed to Windows Azure. In Visual Studio, this tool also prepares the Windows Azure configuration file.For now, we can think of SQL Azure as Microsoft SQL Server 2008 in the cloud. No SDK is required because SQL Express 2008 or SQL Server 2008 can be used for this purpose. Of course we may have existing database tools that we use for database design and development and all of those tools are still very usable here. We design and build our databases locally, and then we deploy those databases to the SQL Azure database server in the sky.
  • Let’s take a closer look at the details of service instance roles…Web Roles define a single HTTP and single HTTPS endpoint for external clients to use. These endpoints are exposed to the public Internet.Worker Roles are not exposed to the public Internet. They can define any number of internal endpoints for communication transmission via TCP or HTTP.Worker Roles may also receive communications from Windows Azure Storage Queues; likewise, Web Roles can communicate with Worker roles using the same.Both Web and Worker Roles can make outbound communication calls to publically accessible resources on the Internet using the HTTP or HTTPS protocols or by making .NET Framework Class Library socket connections.Both Web and Worker Roles can access Windows Azure Storage using RESTful API’s or the Windows Azure Storage Client Library which is part of the Windows Azure SDK.
  • When you create your first Cloud Application, you might be confused when Visual Studio offers you to chose roles for your cloud service application from the 4 roles it offers. If you look closely though, you will see that are really only two roles,and one of those roles simply comes in three flavors. Visual Studio is just providing you with projects that make appropriate Framework Class Library references based on what you will be using the Web Role for.The Web Role comes in three flavors:ASP.NET Web Role – for developing ASP.NET Web Applications (including those using Silverlight).WCF Service Web Role – for developing Windows Communication Foundation applications.CGI Web Role – for developing FastCGI Applications with PHPThe Worker Role is just the Worker Role
  • When we own and manage our own servers, we have a lot of concerns…We have upfront planning to do for our peak usage. In other words, we have to anticipate how much hardware demand there will be on our application, and we have to make our hardware purchases based on our peak demand. If we don’t purchase enough servers, we may lose business because our servers will be too busy. If we purchase too much capacity, we will have wasted a lot of money buying hardware that we didn’t need.We have to plan for hardware redundancy to reduce our down time. Not only for servers, but also for critical components of our network infrastructure. Of course, whatever we plan for, we will need to purchase.We have to make all of our server and software purchases up-front as a capital expenditure.We have to be concerned with how hardware failures will be detected in our infrastructure, and what automated or possibly manual procedures will have to be in place to recover when a CPU smokes or a hard drive head crashes into a platter. Do we need backup parts on hand? Are we going to attempt repairs, or do we want to just swap out failing equipment?It is difficult in a complex environment to estimate these things in a reliable manner.
  • The Microsoft Windows Azure Platform takes us down an easier path with respect to hardware concerns.We make no up-front capital expenditures. Everything is pay-as-you-go for what you need, when you need it.We don’t have to determine what level of redundancy we may require as Windows Azure has built in redundancy.We don’t have to closely estimate what our peak usage might be, as we can add additional server instances any time we demand for our application requires them.We don’t have to worry about what happens when a server or network component fails, as the Microsoft Windows Azure platform provides built-in diagnostics and failure recovery. Windows Azure will dynamically repair itself.We developers can stay focused on applications and not the infrastructure.
  • When we own and manage our own networks, we have a lot of concerns…We must concern ourselves with the topology of our networks and connectivity of our servers.We must establish and maintain firewalls and DMZ areas.When new ideas come along requiring changes, we must often invest significant time in battling institutionalized resistance
  • Here again, the Microsoft Windows Azure Platform takes us down a more comfortable pathNetwork topology and connectivity are created on the fly from configuration dataFirewall rules are easy to maintain and configureThe DMZ is build into the cloud. Many security concerns are no longer a problem for the application developer or the network administrator as they now belong to the Microsoft data center.Innovative ideas can be explored outside of entrenched and sometimes legacy I/T policies.
  • Here is a list of resources that will allow you to follow up on many of the features you’ve seen today, as well as become part of our development community!
  • We’ll take a tour of SQL Azure as a data storage option and then we’ll look at the various types of data storage offered with Windows Azure… in particular, Blobs, Tables, and Queues. I will also make reference to additional materials regarding a new type of data storage that was recently added called Drives.We’ll also learn how to inspect the contents of Windows Azure Data Storage.
  • It’s my intention that when we have completed this session, you’ll have a good understanding of the various data storage options, and you’ll be able to make informed decisions about which types are best for a given storage requirement.
  • We’ll start with SQL Azure... This will give most of developers a common frame of reference as most developers are comfortable with relational databases.In a short while, I will introduce Blobs, Tables, Queues, and DrivesSQL Azure can be thought of as your SQL Server in the cloud. It is based on a subset of SQL Server 2008.Blobs are a means of storing unstructured data, such as pictures, movies, PDF’s, Word documents, and the like.Tables are a means of storing semi-structured or tabular data. Tables are similar to an Excel spreadsheet in the sense that data is tabular and there is no strict type cohesion as there would be in a SQL Server table column. Data stored in tables is partitioned and keyed for retrievalQueues are a means of buffered message delivery. There are very useful for communicating data between our Windows Azure service instances. As our service instances do not have to wait around for the I/O of delivering the message or the result of the message processing, they can dramatically improve the scalability of our software system.Drives are a recently added feature announced at the Los Angeles PDC in November 2009. Drives provide durable storage that appears to our application as an NTFS volume. The drive itself is an abstraction over the same Windows Azure Data Storage used for Blobs. You can get more information on Drives by visiting the PDC site on my slide.Applications may use multiple types of data storage at the same time. In fact, this is quite common. When we do our first Windows Azure Data Storage demo together, I will be showing you an application that uses Blobs, Tables, and Queues in concert.
  • As I stated earlier, SQL Azure is based on SQL Server 2008. At this time it is only a subset of the features of the server product.My intention here is to convey the high level features that are supported and the ones that are not.SQL Azure will support most of the things we need… Tables, Index, Views, Stored Procedures, Triggers, and Constraints… in my book… that’s all the functionality that I need for most of my applications.There are some other adjunct technologies that ship as part of SQL Server 2008 such as SQL Reporting Services and Analysis Services which are not supported. The Service Broker is also not supported.
  • The current offering of SQL Azure provides just core relational database services.In the future, Microsoft will be offering Data synchronization based on the Sync framework so that on premise and mobile databases can be synchronized with databases in the cloud.Business Intelligence and SQL Reporting will be available as an SaaS (Software as a Service)And some new services will be unveiled such as Reference Data and Secure Data Hub. These our outside the scope of this presentation though, so feel free to point your favorite search engine at these terms for more information.
  • So let’s assume that we have designed our relational database with local developer and data modeling tools.We can begin our story then by assuming that we want to get our database deployed to the cloud.There are some tools that will expedite this process which I will show you later, but for now lets assume that we have scripted our database schema. We apply this script to SQL Azure which speaks native TDS.If you created your database through the SQL Azure Portal, then SQL Azure will have created one master database and three replicas of that database. If you create your database with the script the same will be true.These replicas are stored in different database centers from the master to provide redundancy and protection against geographical catastrophe.
  • Configuring our application to use SQL Azure storage instead of SQL Server is simply a matter of modifying the connection string in our application’s configuration file.When our application requests data, ADO.NET speaks to the TDS which directs our queries to the master database server. The master database server performs our query and returns the results to our application.
  • From our application’s point of view, there is only one SQL Azure database.As we make updates to our database, those updates are replicated to other copies stored in other data centers so that in the event that our database fails for any reason, the other databases will be standing by ready to take its place.
  • But what if that master database server fails for some reason?TDS is receives notification of the database failure and automatically redirects the call to the replica!The Azure Cloud Fabric is self-healing… and the details are outside the scope of this presentation; however, the fabric will get busy repairing itself like drones on a Borg mother ship… essentially with the objective of keeping three replicas online at a time.
  • I will demonstrate creating a SQL Azure account in session 3 where I will walk you through the entire process.For now I simply want to give you some background information to prepare you for our first demonstration.When we create our SQL Azure database server, we’ll be prompted for an Administrator’s name and a password.This username and password will be the granted a system administrator role that is similar to the “sa” account on a local SQL Server 2008 box. The account has permission to create and drop databases and database ownership authority in any databases that you create with this account.
  • After creating your SQL Azure database server, you will want to grant appropriate access through the SQL Azure firewall.SQL Azure provides a very simple and easy to maintain firewall. The firewall is so easy to use that it’s only going to get one slide in my deck!The firewall allows us to expose our database to Windows Azure services via a checkbox and to add ranges of IP addresses such as your home office and your business… or possibly the address of a 3rd party server hosting some application that needs data access.I’ll do a thorough demo of this feature in session 3…
  • When you created your SQL Azure database server, you supplied an administrator’s user name and password. I have named my user accordingly… to remind me of its power.The SQL Portal will offer you the ability to copy these credentials in connection string format to your clip board… tempting you into believing that you should just paste this into your configuration file.This is terrific for demos like mine… BUT you should NEVER, EVER do this…A database server system administrator password placed in a configuration file in clear text format… there has got to be something naive in the extreme going on here… and worse… no way to create non-sa-like users through the UI… you must script your database users and then apply the script to the database. And to anticipate your question… no… you can’t use SQL Server Management Studio to do this either.I will demo this as well in session 3… so hang tight…
  • There are a number of techniques for getting data migrated from an existing database into a SQL Azure database.One very effective technique is to script the database schema and any stored procedures or views and then apply these scripts to the SQL Azure database. Once the schema has been deployed to the cloud, BCP can be used to copy the data in.Another effective technique is to utilize SQL Server Integration Service which will transfer the Schema and the Data.
  • I think that I saved the best for last here… The SQL Server Migration Wizard is available for download from the CodePlex website at the URL on this slide.To quote the website, “The SQL Azure Migration Wizard helps you migrate your local SQL Server 2005 / 2008 databases into SQL Azure. The wizard walks you through the selection of your SQL objects, creates SQL scripts suitable for SQL Azure, and allows you to migrate your data.”I will demonstrate this tool in session 3 when I use it to migrate an application and associated database from the local desktop to the cloud.
  • Although some things can be done with SQL Server 2008 Management Studio, I highly recommend that you use the 2008 R2 Nov CTP as it is SQL Azure aware.After you have created your system administrator account for SQL Azure, you can use SQL Server Management Studio R2 CTP to make connections to the database and execute scripts such as the one that I am showing in this slide.
  • Okay… That’s all about SQL Azure for now… we’ll come back to this topic in Session 3…Keep in mind that SQL Azure is a separate product from Windows Azure…. And that Windows Azure includes Windows Azure Data Storage, which we are going to talk about now. We will be using the Windows Azure Data Storage directly in demos, so these slides will provide more of a brief and high level overview.To get Windows Azure Data Storage setup, we simply create a new Storage Account from the Windows Azure Portal.
  • Our Windows Azure Data Storage will be accessible via RESTful queries at the endpoints you see on this slide, or via the API in the Windows Azure SDK library.We’ll be using the Windows Azure library in our demo.
  • Also provided on our data storage setup screen is the Account Name and a Primary and Secondary Access Key.Our Account name uniquely identifies our Data Storage locationThe Access Keys are a small chunk of encrypted data that prove our identity to Windows Azure Data Storage. We’ll use the Primary Access Key to access and update data stored in Data Storage.
  • It’s time now to introduce Windows Azure Data Storage Blobs.Blobs are for storage of unstructured data.We partition our data by creating Blob containers which we give names to.We can create an unlimited number of Blob Containers.We then simply place our blob data into the blob containers, supplying a unique identifier.When we want to retrieve our data, we simply provide the container and the unique identifier.
  • Windows Azure Data Storage Tables are how we get massively scalable and highly available databases.Although there are some similarities, these tables are very different from relational database tables.Data in Windows Azure Data Storage Tables is semi-structured; The concept of a Windows Azure Data Storage Table is similar to how a spreadsheet is used to provide tabularized organization to data without strongly enforcing data cohesion.… Data is indexed in Tables for high performance retrieval, but there are no relationships between Tables.The tables support ACID transactions over single entities and rich queries over the entire table.
  • The PartitionKey combined with the RowKey uniquely identifies an entity in a table.
  • 11:53Getting the all of dunnry’s post it fast because we’re selecting the entities by a partition keyGetting all of the posts after a certain is slow because we may have to traverse across multiple servers because we’re selecting entities that span partition keysA query without the partition key is really a scan
  • We have included this feature comparison table in anticipation of your likely questions about differences between using a relational database table as you may be currently doing with your SQL Server databases and the new Windows Azure Tables included in Windows Azure.
  • Queues are a means of buffered message delivery. There are very useful for communicating data between our Windows Azure service instances.
  • Use queues as a way of communicating w/ the backend worker rolesWRs call getmessage and pass timeoutTimeout value is importantExpiration time is important; message is marked in the queue as invisible; for duration of timeout it’s invisibleWhen we’re done processing, we call a message to remove the message through a deleteTh reason we do this is imagine we have a second worker role; if something goes wrong, once the timeout expires, the message becomes visible, and the next person to do a get message will get the message
  • Here is a list of resources that will allow you to follow up with us on any of the features you’ve seen today as well as become part of our development community!
  • Windows Azure DiagnosticsLogging and Monitoring in the Cloud
  • Welcome back to session 3 of our 3 part presentation! In case you are just joining us, my name is <name> and we’re going to be doing nothing but a non-stop demonstration of how to build and deploy web applications and databases to the cloud.
  • Build Web ApplicationMigrate Web Application to Windows AzureDeploy to the CloudMigrate Database to SQL ServerMigrate SQL Database to SQL AzureDeploy SQL Azure DatabaseMigrate Web Application to the Cloud
  • Understand the process of building and deployment web applications and databases to Windows Azure and SQL Azure.
  • First… lets start with a clean slate and build a web application from the ground up. We’ll get that application running on our desktop in the local Windows Azure DevFabric. The Cloud will not be a part of this step... But well get there very soon.
  • In this step of our demonstration, we are going to take the web application that is presently running in the local DevFabric and we’re going to deploy it to what’s called the Staging area in the Windows Azure Cloud. Once we have completed this step, we’ll launch our web browser against the Staging area to see our application run in the Cloud for the very first time.
  • In this step of our demonstration, we are going to take the web application that is presently running in the Windows Azure Staging area, and we’re going to promote it to the Production environment.Once we have completed this step, we’ll launch our web browser against the Production environment to see our application run as our production users would see it.
  • In this step of our demonstration, we’re going back to our local DevFabric and making some changes to our application to migrate it from using XML data files to a SQL Server database. We’ll execute our application from the local Devfabric to get things running. Since this step is all development work, nothing will happen in the cloud… that will come later when we deploy.
  • In this step of our demonstration, we’re going to deploy only our SQL Database into the SQL Azure cloud. We’ll continue to execute our application from the local Devfabric to ensure that everything went smoothly with our database promotion.Unlike Windows Azure, SQL Azure does not have a Staging area, so this represents a direct promotion of our database into the production environment.
  • In this step of our demonstration, we’re going to complete our full deployment of database and application to the cloud!As you may recall, we already have a version of your application sitting in the production environment. This is the version that runs off of an XML data store.We’ve already deployed our SQL Database into the SQL Azure cloud… but I’m showing it here just to give us context. We’ll proceed now with deploying our web application to Windows Azure. We’ll deploy to staging and test there. Then when we are satisfied that everything is working properly, we’ll swap Production and Staging.Once this has been done, we’ll point our web browser at the Production environment to see our finished product!
  • In this step of our demonstration, we’re going to complete our full deployment of database and application to the cloud!As you may recall, we already have a version of your application sitting in the production environment. This is the version that runs off of an XML data store.We’ve already deployed our SQL Database into the SQL Azure cloud… but I’m showing it here just to give us context. We’ll proceed now with deploying our web application to Windows Azure. We’ll deploy to staging and test there. Then when we are satisfied that everything is working properly, we’ll swap Production and Staging.Once this has been done, we’ll point our web browser at the Production environment to see our finished product!
  • In this step of our demonstration, we’re going to show how updates can be made to our live Windows Azure application.We’ll revise our application with Visual Studio and test it locally from our Dev Fabric. Then, in the interest of demonstration brevity, we’ll deploy our revised application directly into the production environment, thereby bypassing staging.Once our upgrade deployment has been completed, we’ll point our web browser at the Production environment to see our finished product!
  • In this step of our demonstration, we’re going to show how configuration changes can be made to our Windows Azure environment, such as the number of web and worker instances to create to service our application’s users.It is important to understand the differences between our application’s configuration and the services configuration. Our application keeps its configuration data in its web.config file, while the service keeps its environmental configuration in the ServiceConfiguration.cscfg. If you consider the procedures that we have been through, it will be apparent that changes made to the web.config file will require a service redeployment as that is the only way to get a service package propagated to service instances.Keep in mind that it’s possible to add custom configuration to the ServiceConfiguration as we did for the demos in the Data segment of this presentation thereby avoiding the need to redeploy when making configuration changes.Let’s proceed with a configuration change to the ServiceConfiguration.cscfg file.
  • In this step of our demonstration, we’re going to create a new SQL Azure Login and Database User
  • Here is a list of resources that will allow you to follow up on many of the features you’ve seen today, as well as become part of our development community!
  • Here is a list of resources that will allow you to follow up on many of the features you’ve seen today, as well as become part of our development community!
  • Questions?
  • The Windows Azure Platform (MSDN Events Series)

    1. 1. Take Your Applications Sky High with Cloud Computing and the Windows Azure Platform<br />Dave Bost<br />Developer Evangelist<br /><br />
    2. 2. For developers who have a thirst for knowledge<br /><br />
    3. 3. Session 01:Introduction to Microsoft Windows Azure<br />
    4. 4. Agenda<br />Windows Azure in Action<br />Windows Azure Services Platform<br />Core Services<br />Getting Started<br />Roles<br />Developing Azure Applications<br />
    5. 5. Objectives<br />How to get started with:<br />Windows Azure Platform<br />Windows Azure<br />Windows Azure Data Services<br />Web and Worker Roles<br />Development tools you need<br />Ability to develop Windows Azure applications<br />
    6. 6. Demo<br />Live Windows Azure Application In The Cloud<br />
    7. 7. What is Cloud Computing?<br /><ul><li> A New Style of Computing</li></ul> Consumption Based Pricing<br /><ul><li> Hosting, Storage, Database, Other Services
    8. 8. Software as a Service (SaaS)
    9. 9. On-Demand Scale - Mammoth Capacity
    10. 10. High Availability and Reliable
    11. 11. Self-Service Management
    12. 12. Real and Here to Stay</li></ul> Additive to the Enterprise, Not Replacing<br />
    13. 13. What are the Windows Azure Use Cases?<br />On-Premise Application <br />and Cloud Storage <br />Hosting output of 3D design and archiving enterprise data<br />Scalable Web<br />Brand web site or photo sharing <br />service<br />Migration of Legacy <br />Applications to <br />Windows Azure <br />Move legacy applications <br />without re-architecting <br />the infrastructure<br />Scalable Web <br />Application with<br />Worker Role <br />Hosted inventory <br />management <br />integrated with <br />retail POS terminals<br />Using Windows Azure<br />Computational Power<br />Scientific computation<br />Large-scale data mining<br />
    14. 14. Why Are We Here?Because Cloud Computing is Huge<br />At Microsoft:<br /><ul><li>1 billion: Windows Live ID authentications each day
    15. 15. 3 to 4 billion: the # of emails filtered daily from >6 million mail boxes by Forefront
    16. 16. 2 billion: the # of queries each month on Bing
    17. 17. 450 million:Hotmail users (now 15 years old)
    18. 18. 100 million:users that get Windows Update worldwide, (now 12 years old)
    19. 19. 20 million:Xbox Live users (now 9 years old)
    20. 20. +400,000: square footage of our new datacenters</li></ul>For You:<br />A new paradigm in computing<br />
    21. 21. Platform Continuum<br />On-Premises<br />Servers<br />Hosted Servers<br />Cloud Platform<br /><ul><li>Bring your own machines, connectivity, software, etc.
    22. 22. Complete control
    23. 23. Complete responsibility
    24. 24. Static capabilities
    25. 25. Upfront capital costs for the infrastructure
    26. 26. Renting machines, connectivity, software
    27. 27. Less control
    28. 28. Fewer responsibilities
    29. 29. Lower capital costs
    30. 30. More flexible
    31. 31. Pay for fixed capacity, even if idle
    32. 32. Shared, multi-tenant infrastructure
    33. 33. Virtualized & dynamic
    34. 34. Scalable & available
    35. 35. Abstracted from the infrastructure
    36. 36. Higher-level services
    37. 37. Pay as you go</li></li></ul><li>IaaS, PaaS and IaaS<br />Infrastructure as a Service<br />Platform as a Service<br />Software as a Service<br />SaaS<br />ApplicationsPackaged Software<br />PaaS<br />PlatformOS & Application Stack<br />PlatformOS & Application Stack<br />IaaS<br />InfrastructureServers · Storage · Network<br />InfrastructureServers · Storage · Network<br />InfrastructureServers · Storage · Network<br />
    38. 38. Enterprise to Cloud<br />Corporate &Departmental Applications<br />Consumer to CloudPublicly Accessible<br />Web Sites, e-Stores & ISV SaaS Applications<br />Cloud Computing Examples<br />Cloud as a Hub Between Multiple Companies<br />Enterprise to Enterprise<br />Company A<br />Company B<br />Company<br />
    39. 39. Driving Forces<br />ISVs & SaaS Applications<br />Mid-Market Enterprise<br />Enterprise Application Migration<br />Start-ups & Experimental Initiatives<br />Cloud Seen as a Fast Lane to Get to Market Faster<br />Seasonal Businesses<br />Under Pressure to Dramatically Reduce I.T. Costs<br />Cloud Seen as a Competitive Edge<br />
    40. 40. Where the Cloud is Compelling<br />
    41. 41. Microsoft Data Centers<br />Vision<br />Go Inside<br />Energy Efficient<br />Containers<br />
    42. 42. Windows Azure<br />Fabric – Service Management Infrastructure<br />Hosting – Applications, Web Services, Workers<br />Storage – Blobs, Queues, Tables, Drives<br />Frictionless Upgrades<br />Compute<br />Storage<br />Management<br />Compute<br />Storage<br />Management<br />Management<br />Relational data<br />Connectivity<br />Access control<br />
    43. 43. SQL Azure<br />Core Database Functionality, Subset of SQL Server<br />Database available in limited sizes 1GB, 10GB<br />Management<br />SQL Data Sync<br />Management<br />Relational data<br />Compute<br />Storage<br />Management<br />Management<br />Relational data<br />Connectivity<br />Access control<br />
    44. 44. Windows Azure AppFabric<br />Service Bus<br />Access Control Service<br />Management<br />Compute<br />Storage<br />Management<br />Management<br />Relational data<br />Connectivity<br />Access control<br />
    45. 45. Windows Azure Cloud Fabric<br />Multiple virtual instances<br />Easily provision of applications<br />Detect failures<br />Spin up new instances to replace the failed ones<br />How many instances and what role they will play<br />Load balances and DNS<br />Elasticity of the service… scaling up/down number of instances<br />
    46. 46. Windows Azure<br />Your<br />Service<br />DNS<br />LB<br />Web Portal<br />(API)<br />LB<br />Fabric<br />Controller<br />
    47. 47. Service<br />Service<br />Service<br />Model<br />Your<br />Service<br />DNS<br />LB<br />Web Portal<br />(API)<br />DNS<br />config<br />LB<br />Service Deployment<br />Fabric<br />Controller<br />
    48. 48. Your<br />Service<br />Service<br />Service<br />DNS<br />Service<br />Service<br />Service<br />Service<br />Service<br />LB<br />Service<br />Web Portal<br />(API)<br />LB<br />Model<br />Service Scaling<br />Fabric<br />Controller<br />
    49. 49. Your<br />Service<br />Service<br />DNS<br />Service<br />Service<br />Service<br />LB<br />Web Portal<br />(API)<br />!<br />LB<br />Model<br />Service Monitoring & Recovery<br />Fabric<br />Controller<br />
    50. 50. Windows Azure DevFabricLocal Developer Simulation of AppFabric<br />Simulated “Cloud Experience” for Development<br />Routes cloud requests to local machine<br />Simulates data storage with local SQL server database<br />Azure SQL simulated with local SQL Server database<br />
    51. 51. Developer Experience<br />Developer Experience<br />Use existing skills and tools<br />Leverage Existing Skills in .NET, SQL Server, WCF<br />Use Familiar tools – Visual Studio, SSMS<br />RESTful HTTP cloud services, supports PHP, Python<br />Cloud apps can be developed locally / offline<br />SDK Cloud Simulator – Dev Fabric, Dev Storage<br />
    52. 52. Getting Started With Windows AzureThe Windows Azure SDK<br /><br />
    53. 53. Service Management<br />Automated Service ManagementProvisioning, Patching, Upgrades<br />Fabric<br />Self ManagementDeploy, Promote, Scale, Upgrade<br />Management Portal<br />Programmatic ManagementProgrammatic deployments upgrades, etc. API for doing what the portal does<br />Management API<br />
    54. 54. Getting Started with Windows AzureThe Windows Azure Platform Portal<br />Provision<br />Deploy<br />Promote<br />Stop/Start<br />Scale<br />Upgrade<br />Delete<br />
    55. 55. Windows Azure SDK Features<br />C# and VB Visual Studio project templates<br />Windows Azure Cloud Service solution with multiple roles.<br />Tools to manage and configure roles<br />Local Development Fabric<br />Local Development Storage services<br />Local Cloud Service debugging support<br />Cloud Service package and deployment builder<br />No SDK Required for SQL Azure<br />
    56. 56. Defining the Web and Worker Roles<br />WEB ROLE<br />WORKER ROLE<br />Interacts with end-user<br />or web services<br />Handles incoming<br />HTTP/HTTPS requests<br />Develop with Microsoft and<br />non-Microsoft tools:<br />ASP.NET, WCF, other .NET tools<br />Java, PHP, etc.<br />Does not accept<br />incoming requests<br />Initiates their own requests<br />for data or tasks from <br />the queue<br />Similar to a &quot;batch job&quot;<br />or Windows service<br />
    57. 57. Windows Azure Role Details<br />Web Roles<br />Define a single HTTP endpoint and a single HTTPS endpoint for external clients<br />Worker Roles<br />Define internal endpoints for HTTP, TCP <br />May receive work from Windows Azure Storage Queues<br />Web and Worker Roles<br />Can make outbound HTTP/S or .NET Framework class library socket connections to Internet accessible resources<br />Can access Windows Azure Storage services via REST APIs or the Windows Azure Storage Client Library.<br />
    58. 58. Service Models & Roles<br />Bid Now Service<br />Worker X<br />Web A<br />(port 80)<br />Main Web<br />100 instances<br />Image Resize<br />2 instances<br />Worker Y<br />Auction Processing<br />25 instances<br />Web B <br />(port 8081)<br />Admin<br />2 instances<br />Worker Z<br />Notifications<br />10 instances<br />
    59. 59. Windows Azure Roles in Visual Studio<br />
    60. 60. Demo<br />Building Our First Cloud Application<br />With Microsoft Windows Azure<br />
    61. 61. Application Concerns—Hardware<br />Server Instances<br />Plan for peak usage scenarios<br />Plan for redundancy to reduce down time<br />Make up-front capital expenditures<br />Servers<br />Networking / Load Balancers<br />Software Licensing<br />Hardware Diagnostics & Failure Recovery<br />Detection of failures<br />Repair or replacement<br />Backup parts on-hand<br />
    62. 62. Azure Solution– Hardware<br />Hardware Acquisition<br />No up-front capital expenditures<br />Windows Azure provides redundancy<br />Windows Azure scales to meet peak usage<br />Hardware Diagnostics & Failure Recovery<br />Windows Azure detects hardware failures<br />Windows Azure dynamically repairs itself<br />
    63. 63. Application Concern – Network Security<br />Network Security<br />Network Topology & Connectivity<br />Firewall Rules & Maintenance<br />De-Militarization Zone (DMZ)<br />Institutional Resistance to Change<br />
    64. 64. Azure Solution – Azure Network Security<br />Network Security<br />Network Topology & Connectivity <br />Created on the fly from configuration<br />Firewall Rules & Maintenance<br />Provided and configurable<br />De-Militarization Zone (DMZ)<br />Provided<br />Institutional Resistance to Change<br />Moves many security concerns to the cloud<br />
    65. 65. Conclusion<br />You are now Windows Azure savvy…<br />You’ve seen Windows Azure in action…<br />You’ve learned about the platform and its components and core services<br />You understand instance roles<br />You know the tools you will need to begin<br />You’re excited to use this new technology<br />And you can hardly wait for session 2 on data…<br />
    66. 66. Resources – Windows Azure Platform<br />Windows Azure Developer Platform<br />Channel 9 videos<br />Windows Azure Platform Training Kit<br />Microsoft PDC 2009<br />Windows Azure SDK<br />
    67. 67. Session 02: Windows Azure Platform Data Storage<br />
    68. 68. Agenda<br />Windows Azure Platform Data Storage Options<br />Getting Started with SQL Azure Data Storage<br />Getting Started with Windows Azure Data Storage <br />Blobs<br />Tables<br />Queues<br />Drives<br />Inspecting the contents of Windows Azure Data Storage<br />
    69. 69. Objectives<br />Learn the data storage options offered by the Windows Azure Platform and become familiar with choosing and using the appropriate one for your application<br />
    70. 70. Azure Platform Data Storage Options<br /><ul><li>SQL Azure
    71. 71. Relational data storage
    72. 72. Windows Azure Data Storage
    73. 73. Blobs
    74. 74. Unstructured data storage
    75. 75. Tables
    76. 76. Semi-structured or tabular data storage
    77. 77. Queues
    78. 78. Buffered delivery data storage
    79. 79. Drives
    80. 80. Durable NTFS volumes that Windows Azure applications can use. See:</li></li></ul><li>SQL Azure Features<br />Supported<br />Tables, Indexes, Views<br />Stored Procedures<br />Triggers<br />Constraints<br />Table Variables<br />Temp Tables (#Name)<br />Not Supported<br />Physical Server Access <br />Catalog DDL<br />Common Language Runtime<br />Service Broker<br />Reporting Services<br />Analysis Services<br />Distributed Transactions and Queries<br />
    81. 81. SQL Azure<br />Initial Services<br />Database – Core SQL Server database capabilities <br />Future Services<br />Data Sync – Enables the sync framework<br />Additional SQL Server capabilities available as a service: Business Intelligence and Reporting<br />New services: Reference Data and Secure Data Hub<br />
    82. 82. SQL AzureDeployment<br />Web Portal<br />(API)<br />DB Script<br />SQL Azure<br />TDS<br />
    83. 83. SQL AzureAccessing databases<br />Web Portal<br />(API)<br />Your App<br />SQL Azure<br />TDS<br />Change Connection String<br />
    84. 84. Database Replicas<br />Single Database<br />Multiple Replicas<br />Replica 1<br />Single Primary<br />Replica 2<br />DB<br />Replica 3<br />
    85. 85. SQL AzureDatabase Monitoring & Recovery<br />Web Portal<br />(API)<br />!<br />Your App<br />SQL Azure<br />TDS<br />
    86. 86. SQL Azure Server Creation<br />
    87. 87. SQL Azure Firewall Maintenance<br /><ul><li>Simple rules
    88. 88. Easy one-screen portal maintenance</li></li></ul><li>SQL Azure Database Connection String<br />An administrative user is created with the server<br />User has system administrator permissions likesa”<br />; Database=FabrikamAzureDB;User ID=FredSa;Password=myPassword;Trusted_Connection=False;Encrypt=True;<br />
    89. 89. Demo<br />SQL Azure Database Application<br />
    90. 90. Database Migrations<br />Scripts<br />Transfer Schema<br />BCP<br />Transfer Data<br />SSIS (SQL Server Integration Service)<br />Transfer Schema and Data<br />
    91. 91. Database Migrations (Cont.)<br />The SQL Azure Migration Wizard helps you migrate your local SQL Server 2005 / 2008 databases into SQL Azure. The wizard walks you through the selection of your SQL objects, creates SQL scripts suitable for SQL Azure, and allows you to migrate your data.”<br /><br />
    92. 92. Database Management using SQL Management Studio<br />
    93. 93. Getting Started with Windows Azure Data Storage<br />
    94. 94. Windows Azure Data Storage<br />
    95. 95. Account Name / Key<br />AccountName<br />A unique name identifying the Azure Data Storage<br />AccountKey<br />A blob of encrypted data used for authentication<br />
    96. 96. Windows Azure Data Storage - Blobs<br />Unstructured data storage<br />Partitioned by container<br />Unlimited containers<br />
    97. 97. Demo<br /><ul><li>Windows Azure Data Storage – BlobsThe GuestBook Application
    98. 98. Examining the contents ofWindows Azure Data Storage</li></li></ul><li>Examining Windows Azure Data Storage<br />
    99. 99. Demo<br />Examining the contents of<br />Windows Azure Data Storage<br />
    100. 100. Windows Azure Data Storage - Tables<br />Windows Azure Table provides scalable, available, and durable structured (or semi-structured) storage in the form of tables.<br />The tables contain entities, and the entities contain properties.<br />The tables are scalable to billions of entities and terabytes of data, and may be partitioned across thousands of servers.<br />The tables support ACID transactions over single entities and rich queries over the entire table.<br />Simple and familiar .NET and REST programming interfaces are provided via ADO.NET Data Services. <br /><br />
    101. 101. Windows Azure Data Storage – Tables (Terms Part 1)<br />Table – contains a set of entities. <br />Entity (Row) – Entities are the basic data items stored in a table. <br />Property (Column) – This represents a single value in an entity. <br />PartitionKey– The first key property of every table. The system uses this key to automatically distribute the table’s entities over many storage nodes.<br />
    102. 102. Windows Azure Data Storage – Tables (Terms Part 2)<br />RowKey– A second key property for the table. This is the unique ID of the entity within the partition it belongs to. <br />Timestamp – Every entity has a version maintained by the system.<br />Partition – A set of entities in a table with the same partition key value.<br />Sort Order – There is a single index provided for the CTP, where all entities in a table are sorted by PartitionKey and then RowKey<br />
    103. 103. Key Example – Blog Posts<br />Partition 1<br />Partition 2<br />Getting all of dunnry’s blog posts is fast<br />Single partition<br />Getting all posts after 2008-03-27 is slow<br />Traverse all partitions<br />
    104. 104. SQL Azure and Windows Azure Table Comparison<br />Windows Azure Tables<br />SQL Azure Tables<br />Semi-structured<br />Loosely typed<br />Non-Relational (Not RDMS)<br />Massively scalable<br />Fully structured<br />Strongly typed<br />Relational (RDMS)<br />Highly scalable<br />
    105. 105. Demo<br />Windows Azure Data Storage - Tables<br />The GuestBook Application<br />
    106. 106. Windows Azure Data Storage - Queues<br />Buffered delivery data storage<br />Read at least once<br />Delete to remove message, otherwise is returned to queue<br />Partitioned by Queue Name<br />
    107. 107. Azure Queues<br />RemoveMessage<br />GetMessage (Timeout)<br />Worker Role<br />PutMessage<br />Queue<br />Msg 1<br />Msg 2<br />Msg 2<br />Msg 1<br />Web Role<br />Worker Role<br />Worker Role<br />Msg 3<br />Msg 4<br />Msg 2<br />
    108. 108. Demo<br />Windows Azure Data Storage - Queues<br />The GuestBook Application<br />
    109. 109. Resources<br />Azure Portal<br /><br />Tools<br />SQL Azure Migration Wizard<br /><br />Azure Storage Explorer <br /><br />Windows Azure Management Tool (MMC)<br /><br />Windows Azure Forums<br /><br />
    110. 110. ResourcesWindows Azure Data Storage<br /><ul><li>Haridas, Jai. “Windows Azure Tables and Queues Deep Dive”. Microsoft PDC. 2009.
    111. 111. Calder, Brad. “Windows Azure Blob Deep Dive”. Microsoft PDC. 2009.</li></li></ul><li>Resources – White Papers<br />Windows Azure Table – Programming Table Storage<br /><br />Windows Azure Blob – Programming Blob Storage<br /><br />Windows Azure Queue – Programming Queue Storage<br /><br />
    112. 112. Session 03:Windows Azure ApplicationsFrom Construction through Deployment<br />
    113. 113. Agenda<br />Build Web Application<br />Migrate Web Application to Windows Azure<br />Deploy to the Cloud<br />Migrate Database to SQL Server<br />Migrate SQL Database to SQL Azure<br />Deploy SQL Azure Database<br />Migrate Web Application to the Cloud<br />
    114. 114. Objective<br />Understand the process of building and deploying web applications and databases to Windows Azure and SQL Azure.<br />
    115. 115. Part 1 - Developing and Running Application From the Local DevFabric<br />Development Workstation<br />The Cloud<br />DevFabric<br />Web App<br />
    116. 116. Demo<br />Part 1 - Developing and Running Application From the Local DevFabric<br />
    117. 117. Part 2 - Deploy A Web ApplicationFrom DevFabric to Windows Azure Staging<br />Development Workstation<br />Cloud Fabric<br />Production<br />DevFabric<br />Web App<br />Web App<br />Staging<br />
    118. 118. Demo<br />Part 2 – Deploy A Web ApplicationFrom DevFabric to Windows Azure Staging Area<br />
    119. 119. Part 3 - Deploy A Web ApplicationFrom Windows Azure Staging to Production<br />Cloud Fabric<br />Production<br />Staging<br />Web App<br />Web App<br />
    120. 120. Demo<br />Part 3 – Deploy Our Windows Azure Application From The Windows Azure Staging Area into Production<br />
    121. 121. Part 4 - Developing and Running ApplicationWith SQL Server From the Local DevFabric<br />Development Workstation<br />The Cloud<br />DevFabric<br />Web App<br />SQL Database<br />
    122. 122. Demo<br />Part 4 – Developing and Running Application With SQL Server From the Local DevFabric<br />
    123. 123. Part 5 - Developing and Running ApplicationWith SQL Server From the Local DevFabric<br />Cloud Fabric<br />Development Workstation<br />Production<br />DevFabric<br />Web App<br />Staging<br />SQL Database<br />SQL Database<br />SQL Azure<br />
    124. 124. Demo<br />Part 5 - Developing and Running ApplicationWith SQL Server From the Local DevFabric<br />
    125. 125. Part 5 - Developing and Running ApplicationWith Windows Azure and SQL Azure<br />Cloud Fabric<br />Development Workstation<br />Production<br />Web App<br />DevFabric<br />Web App<br />Web App<br />Staging<br />SQL Database<br />Web App<br />SQL Database<br />SQL Azure<br />
    126. 126. Demo<br />Part 5 - Developing and Running Application With Windows Azure and SQL Azure<br />
    127. 127. Step 6 – Deploying ApplicationsWith Windows Azure and SQL Azure<br />Cloud Fabric<br />Development Workstation<br />Production<br />Web App<br />DevFabric<br />Web App<br />Web App<br />Staging<br />SQL Databases<br />Web App<br />SQL Database<br />SQL Azure<br />
    128. 128. Demo<br />Step 6 – Deploying ApplicationsWith Windows Azure and SQL Azure<br />
    129. 129. Part 7 - Deploying Updates To Applications<br />Cloud Fabric<br />Development Workstation<br />Production<br />Web App<br />DevFabric<br />Web App<br />Web App<br />Staging<br />Web App<br />SQL Database<br />SQL Azure<br />SQL Database<br />
    130. 130. Demo<br />Part 7 - Deploying Updates To Applications<br />
    131. 131. Part 8 - Revising Application Configuration<br />Cloud Fabric<br />Development Workstation<br />Production<br />Config<br />Web App<br />DevFabric<br />Web App<br />Web App<br />Staging<br />Web App<br />SQL Database<br />SQL Azure<br />SQL Database<br />
    132. 132. Demo<br />Part 8 - Revising Application Configuration<br />
    133. 133. Part 9 - Creating SQL Azure Database Users<br />Development Workstation<br />SQL Azure<br />SQL Server 2008 R2 Mgmt Studio<br />SQL Database<br />SQL Database<br />
    134. 134. Demo<br />Part 9 - Creating SQL Azure Database Users<br />
    135. 135. Resources - Deployments<br />Kerner, Mathew. “Windows Azure Diagnostics, Logging and Monitoring in the Cloud.” Microsoft PDC. 2009.<br />
    136. 136. More Information On Stuff We Wanted To Talk About But Didn’t Have Time For…<br />AppFabric<br />Smith, Justin. “REST Services Security Using the Access Control Service”. Microsoft PDC. 2009<br />
    137. 137. Q & A<br />