更新到Azure诊断:rolestatus并获取健康状态



所以我想知道Azure中RoleStatus和getHealthStatus()的更新诊断是什么?

谢谢Supraja J

From: http://msdn.microsoft.com/en-us/library/microsoft.windowsazure.serviceruntime.roleinstancestatuscheckeventargs.aspx

public override bool OnStart()
{
   RoleEnvironment.StatusCheck += RoleEnvironmentStatusCheck;
   return base.OnStart();
}
private void RoleEnvironmentStatusCheck(object sender, RoleInstanceStatusCheckEventArgs e)
{
   Trace.WriteLine("The status of the role instance: " + e.Status, "Information");
}

参见:

RoleInstanceStatusCheckEventArgs.SetBusy (): http://msdn.microsoft.com/en-us/library/microsoft.windowsazure.serviceruntime.roleinstancestatuscheckeventargs.setbusy.aspx

RoleEnvironment.RequestRecycle (): http://msdn.microsoft.com/en-us/library/microsoft.windowsazure.serviceruntime.roleenvironment.requestrecycle.aspx

最新更新