Help Center/ GaussDB/ API Reference/ APIs (Recommended)/ Parameter Configuration/ Obtaining the Differences of Two Parameter Templates
Updated on 2024-08-20 GMT+08:00

Obtaining the Differences of Two Parameter Templates

Function

This API is used to obtain the differences of two parameter templates. Before calling this API:

URI

POST https://{Endpoint}/v3/{project_id}/configurations/comparison

Table 1 Parameter description

Name

Mandatory

Description

project_id

Yes

Explanation:

Project ID of a tenant in a region.

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

Restrictions:

None

Value range:

The value can contain 32 characters. Only letters and digits are allowed.

Default value:

None

Request Parameters

Table 2 Parameter description

Name

Mandatory

Type

Description

source_id

Yes

String

ID of the source parameter template to be compared.

target_id

Yes

String

ID of the target parameter template to be compared. The deployment model of the target parameter template must be the same as that of the source parameter template.

Response Parameters

Table 3 Parameter description

Parameter

Type

Description

differences

Array of objects

Differences between parameter templates.

For details, see Table 4.

Table 4 differences field data structure description

Parameter

Type

Description

name

String

Parameter name.

source_value

String

Parameter value of the source parameter template.

target_value

String

Parameter value of the target parameter template.

Example Request

Obtaining the differences of two parameter templates
POST https://gaussdb-opengauss.ap-southeast-1.myhuaweicloud.com/v3/0483b6b16e954cb88930a360d2c4e663/configurations/comparison
{
  "source_id" : "3e9f722f27c9477089bdf576b33f9d8epr14", 
  "target_id" : "a51fcdde022a4ea8a016a3c4671644f4pr14"
}

Example Response

Differences of two parameter templates queried.
{
  "differences" : [ { 
    "name" : "audit_system_object", 
    "source_value" : "12289", 
    "target_value" : "12295" 
  } ]
}

Status Code

Error Code

For details, see Error Codes.