Help Center> GaussDB> API Reference> APIs (Recommended)> Instance Management> Querying Solution Template Settings
Updated on 2024-05-21 GMT+08:00

Querying Solution Template Settings

Function

This API is used to query the number of replicas, shards, and nodes corresponding to a specified instance or deployment mode. Before calling this API:

Constraints

The request parameters solution and instance_id cannot be both empty. If the parameters are both configured, the value of instance_id is used.

URI

GET https://{Endpoint}/v3/{project_id}/deployment-form
Table 1 Parameter description

Name

Mandatory

Description

project_id

Yes

Project ID of a tenant in a region.

For details about how to obtain the project ID, see Obtaining a Project ID.

instance_id

No

DB instance ID.

solution

No

Solution template name.

triset: HA (1 primary + 2 standby)

Request Parameters

None

Response Parameters

Table 2 Parameter description

Name

Type

Description

initial_node_num

Integer

Number of initial nodes. If solution is set to triset, this parameter is returned. Otherwise, null is returned.

solution

String

Solution template name.

shard_num

Integer

Number of shards.

replica_num

Integer

Number of replicas.

Example Request

Querying solution template settings

GET https://gaussdb-opengauss.ap-southeast-1.myhuaweicloud.com/v3/fff3cb7f644d4fc9a3c58f2bfe239b9e/deployment-form?solution=triset

Example Response

Solution template settings queried.

{ 
  "initial_node_num" : 3, 
  "solution" : "triset", 
  "shard_num" : 1, 
  "replica_num" : 3 
}

Status Code

Error Code

For details, see Error Codes.