Azure Web 角色和虚拟机持久性

Azure web roles and vm durability

假设我们扩展了 RoleEntryPoint class 并覆盖了 Run() 方法。正如文档所述,

If the Run method returns, the role is automatically recycled by raising the Stopping event and calling the OnStop method so that your shutdown sequences may be executed before the role is taken offline.

我对此有一些疑问

  1. 如果覆盖 运行() 方法 returns,vm 实例会发生什么情况? (vm是被Azure回收还是shutdown)
  2. webrole是分配给专用vm实例还是共享vm实例?
  3. 用于 web 的 vms 或 worker 角色是以临时方式创建的,还是回收了之前创建和使用的实例? (在这种情况下,我们可以期望旧的注册表项可用吗?)

What happens to the vm instance if overrode Run() method returns? (Is the vm reclaimed by Azure or shutdown)

在这种情况下,您的虚拟机实例将重新启动。

Is a webrole allocated to a dedicated vm instance or a shared vm instance?

您将获得一个基于您选择的大小的专用虚拟机实例。

Are vms used for web or worker roles are created in an adhoc manner or recycled instances which were created and used earlier? (In this case can we expect old registry key entries are available?)

创建新部署时,您将获得全新的虚拟机,即从头开始创建。因此,您不能期望旧的注册表项可用。