Runs code that is intended to be run for the life of the role instance.
Microsoft.WindowsAzure.ServiceRuntime (in Microsoft.WindowsAzure.ServiceRuntime.dll)
Public Overridable Sub Run
The Run is considered the Main method for your application. Overriding the Run method is not required; the default implementation never returns. If you do override the Run method, your code should block indefinitely. 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.
Override the Run method to run code for the life of the role instance. The following code example shows how to override the Run method:
No code example is currently available or this language may not be supported.
For more information about life cycle management, see Overview of Building an Application that Runs in a Hosted Service.
Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.
Windows Vista, Windows 7 and Windows Server 2008