Windows Azure and ASP.NET MVC Migration
Buy Rights Online Buy Rights

Rights Contact Login For More Details

More About This Title Windows Azure and ASP.NET MVC Migration

English

Practical, real-world tools for migrating ASP.NET MVC to Windows Azure

When IIS6 and Windows Server 2003 are no longer supported, you?ll need to migrate websites currently hosted on these technologies to newer technologies. This book comes to the rescue. It's packed with all the steps you need - all intertwined with real-world examples - to perform the migration of IIS6 and Windows Server 2003 websites to Windows Azure.

Discusses different aspects of performance and scalability such as pipeline optimization, process model configuration, caching, minification, and bundlingShares an overview of the Windows Azure Cloud Service and the benefits it has over legacy configurationsLooks at Windows Azure deployment features, provides steps for getting access to Windows Azure, and explains how to create the components necessary to host and successfully run a test website

Windows Azure and ASP.NET MVC Migration is a must-have resource for making the transition to Windows Azure as smooth and successful as possible.

English

Introduction to the Windows Azure Book Series xiii

Introduction xv

Part I: Migration 1

CHAPTER 1: Migrating from AS P.NET to AS P.NET MVC 4 2

Getting Started 3

Comparing ASP.NET to ASP.NET MVC 3

Understanding the Model-View-Controller 6

Using Master Pages versus Shared Views 7

When to Use User Controls versus Partial Views 8

Understanding the Statelessness of ASP.NET MVC 8

Understanding Strongly Typed Class References 9

ASP.NET, ASP.NET MVC, or Both? 9

What Are the Differences Between ADO.NET and NHibernate? 10

Understanding the Data Access Layer 10

Understanding the Object Relational Mapping 12

Understanding Mapping by Code 14

Accessing Data from the Database 15

Examining Innovations from IIS 6 to IIS 7.0/7.5/8 16

Introducing Team Foundation Server 19

Using Test Driven Development Within ASP.NET MVC 22

Summary 24

CHAPTER 2: Creating the AS P.NET MVC 4 Project 25

Changing the Look and Feel of Your Website 26

Creating the Blog List from an XML RSS File 29

Adding the BlogList Class to the Models Directory 30

Adding Methods to the HomeControllers File 31

Modifying the Index() Method 33

Displaying the List of Blogs in the View 34

Adding the Html.ActionLinks 35

Creating a Local Test Database 38

Downloading and Installing SQL Server 38

Creating a New SQL Server Database 39

Implementing NHibernate into an ASP.NET MVC 4 Application 40

Creating the NHibernate Classes and Configuration 42

Creating and Adding the BlogNavBar Partial View 49

Adding a Partial View 49

Adding Static Content to the View 50

Creating a Sample View and Adding the _BlogNavBar 50

Adding Dynamic Content to the _BlogNavBar Partial View 52

Creating the Archive List Web Page 59

Creating the ArchiveList.cshtml View 59

Adding the ArchiveList() Action Result Method 60

Create and Implement a Custom MapRoute 60

Retrieving the Archive Blog Data with LINQ to NHibernate 61

Modifying the Views to Display and Link to Data 63

Migrate a Blog Entry from ASP.NET with Feedback Form and Comment List 64

Adding a Controller to Manage Requests to All Blogs 65

Creating a Method to Retrieve Blog Details 65

Updating the Example Blog Link 66

Creating a Shared Partial View for the Blog 67

Adding Partial View to the Blog 68

Summary 68

Part II: Enhancing 70

CHAPTER 3: Understanding AS P.NET MVC 4 Performance Optimization Tech niques 71

Setting a Performance Baseline 72

Using Online Tools for Performance Testing and Optimization Tips 73

Understanding Bundling and Minification 74

Scaling a Windows Azure Cloud Service 77

Fifteen Performance Enhancing Tips 79

Useful Links 81

Summary 82

CHAPTER 4: Fine-tuning the AS P.NET MVC 4 Project for Performance 83

Using Fiddler to Capture Performance Statistics 84

Implementing MiniProfiler 88

Implementing into ASP.NET Website 89

Implementing into the ASP.NET MVC 4 Web Role 95

Capturing Performance Data with IE F12 Developer Tools 99

Employing Google PageSpeed — ASP.NET Website 100

Leveraging Browser Caching 101

Enabling Compression 102

Serve Scaled Images 103

Optimizing Images 104

Bundling and Minifying JavaScript and CSS 106

Understanding the Impact of Bundling and Minifying Files 107

Implementing Bundling 107

Implementing Minification 108

Configuring Compression and Caching 110

Implementing Compression 110

Changing the Output Caching 113

Comparing ASP.NET MVC 4 Performance After Tuning 115

Summary 117

Part III: Deployment 118

CHAPTER 5: Di scu ssing AS P.NET MVC 4 Windows Azure
Deployment Tech niques 119

Preparing Your Application for the Windows Azure Platform 120

Straightforward Implementation 120

Scalability, Availability, and Durability 120

Releasing Internal Resources 120

Quality Support/Experienced Practitioners 121

Mobility 121

Reduced Cost 121

Understanding Developer Centers and Supported SDKs 121

Introducing Cloud Computing Services 122

Understanding Cloud Computing Service Models 123

Understanding Deployment Models 124

Understanding Private and Public Clouds 125

Understanding a Community Cloud 127

Understanding a Hybrid Cloud 128

Accessing the Windows Azure Platform 128

Choosing Your Windows Azure Services 131

Using Azure Web Site versus Cloud versus Virtual Machine 131

Understanding Data Storage Features 132

What is Windows Azure SQL Reporting? 133

What is HDInsight? 133

Using Active Directory 133

Understanding Deployment Options 134

Integrating Source Control with a Cloud Service 134

Integrating Source Control with an Azure Web Site 135

Deploying Web Roles 138

Planning Database Migration and Storage 140

Monitoring the Status of a Deployment 141

Summary 143

CHAPTER 6: Deploying an AS P.NET MVC 4 Project to Windows Azure 144

Accessing Windows Azure 145

Creating the Window Azure Web Site and Cloud Service 146

Creating a Website 146

Creating a Cloud Service 148

Adding and Connecting a SQL Database 150

Adding a SQL Server Database 150

Connecting to the Database 153

Deploying and Testing Your Code 156

Converting an ASP.NET MVC 4 Project to a Cloud Service 157

Deploying with Visual Studio Publishing Features 162

Setting a TFS Connection and Publishing the ASP.NET MVC 4 Website 170

Accessing the Team Foundation Server 170

Adding Links between TFS and Windows Azure 175

Connecting a Windows Azure Web Site to a GitHub Code Repository 178

Publishing an ASP.NET MVC 4 Website Using FTP 182

Setting Up FTP Capability 183

Publishing the Project 184

Summary 184

Part IV: Monitoring and T roubleshooting 185

CHAPTER 7: Maintaining an AS P.NET MVC 4 Deployment on Windows A zure 186

Monitoring a Windows Azure Web Site 187

Monitoring with the Dashboard 187

Monitoring with the Website’s Management Console 188

Monitoring a Windows Azure Cloud Service 191

Using the Task Manager and Event Viewer 191

Using IIS and PowerShell 191

Using the Cloud Service Management Console 192

Configure a Cloud Service from Visual Studio 196

Monitor a Cloud Service from within Visual Studio 198

Management and Monitoring Tools for Windows Azure 199

Open Source Tools 199

Windows Azure Management API 200

Windows Azure PowerShell Cmdlets 201

Microsoft Tools for Monitoring and Managing Windows Azure 202

Summary 203

CHAPTER 8: M onitoring and S upp orting an AS P.NET  MVC 4 Project on Windows Azure 204

Monitoring and Supporting an ASP.NET MVC 4 Web site on Windows Azure 204

Accessing the Graph and Usage Overview 205

Adding Metrics to the List of Monitored Attributes 206

Configuring Diagnostics for the Website 207

Downloading and Analyzing Diagnostic Logs 210

Streaming Diagnostic Logs 213

Monitoring and Supporting an ASP.NET MVC 4 Cloud Service on Windows Azure 216

Updating Diagnostic Settings on a Live Service 216

Configuring a Remote Desktop Connection 218

Setting Up a Remote Desktop Connection for an Existing Cloud Service 224

Viewing the Cloud Service Usage Dashboard 237

Summary 241

loading