RoleInstanceEndpoint Class

 

Updated: May 29, 2012

Represents an endpoint that is associated with a role instance.

Namespace:   Microsoft.WindowsAzure.ServiceRuntime
Assembly:  Microsoft.WindowsAzure.ServiceRuntime (in Microsoft.WindowsAzure.ServiceRuntime.dll)

System::Object
  Microsoft.WindowsAzure.ServiceRuntime::RoleInstanceEndpoint

public ref class RoleInstanceEndpoint abstract 

NameDescription
System_CAPS_pubpropertyIPEndpoint

Gets an IPEndPoint object for the role instance endpoint. The IPEndPoint object provides the IP address and port number for the endpoint.

System_CAPS_pubpropertyProtocol

Gets the protocol that is defined for the endpoint.

System_CAPS_pubpropertyPublicIPEndpoint

Gets an IPEndPoint object for the role instance endpoint. The IPEndPoint object provides the port number for the direct port endpoint. The IP address in the property is unused.

System_CAPS_pubpropertyRoleInstance

Gets the RoleInstance object that is associated with an endpoint.

NameDescription
System_CAPS_pubmethodEquals(Object^)

(Inherited from Object.)

System_CAPS_protmethodFinalize()

(Inherited from Object.)

System_CAPS_pubmethodGetHashCode()

(Inherited from Object.)

System_CAPS_pubmethodGetType()

(Inherited from Object.)

System_CAPS_protmethodMemberwiseClone()

(Inherited from Object.)

System_CAPS_pubmethodToString()

(Inherited from Object.)

Endpoints are used by role instances to communicate externally (InputEndpoint) with other applications and internally (InternalEndpoint) with other role instances. Endpoints are defined in the service model for the hosted service. For more information about defining endpoints, see Enabling Communication for Role Instances in Windows Azure and Azure Service Definition Schema (.csdef File).

The following code example shows how to retrieve endpoint information from role instances:


foreach (var role in RoleEnvironment.Roles)
{
   foreach (var roleInst in role.Value.Instances)
   {
      foreach (RoleInstanceEndpoint instanceEndpoint in roleInst.InstanceEndpoints.Values)
      {
         Trace.WriteLine("Instance endpoint IP address and port:" + instanceEndpoint.IPEndpoint, "Information");
      }
   }
}

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

Return to top
Show: