All Products
Search
Document Center

ApsaraDB for OceanBase:DescribeInstanceTopology

Last Updated:Oct 23, 2024

You can call this operation to query the topology of an OceanBase cluster.

Debugging

You can run this interface directly in OpenAPI Explorer, saving you the trouble of calculating signatures. After running successfully, OpenAPI Explorer can automatically generate SDK code samples.

Authorization information

The following table shows the authorization information corresponding to the API. The authorization information can be used in the Action policy element to grant a RAM user or RAM role the permissions to call this API operation. Description:

  • Operation: the value that you can use in the Action element to specify the operation on a resource.
  • Access level: the access level of each operation. The levels are read, write, and list.
  • Resource type: the type of the resource on which you can authorize the RAM user or the RAM role to perform the operation. Take note of the following items:
    • The required resource types are displayed in bold characters.
    • If the permissions cannot be granted at the resource level, All Resources is used in the Resource type column of the operation.
  • Condition Key: the condition key that is defined by the cloud service.
  • Associated operation: other operations that the RAM user or the RAM role must have permissions to perform to complete the operation. To complete the operation, the RAM user or the RAM role must have the permissions to perform the associated operations.
OperationAccess levelResource typeCondition keyAssociated operation
oceanbase:DescribeInstanceTopologyget
  • All Resources
    *
    none
none

Request parameters

ParameterTypeRequiredDescriptionExample
InstanceIdstringYes

The status of the node.

ob317v4uif****

Response parameters

ParameterTypeDescriptionExample
object

The information of node resources.

RequestIdstring

The information about the CPU resources of the node.

EE205C00-30E4-XXXX-XXXX-87E3A8A2AA0C
InstanceTopologyobject

The number of CPU cores used by the node.

Tenantsarray<object>

The total number of CPU cores for the node.

Tenantsobject

The information about the CPU resources of the node.

TenantIdstring

The size of used memory of the node, in GB.

t33h8y08k****
TenantNamestring

The total memory size of the node, in GB.

pay_online
TenantCpufloat

The information about the memory resources of the node.

2
TenantMemoryfloat

The total storage space of the node, in GB.

10
TenantModestring

The size of used storage space of the node, in GB.

Oracle
TenantZonesarray<object>

The information about the storage resources of the node.

TenantZonesobject

The information of node resources.

TenantZoneRolestring

The information of zones.

ReadWrite
IsPrimaryTenantZonestring

The maximum disk usage, in percentage.

true
TenantZoneIdstring

The server with the highest disk usage.

cn-hangzhou-h
Unitsarray<object>

The information about the storage resources.

Unitsobject

The resource information of the zones.

UnitIdstring

The topology of the cluster.

1002
UnitStatusstring

You can call this operation to query the topology of an OceanBase cluster.

ONLINE
NodeIdstring

It is an online CLI tool that allows you to quickly retrieve and debug APIs. It can dynamically generate executable SDK code samples.

i-bp16niirq4zdmgvm****
UnitCpufloat

Alibaba Cloud CLI

2
UnitMemoryfloat

The ID of the tenant.

10
EnableMigrateUnitboolean

The return result of the request.

true
ManualMigrateboolean

The return result of the request.

true
EnableCancelMigrateUnitboolean

Indicates whether the migration can be canceled.
This field is valid only for units that are being manually immigrated or emigrated.

true
UnitDataSizelong

The operation that you want to perform.
Set the value to DescribeInstanceTopology.

10
TenantStatusstring

The size of used memory of the node, in GB.

ONLINE
TenantDeployTypestring

The name of the tenant.

multiple
TenantUnitNuminteger

The number of CPU cores of the tenant.

1
PrimaryZoneDeployTypestring

The server with the highest disk usage.

Enumeration Value:
  • RANDOM: RANDOM.
  • STATIC: STATIC.
RANDOM
Zonesarray<object>

The information about resource units.

Zonesobject

Indicates whether the migration is manually performed.

ZoneIdstring

The information of the tenant.

cn-hangzhou-i
Regionstring

The zone information of the cluster.

cn-hangzhou
ZoneDiskstring

The information about the memory resources of the node.

200 GB
Nodesarray<object>

The ID of the region.

Nodesobject

The status of the resource unit. Valid values:

  • ONLINE: The resource unit is running.
  • IMMIGRATING: The resource unit is being immigrated.
  • EMIGRATING: The resource unit is being emigrated.
  • CANCEL_EMIGRATING: Resource node immigration is being canceled.
  • CANCEL_EMIGRATING: Resource node emigration is being canceled.
  • DELETING: The resource unit is being deleted.
NodeIdstring

The ID of the resource unit.

i-bp16niirq4zdmgvm****
NodeCopyIdlong

The information of zones.

1
NodeStatusstring

The ID of the OBServer where the resource unit resides.

ONLINE
NodeResourcearray<object>

The ID of the node.

NodeResourceobject

The topology of the cluster.

Cpuobject

The memory size of the tenant, in GB.

UsedCpufloat

Indicates whether migration can be performed.

4
TotalCpuinteger

The size of used storage space of the node, in GB.

14
Memoryobject

The role to access the zone. Valid values:

  • ReadWrite: a role that has the read and write privileges.
  • ReadOnly: a role that has only the read-only privilege.
UsedMemoryfloat

The information of node resources.

10
TotalMemorylong

The ID of the replica node.

70
DiskSizeobject

The information about the CPU resources of the node.

TotalDiskSizedouble

The deployment type of the primary zone.

400
UsedDiskSizedouble

The status of the tenant.

  • PENDING_CREATE: The tenant is being created.
  • RESTORE: The tenant is being recovered.
  • ONLINE: The tenant is running.
  • SPEC_MODIFYING: The specification of the tenant is being modified.
  • ALLOCATING_INTERNET_ADDRESS: An Internet address is being allocated.
  • PENDING_OFFLINE_INTERNET_ADDRESS: The Internet address is being disabled.
  • PRIMARY_ZONE_MODIFYING: The tenant is switching to a new primary zone.
  • PARAMETER_MODIFYING: Parameters are being modified.
  • WHITE_LIST_MODIFYING: The whitelist is being modified.
200
ZoneResourceobject

Example 1

DiskSizeobject
MaxDiskUsedPercentdouble

DescribeInstanceTopology

0.14

Examples

Sample success responses

JSONformat

{
  "RequestId": "EE205C00-30E4-XXXX-XXXX-87E3A8A2AA0C",
  "InstanceTopology": {
    "Tenants": [
      {
        "TenantId": "t33h8y08k****",
        "TenantName": "pay_online",
        "TenantCpu": 2,
        "TenantMemory": 10,
        "TenantMode": "Oracle",
        "TenantZones": [
          {
            "TenantZoneRole": "ReadWrite",
            "IsPrimaryTenantZone": "true",
            "TenantZoneId": "cn-hangzhou-h",
            "Units": [
              {
                "UnitId": "1002",
                "UnitStatus": "ONLINE",
                "NodeId": "i-bp16niirq4zdmgvm****",
                "UnitCpu": 2,
                "UnitMemory": 10,
                "EnableMigrateUnit": true,
                "ManualMigrate": true,
                "EnableCancelMigrateUnit": true,
                "UnitDataSize": 10
              }
            ]
          }
        ],
        "TenantStatus": "ONLINE",
        "TenantDeployType": "multiple",
        "TenantUnitNum": 1,
        "PrimaryZoneDeployType": "RANDOM"
      }
    ],
    "Zones": [
      {
        "ZoneId": "cn-hangzhou-i",
        "Region": "cn-hangzhou",
        "ZoneDisk": "200 GB",
        "Nodes": [
          {
            "NodeId": "i-bp16niirq4zdmgvm****",
            "NodeCopyId": 1,
            "NodeStatus": "ONLINE",
            "NodeResource": [
              {
                "Cpu": {
                  "UsedCpu": 4,
                  "TotalCpu": 14
                },
                "Memory": {
                  "UsedMemory": 10,
                  "TotalMemory": 70
                },
                "DiskSize": {
                  "TotalDiskSize": 400,
                  "UsedDiskSize": 200
                }
              }
            ]
          }
        ],
        "ZoneResource": {
          "DiskSize": {
            "MaxDiskUsedPercent": 0.14,
            "MaxDiskUsedObServer": [
              "i-bp1fhj23fs32dfbg4****"
            ]
          }
        }
      }
    ]
  }
}

Error codes

For a list of error codes, visit the Service error codes.

Change history

Change timeSummary of changesOperation
2024-07-04The response structure of the API has changedView Change Details
2024-06-06The response structure of the API has changedView Change Details
2024-04-15The response structure of the API has changedView Change Details
2023-12-26The response structure of the API has changedView Change Details
2022-09-28The response structure of the API has changedView Change Details
2021-08-19Add OperationView Change Details