Share via


List Affinity Groups

 

The List Affinity Groups operation lists the affinity groups that are associated with the specified subscription.

Request

The List Affinity Groups request may be specified as follows. Replace <subscription-id> with the subscription ID.

Method

Request URI

GET

https://management.core.windows.net/<subscription-id>/affinitygroups

URI Parameters

None.

Request Headers

The following table describes the request headers.

Request Header

Description

x-ms-version

Required. Specifies the version of the operation to use for this request. This header should be set to 2009-10-01 or higher.

Request Body

None.

Response

The response includes an HTTP status code, a set of response headers, and a response body.

Status Code

A successful operation returns status code 202 (Accepted).

Response Headers

The response for this operation includes the following headers. The response may also include additional standard HTTP headers.

Response Header

Description

x-ms-request-id

A value that uniquely identifies a request made against the management service.

Response Body

<?xml version="1.0" encoding="utf-8"?>
  <AffinityGroups xmlns="https://schemas.microsoft.com/windowsazure">
    <AffinityGroup>
      <Name>affinity-group-name</Name>
      <Label>base64-encoded-label</Label>
      <Description>description</Description>
      <Location>location</Location>  
      <Capabilities>
        <Capability>affinity-group-capability</Capability>
      </Capabilities>
      <CreatedTime>creation-time-of-affinity-group</CreatedTime>
      <ComputeCapabilities>
        <VirtualMachineRoleSizes>
          <RoleSize>role-size-name</RoleSize>
        </VirtualMachineRoleSizes>
        <WebWorkerRoleSizes>
          <RoleSize>role-size-name</RoleSize>
        </WebWorkerRoleSizes>
      </ComputeCapabilities>
    </AffinityGroup>
  </AffinityGroups>

The following table describes the elements of the response body.

Element name

Description

Name

Specifies the name of the affinity group.

Label

Specifies the base-64-encoded identifier of the affinity group.

Description

Specified the description of this affinity group.

Location

Specifies the data center in which the affinity group is located.

Capability

Specifies the capabilities that of the affinity group.

Possible values are:

  • PersistentVMRole

  • HighMemory

The capabilities of an affinity group are typically derived from its location. An affinity group may show a reduced set of capabilities if the specific set of resources assigned to support the affinity group do not support a capability, for example high-memory Virtual Machines. The PersistentVMRole capability enables an affinity group to support Virtual Machines. The HighMemory capability enables the affinity group to support Virtual Machines that use high memory relative to the number of CPUs.

CreatedTime

Specifies in UTC format when the affinity group was created.

The CreatedTime element is only available using version 2014-01-01 or higher.

ComputeCapabilities

Specifies the roles sizes that are available for deployments in the affinity group. Deployments of web roles and worker roles may have different sizes available than deployments of Virtual Machines.

The ComputeCapabilities element is only available using version 2014-05-01 or higher.

ComputeCapabilities

Specifies the roles sizes that are available for deployments in the affinity group.

Element name

Description

VirtualMachineRoleSizes

Contains a collection of RoleSize elements.

WebWorkerRoleSizes

Contains a collection of RoleSize elements.

RoleSize

Specifies the role size that is available for the type of deployment.