Help Center/ Distributed Cache Service/ API Reference/ API V2/ Parameter Management/ Querying DCS Instance Configuration Parameters
Updated on 2025-05-13 GMT+08:00

Querying DCS Instance Configuration Parameters

Function

This API is used to query the configuration parameters of a DCS instance.

Calling Method

For details, see Calling APIs.

URI

GET /v2/{project_id}/instances/{instance_id}/configs

Table 1 Path Parameters

Parameter

Mandatory

Type

Description

instance_id

Yes

String

Parameter description:

Instance ID. It can be viewed on the instance details page on the DCS console.

Constraints:

N/A.

Value range:

N/A.

Default value:

N/A.

project_id

Yes

String

Parameter description:

Project ID. For details, see Obtaining a Project ID.

Constraints:

N/A.

Value range:

N/A.

Default value:

N/A.

Request Parameters

None

Response Parameters

Status code: 200

Table 2 Response body parameters

Parameter

Type

Description

config_time

String

Parameter description:

Time when the instance was operated on. For example, 2017-03-31T12:24:46.297Z.

Value range:

N/A.

instance_id

String

Parameter description:

Instance ID.

Value range:

N/A.

redis_config

Array of QueryRedisConfig objects

Parameter description:

Array of configuration items of the instance.

Value range:

N/A.

config_status

String

Parameter description:

Instance status that is being modified or has been modified.

Value range:

  • UPDATING: The modification is in progress.

  • FAILURE: The modification failed.

  • SUCCESS: The modification succeeded.

status

String

Parameter description:

Instance status.

Value range:

  • PAYING: The order has not been paid or is being processed.

  • CREATING: The DCS instance is being created.

  • RUNNING: The DCS instance is running.

  • CLOSING: The DCS instance is stopping.

  • STARTING: The DCS instance is starting.

  • RESTARTING: The DCS instance is restarting.

  • CLOSED: The DCS instance has stopped.

  • DELETING: The DCS instance is being deleted.

  • DELETED: The DCS instance has been deleted.

  • ERROR: The DCS instance is not running properly.

  • FAILURE: The DCS instance fails to be configured.

  • SUCCESS: The DCS instance is successfully configured.

  • CREATEFAILED: The DCS instance fails to be created.

  • DELETEFAILED: The DCS instance fails to be deleted.

  • FREEZING: The instance is frozen.

  • EXTENDING: The DCS instance's capacity is being increased.

  • EXTENDEDFAILED: The instance's capacity fails to be increased.

  • MIGRATING: The DCS instance is migrating data.

  • OTHER: other status.

  • FLUSHING: The instance data is being cleared.

  • RESTORING: The backup data is being restored.

  • UPGRADING: The instance software is being upgraded.

  • IPEXCHANGING: IP switch is in progress.

  • IPROLLBACKING: IP addresses are being rolled back.

  • MS_SWAPPING: The master/standby switchover is in progress.

  • AZMigrating: The AZ is being migrated.

Table 3 QueryRedisConfig

Parameter

Type

Description

param_value

String

Parameter description:

Configuration parameter value.

Value range:

N/A.

value_type

String

Parameter description:

Type of the configuration parameter value. For example, Integer and String.

Value range:

N/A.

value_range

String

Parameter description:

Range of the configuration parameter value.

Value range:

N/A.

description

String

Parameter description:

Description of the configuration item.

Value range:

N/A.

default_value

String

Parameter description:

Default value of the configuration parameter.

Value range:

N/A.

param_name

String

Parameter description:

Configuration parameter name.

Value range:

N/A.

param_id

String

Parameter description:

Configuration parameter ID.

Value range:

N/A.

Status code: 400

Table 4 Response body parameters

Parameter

Type

Description

error_msg

String

Parameter description:

Error message.

Value range:

N/A.

error_code

String

Parameter description:

Error code.

Value range:

For details, see Error Codes.

error_ext_msg

String

Parameter description:

Extended error information. This parameter is not used currently and is set to null.

Value range:

N/A.

Status code: 500

Table 5 Response body parameters

Parameter

Type

Description

error_msg

String

Parameter description:

Error message.

Value range:

N/A.

error_code

String

Parameter description:

Error code.

Value range:

For details, see Error Codes.

error_ext_msg

String

Parameter description:

Extended error information. This parameter is not used currently and is set to null.

Value range:

N/A.

Example Requests

GET https://{dcs_endpoint}/v2/{project_id}/instances/{instance_id}/configs

Example Responses

Status code: 200

Instance configuration parameters queried successfully.

{
  "instance_id" : "50829e5a-a4fc-4c01-8651-80be8a491602",
  "config_status" : "SUCCESS",
  "config_time" : "2020-07-06T07:04:31.464Z",
  "redis_config" : [ {
    "param_id" : "1",
    "param_name" : "timeout",
    "description" : "Close the connection after a client is idle for N seconds (0 to disable)",
    "param_value" : "101",
    "value_range" : "0-7200",
    "value_type" : "Interger",
    "default_value" : "0"
  } ],
  "status" : "RUNNING"
}

Status Codes

Status Code

Description

200

Instance configuration parameters queried successfully.

400

Invalid request.

500

Internal service error.

Error Codes

See Error Codes.