Building a social networking portal on Windows Azure in 1 hour Saranya Sriram Developer Evangelist Microsoft, India
Over the next 60 mins We will build TechEd India 2011 Agenda Builder site and host it on Azure. We will use –ASP.NET MV3 & Razor –SQL Server DB and migrate to SQL Azure DB –Azure tables –Facebook Javascript APIs & FBML –Azure hosting
Flow of Demo Create MVC 3 App Cloud Enable the App Use Azure Table Storage Integrate Facebook API Publish to Azure Hosting
Agenda Builder App
Step 1 : Create the MVC3 App Model ADO.NET Entity Model Create Repository(Wrappers) Controller Create Session Controller Manage Routes in Global.asax Views Create cshtml views for Day 1,2 & 3 Write Razor Code
Step 2 : Enable Cloud Simulation Cloud Project Add Cloud template and link MVC App Add Azure references to MVC App SQL Azure Migrate database schema & data Manage portal settings Point application to SQL Azure Database
Step 3 : Integrate Azure Storage Model Create Azure Table Data Model Create Azure Table Data ServiceContext Create DataSource Wrapper Classes Controller Create Agenda Controller Manage CRUD operations View Create CRUD Views
Step 4 : Integrate Facebook Iframe Integrate Like, Activity Feeds into HTML using iFrame FBML Include FBML references Use Facebook Markup JavaScript API Create Facebook App to get APPID Update Site URL and Canvas URL on Facebook Wire up JavaScript Code for publishing
Step 5 : Publish to Azure DataCenter Azure Portal Create Hosted Service Create Storage Service Application Point Table Storage to Cloud Include MVC3 Setup as Startup Task Publish Configure Remote Desktop Add Certificates Publish your app to cloud
Summary All.NET Developers are cloud developers –Visual Studio (express & licensed) –WebMatrix –LighTSwitch –REST access Easy to integrate –Windows Azure runs on Windows Server 2008 R2 in data center –.NET framework –Can remote desktop Can run startup tasks and install other assemblies and components
Resources Software Application Developers Infrastructure Professionals
© 2011 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries. The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.
.NET 4 ASP.NET MVC 3 Web Matrix Razor CSHTML VBHTML Layouts A quick look at Razor