following are the few important steps and tips for migrating ASP.NET
apps to Windows Azure.
- Convert the ASP.NET application into a Web Role project.
- Verify that the application is running correctly in the development environment.
- Make sure that your application is 64-bit compatible since Window azure is a 64-bit environment.
- Since Window Azure Web Roles runs on IIS7 Integrated mode, make sure that your web application does not have any issues with running on IIS 7 Integrated mode.
- If your web app is using Session, Membership, Roles and Profile data, you have to find a way to make the state information is working with Windows Azure environment. You can use ASP.NET Universal Providers for handling Session, Membership, Roles and Profile which will be working with Sql Azure. The Windows Azure Caching Service is also providing a provider for ASP.NET Session state which will be faster than working with Sql Azure, but will be bit expensive than using Sql Azure.
- If you are using ASP.NET caching, it would be recommended to use The Windows Azure Caching Service. The Windows Azure Caching Service is the better way to use Caching in Windows Azure.
- Upload and save files to BLOB storage, if your web application is dealing with documents, media files, etc.
- If your application is using any Windows services or using any background processing, migrate these services to Worker Roles.
- Put messages to Windows Azure storage Queue or Service Bus Queue if you want to communicate between Web Role and Worker Role.
- If you want to make federated claims-based authentication and single sign-on, you can use Windows Azure Access Control Service (ACS) that enables federated authentication. It will work with external identity providers such as Windows Live, Google, Facebook, and Open ID and you can also able to define service identities in ACS that lets you to authenticate without using an external identity provider.
- Use startup tasks if you want to perform operations and install components before your Azure Role starts on Virtual Server. You can add startup tasks by editing the ServiceDefinition.csdef file.
- Consider moving out some configuration settings in web.config files to ServiceConfiguration.cscfg so that you do not require redeployment after every change in configuration. Data in the ServiceConfiguration.cscfg file can be edited at runtime.
- The Windows Azure environment does not provide a SMTP relay or mail relay service. So if your application is using e-mail services, it would be recommended to use a third party service (like SendGrid or AuthSMTP) to send email from inside Windows Azure.
- If you are using Sql Azure, use a SQL Server 2008 R2 client so that you can easily migrate database schema and data into Sql Azure. And you can connect the Sql Azure from the SQL Server 2008 R2 client.