Compute
Elastic Cloud Server
Huawei Cloud Flexus
Bare Metal Server
Auto Scaling
Image Management Service
Dedicated Host
FunctionGraph
Cloud Phone Host
Huawei Cloud EulerOS
Networking
Virtual Private Cloud
Elastic IP
Elastic Load Balance
NAT Gateway
Direct Connect
Virtual Private Network
VPC Endpoint
Cloud Connect
Enterprise Router
Enterprise Switch
Global Accelerator
Management & Governance
Cloud Eye
Identity and Access Management
Cloud Trace Service
Resource Formation Service
Tag Management Service
Log Tank Service
Config
OneAccess
Resource Access Manager
Simple Message Notification
Application Performance Management
Application Operations Management
Organizations
Optimization Advisor
IAM Identity Center
Cloud Operations Center
Resource Governance Center
Migration
Server Migration Service
Object Storage Migration Service
Cloud Data Migration
Migration Center
Cloud Ecosystem
KooGallery
Partner Center
User Support
My Account
Billing Center
Cost Center
Resource Center
Enterprise Management
Service Tickets
HUAWEI CLOUD (International) FAQs
ICP Filing
Support Plans
My Credentials
Customer Operation Capabilities
Partner Support Plans
Professional Services
Analytics
MapReduce Service
Data Lake Insight
CloudTable Service
Cloud Search Service
Data Lake Visualization
Data Ingestion Service
GaussDB(DWS)
DataArts Studio
Data Lake Factory
DataArts Lake Formation
IoT
IoT Device Access
Others
Product Pricing Details
System Permissions
Console Quick Start
Common FAQs
Instructions for Associating with a HUAWEI CLOUD Partner
Message Center
Security & Compliance
Security Technologies and Applications
Web Application Firewall
Host Security Service
Cloud Firewall
SecMaster
Anti-DDoS Service
Data Encryption Workshop
Database Security Service
Cloud Bastion Host
Data Security Center
Cloud Certificate Manager
Edge Security
Situation Awareness
Managed Threat Detection
Blockchain
Blockchain Service
Web3 Node Engine Service
Media Services
Media Processing Center
Video On Demand
Live
SparkRTC
MetaStudio
Storage
Object Storage Service
Elastic Volume Service
Cloud Backup and Recovery
Storage Disaster Recovery Service
Scalable File Service Turbo
Scalable File Service
Volume Backup Service
Cloud Server Backup Service
Data Express Service
Dedicated Distributed Storage Service
Containers
Cloud Container Engine
SoftWare Repository for Container
Application Service Mesh
Ubiquitous Cloud Native Service
Cloud Container Instance
Databases
Relational Database Service
Document Database Service
Data Admin Service
Data Replication Service
GeminiDB
GaussDB
Distributed Database Middleware
Database and Application Migration UGO
TaurusDB
Middleware
Distributed Cache Service
API Gateway
Distributed Message Service for Kafka
Distributed Message Service for RabbitMQ
Distributed Message Service for RocketMQ
Cloud Service Engine
Multi-Site High Availability Service
EventGrid
Dedicated Cloud
Dedicated Computing Cluster
Business Applications
Workspace
ROMA Connect
Message & SMS
Domain Name Service
Edge Data Center Management
Meeting
AI
Face Recognition Service
Graph Engine Service
Content Moderation
Image Recognition
Optical Character Recognition
ModelArts
ImageSearch
Conversational Bot Service
Speech Interaction Service
Huawei HiLens
Video Intelligent Analysis Service
Developer Tools
SDK Developer Guide
API Request Signing Guide
Terraform
Koo Command Line Interface
Content Delivery & Edge Computing
Content Delivery Network
Intelligent EdgeFabric
CloudPond
Intelligent EdgeCloud
Solutions
SAP Cloud
High Performance Computing
Developer Services
ServiceStage
CodeArts
CodeArts PerfTest
CodeArts Req
CodeArts Pipeline
CodeArts Build
CodeArts Deploy
CodeArts Artifact
CodeArts TestPlan
CodeArts Check
CodeArts Repo
Cloud Application Engine
MacroVerse aPaaS
KooMessage
KooPhone
KooDrive

Querying All DCS Instances of a Tenant

Updated on 2022-02-21 GMT+08:00

Function

This API is used to query DCS instances of a tenant, and allows you to specify query criteria.

URI

GET /v1.0/{project_id}/instances?start={start}&limit={limit}&name={name}&status={status}&id={id}&includeFailure={includeFailure}&isExactMatchName={isExactMatchName}

Table 1 describes the parameters.
Table 1 Parameter description

Parameter

Type

Mandatory

Description

project_id

String

Yes

Project ID.

start

Integer

No

Start number for querying DCS instances. It cannot be lower than 1.

By default, the start number is 1.

limit

Integer

No

Number of DCS instances displayed on each page.

Minimum value: 1

Maximum value: 2000

If this parameter is left unspecified, a maximum of 1000 DCS instances are displayed on each page.

name

String

No

DCS instance name.

id

String

No

Instance ID.

status

String

No

DCS instance status. For details about status, see DCS Instance Statuses.

includeFailure

String

No

An indicator of whether the number of DCS instances that failed to be created will be returned to the API caller.

Options:

  • true: The number of DCS instances that failed to be created will be returned to the API caller.
  • false or others: The number of DCS instances that failed to be created will not be returned to the API caller.

isExactMatchName

String

No

An indicator of whether to perform an exact or fuzzy match based on instance name.

Options:

  • true: exact match
  • false: fuzzy match

Default value: false.

Example

GET https://{dcs_endpoint}/v1.0/bd6b78e2ff9e4e47bc260803ddcc7a21/instances?start=1&limit=10&name=&status=&id=&includeFailure=true&isExactMatchName=false  

Request

Request parameters

None

Example request

None

Response

Response parameters

Table 2 describes the response parameters.
Table 2 Parameter description

Parameter

Type

Description

instances

Array

Array of DCS instance details.

instance_num

Integer

Number of DCS instances.

Table 3 Parameter description of the instance array

Parameter

Type

Description

name

String

DCS instance name.

engine

String

Cache engine.

capacity

Integer

Cache capacity.

Unit: GB.

ip

String

IP address for connecting to the DCS instance For a cluster instance, multiple IP addresses are returned and separated by commas (,). For example, 192.168.0.1,192.168.0.2.

port

Integer

Port number of the cache node.

status

String

Cache instance status. For details about status, see DCS Instance Statuses.

max_memory

Integer

Overall memory size.

Unit: MB.

used_memory

Integer

Size of the used memory.

Unit: MB.

instance_id

String

DCS instance ID.

engine_version

String

Cache engine version.

internal_version

String

Internal DCS version.

charging_mode

Integer

Billing mode. 0: pay-per-use.

capacity_minor

String

Small-scale cache capacity. Unit: GB.

vpc_id

String

VPC ID.

vpc_name

String

VPC name.

created_at

String

Time at which the DCS instance is created. For example, 2017-03-31T12:24:46.297Z.

error_code

String

Error code returned when the DCS instance fails to be created or is abnormal. For details about error codes, see Error Codes.

user_id

String

User ID.

user_name

String

Username.

maintain_begin

String

Time at which the maintenance time window starts. Format: HH:mm:ss.

maintain_end

String

Time at which the maintenance time window ends. Format: HH:mm:ss.

security_group_id

String

Security group name.

Example response

{
    "instances": [
        {           
            "name": "dcs-lxy",            
            "engine": "Redis",
            "capacity": 4,
            "ip": "192.168.7.146",
           
            "port": 6379,
            "status": "CREATING",
            "max_memory": 3277,
            "used_memory": 0,
            "instance_id": "a4d31cb6-3d72-4fdc-8ec9-6e3a41e47f71",
             "resource_spec_code": "dcs.master_standby",
            "engine_version": "3.0",
            "internal_version": null,
            "charging_mode": 0,          
            "capacity_minor": null,
            "vpc_id": "c71d9731-9b0c-43e9-ab2a-716af9d9fd55",
            "vpc_name": "CCE-AutoCreate-VPC-7qvs1",       
            "created_at": "2019-09-23T02:40:06.123Z",
            "error_code": null,
            "user_id": "50a4156d334a4a82b8745dc730dc1e00",
            "user_name": "hwstaff_f00443635",
            "maintain_begin": "02:00:00",
            "maintain_end": "06:00:00",
            "security_group_id": "0cc8fdb7-872a-49da-a062-88ccc39463b5"
        }],
    "instance_num": 1
}

Status Code

Table 4 describes the status code of successful operations. For details about other status codes, see Table 1.

Table 4 Status code

Status Code

Description

200

All DCS instances of the tenant queried successfully.

We use cookies to improve our site and your experience. By continuing to browse our site you accept our cookie policy. Find out more

Feedback

Feedback

Feedback

0/500

Selected Content

Submit selected content with the feedback