日期:2013-10-12  浏览次数:20494 次

Migrating to ASP .NET: Key Considerations


Jim Kieley
Microsoft Corporation
July 2001
Summary: This article explores some basic considerations for moving existing ASP applications to the ASP .NET environment as quickly and efficiently as possible. (18 printed pages)

Contents


Introduction
Compatibility Issues
Core API Changes
Structural Changes
Visual Basic Language Changes
COM-Related Changes
Application Configuration Changes
State Management
Security-Related Changes
Data Access
Preparation for ASP .NET
Summary

Introduction


Although the designers of Microsoft® ASP .NET have done an excellent job in preserving backward compatibility with ASP applications, there are a few key items you need to be aware of before undertaking the effort of moving a Web application from ASP to ASP .NET. A solid understanding of the technologies that have changed or been introduced with the .NET platform and ASP .NET will go a long way in making this process a whole lot easier.
This article explores a number of areas of change to give a clear understanding of the efforts involved in getting an ASP application up and running in the ASP .NET environment. At the same time, it points out some of the new features of ASP .NET that can be leveraged to improve an existing application. This is by no means a comprehensive look at all of the new features in ASP .NET. Instead, it focuses on areas that you need to know now for successful migration.
I am assuming that since the majority of ASP applications use Microsoft® Visual Basic® Scripting Edition (VBScript), most of you will elect to migrate to ASP .NET using Visual Basic .NET. This is obviously not a requirement, but changing languages at the same time you decide to migrate will take some additional effort and most likely will include design and architectural changes as well.

Coexistence


Before we get into discussing specific compatibility and migration issues, it is important that you understand how ASP and ASP .NET can coexist. Both ASP and ASP .NET applications can run side by side on a server without adversely affecting each other. This is primarily due to the fact that separate file extensions (.asp versus .aspx) and separate configuration models (metabase/registry versus XML-based configuration files) are used between the two technologies. The two systems have totally separate processing engines.
It is entirely possible to have part of one application running ASP and another part of the same application running ASP .NET. This is very beneficial if you need to move a large, rapidly changing site to ASP .NET one piece at a time. Some would argue that you may be better off porting and deploying the entire site all at once. This may be the case for certain classes of Web applications, but I think that there are a lot of sites out there where this may not be feasible due to the sheer size, complexity, and rapid evolution of the site's content and presentation. After all, if you are sitting on a profitable Web site, chances are the people paying the bills will not allow you to stop implementing their new features so that you can move things over to this hot new technology. Additionally, if you are going to put forth the effort to move to ASP .NET as a long-term investment, you will want to use this chance to make as many architectural and design improvements as you can. For these types of situations, coexistence using a phased-in approach is an absolute must.

Compatibility Issues


Migrating your application to ASP .NET may not be easy; however, it should not be that difficult either. ASP .NET is very much compatible with ASP. This is impressive given the fact that ASP .NET is a complete overhaul of ASP. The designers of ASP .NET had an initial goal of being 100 percent backwards compatible with ASP but subsequently had to back