Windows Azure - 将 .NET Web 应用程序传输到 Azure [英] Windows Azure - Transferring .NET Web Application to Azure

查看:16
本文介绍了Windows Azure - 将 .NET Web 应用程序传输到 Azure的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我希望有人能回答一些关于 Windows Azure 的简短问题.我知道这有点懒惰,但是涵盖 Azure 的 Microsoft 网站似乎是针对半技术项目负责人并且充满了业务指标——它们似乎从来没有真正对如何"给出一个很好的简短概述.

I was hoping someone could answer some brief questions on windows Azure. I know this is a bit lazy, but the Microsoft websites covering Azure seem to be directed at semi technical project leads and full of business metrics - they never really seem to give a good short overview of the 'how'.

我有一个 ASP.NET Web 应用程序,它需要一些工作来协助扩展(其中有一些蜘蛛类型的进程和一个相当大的数据库.它还会多次调用外部 Web 服务).

I have an ASP.NET web application that requires some work to assist with scale (there's some spider type processes in there and a pretty large database. It also makes many calls to outside web services).

我的问题是:

  1. 从开发的角度来看 - 将应用程序从标准 iis/sql 服务器类型设置移植到 Azure 是多么容易.是否涉及很多编码.我已经开始制作一个培训视频,让您对结构"等进行编程.将应用程序转换为 Azure 真的可行吗?

  1. From a development point of view - how easy is it to port an application from standard iis / sql server type set up to Azure. Is there much coding involved. I've gone as far as starting a training video that has you programming the 'fabric' etc. Is it really practical to convert an application to Azure?

我听说您可以在 Azure 中运行 Windows Server 2008 R2 实例 - 这是否意味着您不必使用 Azure 特定的 SDK 进行编程,只需将您的 iis/sql 服务器设置为azure 并立即利用可扩展性的优势?

I've heard that you can run Windows Server 2008 R2 instances in Azure - does this mean you don't necessarily have to program with Azure specific SDK, and can just move your iis / sql server set up to azure and utilise benefits of scalablility immediately?

推荐答案

您提到了几个要点:培训、移植、扩展和虚拟机管理.

You hit on several points: training, porting, scaling, and virtual machine management.

培训

您可能应该在 MSDev.Windows Azure 2010 秋季版"系列是最新的.请注意,要在 Azure 中运行应用,您需要了解 Azure Fabric 和相关服务,例如诊断和角色管理.

You should probably look at some of the intro videos at MSDev. The "Windows Azure Fall 2010" series are the latest ones. Note that, to run an app in Azure, you need to understand the Azure Fabric and related services such as diagnostics and role management.

移植

您需要了解您在 asp.net 核心之外所做的工作,例如缓存、会话状态管理、安全性、第 3 方 DLL、COM、注册表访问以及任何其他管理员级别的功能.今天,使用 SDK 1.2,您将无法操作注册表或运行 MSI.我有一个 相关 StackOverflow 帖子 关于一些您可能会遇到挑战的领域.关于 SQL Azure:某些功能(例如 CLR 支持)未实现,您将无法访问某些系统级功能.可以在 SQL Azure 站点.

You'll need to look at what you're doing beyond core asp.net, such as caching, session state management, security, 3rd-party DLLs, COM, registry access, and any other admin-level functions. Today, with SDK 1.2, you won't have the ability to manipulate the registry or run an MSI. I have a related StackOverflow post about some of the areas where you might run into challenges. Regarding SQL Azure: Some features, such as CLR support, are not implemented, and you won't have access to some system-level features. Details about differences can be found in a whitepaper on the SQL Azure site.

借助 PDC 2010 推出的新功能,您应该能够克服几乎所有这些问题:

With the new features introduced at PDC 2010, you should be able to overcome nearly all of these issues:

  • 会话状态可以托管在AppFabric 缓存.这将只是对您的配置进行更改配置.此缓存将可用在您部署的所有网络中实例,让您可以扩展.
  • 管理员模式下提供管理员级别的访问权限.你将能够在您的角色实例启动时运行 MSI 并修改注册表等内容.

缩放

您需要仔细查看您的应用如何处理缩放.例如:如果所有服务器实例尝试同时使用相同的资源,您可能会遇到瓶颈,从而导致锁定.一种常见的 Azure 模式是将工作项放置在持久的 Azure 队列中,并让后台工作人员角色实例异步使用这些工作项.

You'll need to look closely at how your app handles scaling. For example: you might have a bottleneck if all server instances attempt to work simultaneously with the same resource, causing locks. A common Azure pattern is to place work items in a durable Azure Queue and have background worker role instances consume these work items asynchronously.

今天,Azure 不提供开箱即用的会话状态管理功能(例如,将状态存储在 SQL Server 中).但是,有一个 可下载示例 在 SQL Azure 博客上,它与 SQL Azure 配合得很好.如上所述,新的 AppFabric 缓存功能将提供会话状态管理,因此您很快就会拥有一个开箱即用的解决方案.

Today, Azure doesn't provide an out-of-the-box session state management ability (e.g. storing state in SQL Server). However, there's a downloadable sample on the SQL Azure Blog that works great with SQL Azure. As mentioned above, the new AppFabric Cache feature will provide session state management, so you will soon have an out-of-the-box solution.

虚拟机管理

在 PDC 上宣布了 VM 角色.从本质上讲,这将使您能够获取本地构建的 Windows Server 2008 R2 映像并将其移动到 Azure.您需要安装 Azure 扩展,以允许由 Azure 结构管理映像.

VM Role was announced at PDC. In essence, this will provide you the ability to take a Windows Server 2008 R2 image, built locally, and move it to Azure. You'll need to install Azure extensions that allow the image to be managed by the Azure fabric.

但有一个权衡:您的虚拟机不会从操作系统升级和补丁中受益:您将负责管理这些(通过差异磁盘).Azure 结构仍将监视 VM 的运行状况,并在必要时重新启动或移动它.我建议您首先尝试使用管理员模式,这样您仍然可以 100% 使用 Azure 的服务.

There is a tradeoff though: Your VM won't benefit from OS upgrades and patches: You'll be responsible for managing these (via differencing disk). The Azure fabric will still monitor your VM's health, and reboot it or move it if necessary. I would recommend first attempting to utilize Admin Mode, so you can still take advantage of 100% of Azure's services.

这篇关于Windows Azure - 将 .NET Web 应用程序传输到 Azure的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆