Modifies the configuration information of a cluster.
Operation description
Request syntax
PUT /openapi/ha3/instances/{instanceId}/cluster-offline-config
Try it now
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
searchengine:ModifyClusterOfflineConfig |
update |
*Instance
|
None | None |
Request syntax
PUT /openapi/ha3/instances/{instanceId}/cluster-offline-config HTTP/1.1
Path Parameters
|
Parameter |
Type |
Required |
Description |
Example |
| instanceId |
string |
Yes |
The instance ID. |
ha-cn-pl32rf0**** |
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| body |
object |
No |
The request body. |
{} |
| dataSourceName |
string |
No |
The name of the data source. |
ha-cn-pl32rf0****_test_api |
| dataSourceType |
string |
No |
The type of the data source. Valid values: odps: MaxCompute. swift: Swift. unKnow: unknown type. |
odps |
| domain |
string |
No |
The data center in which the data source is deployed. |
vpc_hz_domain_1 |
| config |
object |
No |
The configuration name, which is stored as a key. |
|
|
integer |
No |
The configuration version, which is stored as a value. |
1 |
|
| partition |
string |
No |
This parameter is required when index building for full data in a MaxCompute data source is triggered. |
ds=20211202 |
| dataTimeSec |
integer |
No |
This parameter is required when index building by using API data sources is triggered. |
1640867288 |
| buildMode |
string |
No |
The reindexing method. Valid values: api: API data source. indexRecover: data recovery by using indexing. |
indexRecover |
| generation |
integer |
No |
The ID of the full index version. |
160142641 |
| pushMode |
string |
No |
The push mode of the configuration. By default, only the configuration is pushed. |
PUSH_ONLY |
| Parameter | Required | Type | Description |
| dataSource | Yes | String | The name of the data source. |
| domain | Yes | String | The domain where the data source is deployed. |
| indexes | Yes | Object | The description of the index structure. |
| advancedConfigVersionId | Yes | Integer | The ID of the advanced configuration version. |
| triggerBuild | Yes | boolean | If this parameter is set to true, the configuration is pushed and reindexing is triggered. If this parameter is set to false, the configuration takes effect after the next reindexing. |
| buildMode | No | Integer | The mode of reindexing. api indicates the default mode, and indexRecover indicates that the data source is restored by using the index. This parameter is required only when the data source is of the HDFS type. |
| generation | No | Long | The data restoration version. |
| partition | No | String | The data partition of the data source selected for reindexing. This parameter is required when reindexing is triggered for the odps data source. |
| dataTimeSec | No | Integer | The time when reindexing is triggered for the API-pushed data source. The value of this parameter must be accurate to the second. This parameter is required when reindexing is triggered for the API-pushed data source. |
| dataSourceType | No | Enum | This parameter is required when the triggerBuild parameter is set to true. Valid values: odps and swift. |
Sample requests
PUT /openapi/ha3/instances/ha3_instance_name/cluster-offline-config
{
"dataSource": "test1",
"domain": "xx",
"indexes": [
{
"name": "index1",
"versionId": 1
},
{
"name": "index2",
"versionId": 1
}
],
"advancedConfigVersionId": 2,
"triggerBuild": true,
"partition": "20201010", // This parameter is required when reindexing is triggered for the odps data source.
"dataSourceType": "odps", // This parameter is required. Set this parameter to odps or swift. An error message is returned if you do not set this parameter.
"dataTimeSec": 1640867288 // This parameter specifies the time when reindexing is triggered for the API-pushed data source. The value of this parameter must be accurate to the second. This parameter is required when reindexing is triggered for the API-pushed data source.
}
Response elements
|
Element |
Type |
Description |
Example |
|
object |
Schema of Response |
||
| requestId |
string |
The ID of the request |
E7B7D598-B080-5C8E-AA35-D43EC0D5F886 |
| result |
object |
The result |
{} |
ResponseExample
{
"requestId": "0A6EB64B-B4C8-CF02-810F-E660812972FF",
"result": []
}
For details, refer toResponse structure
Examples
Success response
JSON format
{
"requestId": "E7B7D598-B080-5C8E-AA35-D43EC0D5F886",
"result": {}
}
Error codes
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.