Add snapshot settings.
This commit is contained in:
@@ -1,3 +1,7 @@
|
||||
2020-07-22 Version: 1.36.528
|
||||
- Add snapshot settings.
|
||||
- Add ElasticTask.
|
||||
|
||||
2020-07-22 Version: 1.36.527
|
||||
- Add SourceId for SearchFace.
|
||||
|
||||
|
||||
@@ -63,6 +63,10 @@ set(elasticsearch_public_header_model
|
||||
include/alibabacloud/elasticsearch/model/DescribePipelineManagementConfigResult.h
|
||||
include/alibabacloud/elasticsearch/model/DescribeRegionsRequest.h
|
||||
include/alibabacloud/elasticsearch/model/DescribeRegionsResult.h
|
||||
include/alibabacloud/elasticsearch/model/DescribeSnapshotSettingRequest.h
|
||||
include/alibabacloud/elasticsearch/model/DescribeSnapshotSettingResult.h
|
||||
include/alibabacloud/elasticsearch/model/GetElastictaskRequest.h
|
||||
include/alibabacloud/elasticsearch/model/GetElastictaskResult.h
|
||||
include/alibabacloud/elasticsearch/model/GetRegionConfigurationRequest.h
|
||||
include/alibabacloud/elasticsearch/model/GetRegionConfigurationResult.h
|
||||
include/alibabacloud/elasticsearch/model/GetSuggestShrinkableNodesRequest.h
|
||||
@@ -105,6 +109,8 @@ set(elasticsearch_public_header_model
|
||||
include/alibabacloud/elasticsearch/model/ListSnapshotReposByInstanceIdResult.h
|
||||
include/alibabacloud/elasticsearch/model/ListTagResourcesRequest.h
|
||||
include/alibabacloud/elasticsearch/model/ListTagResourcesResult.h
|
||||
include/alibabacloud/elasticsearch/model/ModifyElastictaskRequest.h
|
||||
include/alibabacloud/elasticsearch/model/ModifyElastictaskResult.h
|
||||
include/alibabacloud/elasticsearch/model/ModifyWhiteIpsRequest.h
|
||||
include/alibabacloud/elasticsearch/model/ModifyWhiteIpsResult.h
|
||||
include/alibabacloud/elasticsearch/model/MoveResourceGroupRequest.h
|
||||
@@ -240,6 +246,10 @@ set(elasticsearch_src
|
||||
src/model/DescribePipelineManagementConfigResult.cc
|
||||
src/model/DescribeRegionsRequest.cc
|
||||
src/model/DescribeRegionsResult.cc
|
||||
src/model/DescribeSnapshotSettingRequest.cc
|
||||
src/model/DescribeSnapshotSettingResult.cc
|
||||
src/model/GetElastictaskRequest.cc
|
||||
src/model/GetElastictaskResult.cc
|
||||
src/model/GetRegionConfigurationRequest.cc
|
||||
src/model/GetRegionConfigurationResult.cc
|
||||
src/model/GetSuggestShrinkableNodesRequest.cc
|
||||
@@ -282,6 +292,8 @@ set(elasticsearch_src
|
||||
src/model/ListSnapshotReposByInstanceIdResult.cc
|
||||
src/model/ListTagResourcesRequest.cc
|
||||
src/model/ListTagResourcesResult.cc
|
||||
src/model/ModifyElastictaskRequest.cc
|
||||
src/model/ModifyElastictaskResult.cc
|
||||
src/model/ModifyWhiteIpsRequest.cc
|
||||
src/model/ModifyWhiteIpsResult.cc
|
||||
src/model/MoveResourceGroupRequest.cc
|
||||
|
||||
@@ -64,6 +64,10 @@
|
||||
#include "model/DescribePipelineManagementConfigResult.h"
|
||||
#include "model/DescribeRegionsRequest.h"
|
||||
#include "model/DescribeRegionsResult.h"
|
||||
#include "model/DescribeSnapshotSettingRequest.h"
|
||||
#include "model/DescribeSnapshotSettingResult.h"
|
||||
#include "model/GetElastictaskRequest.h"
|
||||
#include "model/GetElastictaskResult.h"
|
||||
#include "model/GetRegionConfigurationRequest.h"
|
||||
#include "model/GetRegionConfigurationResult.h"
|
||||
#include "model/GetSuggestShrinkableNodesRequest.h"
|
||||
@@ -106,6 +110,8 @@
|
||||
#include "model/ListSnapshotReposByInstanceIdResult.h"
|
||||
#include "model/ListTagResourcesRequest.h"
|
||||
#include "model/ListTagResourcesResult.h"
|
||||
#include "model/ModifyElastictaskRequest.h"
|
||||
#include "model/ModifyElastictaskResult.h"
|
||||
#include "model/ModifyWhiteIpsRequest.h"
|
||||
#include "model/ModifyWhiteIpsResult.h"
|
||||
#include "model/MoveResourceGroupRequest.h"
|
||||
@@ -268,6 +274,12 @@ namespace AlibabaCloud
|
||||
typedef Outcome<Error, Model::DescribeRegionsResult> DescribeRegionsOutcome;
|
||||
typedef std::future<DescribeRegionsOutcome> DescribeRegionsOutcomeCallable;
|
||||
typedef std::function<void(const ElasticsearchClient*, const Model::DescribeRegionsRequest&, const DescribeRegionsOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> DescribeRegionsAsyncHandler;
|
||||
typedef Outcome<Error, Model::DescribeSnapshotSettingResult> DescribeSnapshotSettingOutcome;
|
||||
typedef std::future<DescribeSnapshotSettingOutcome> DescribeSnapshotSettingOutcomeCallable;
|
||||
typedef std::function<void(const ElasticsearchClient*, const Model::DescribeSnapshotSettingRequest&, const DescribeSnapshotSettingOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> DescribeSnapshotSettingAsyncHandler;
|
||||
typedef Outcome<Error, Model::GetElastictaskResult> GetElastictaskOutcome;
|
||||
typedef std::future<GetElastictaskOutcome> GetElastictaskOutcomeCallable;
|
||||
typedef std::function<void(const ElasticsearchClient*, const Model::GetElastictaskRequest&, const GetElastictaskOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> GetElastictaskAsyncHandler;
|
||||
typedef Outcome<Error, Model::GetRegionConfigurationResult> GetRegionConfigurationOutcome;
|
||||
typedef std::future<GetRegionConfigurationOutcome> GetRegionConfigurationOutcomeCallable;
|
||||
typedef std::function<void(const ElasticsearchClient*, const Model::GetRegionConfigurationRequest&, const GetRegionConfigurationOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> GetRegionConfigurationAsyncHandler;
|
||||
@@ -331,6 +343,9 @@ namespace AlibabaCloud
|
||||
typedef Outcome<Error, Model::ListTagResourcesResult> ListTagResourcesOutcome;
|
||||
typedef std::future<ListTagResourcesOutcome> ListTagResourcesOutcomeCallable;
|
||||
typedef std::function<void(const ElasticsearchClient*, const Model::ListTagResourcesRequest&, const ListTagResourcesOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> ListTagResourcesAsyncHandler;
|
||||
typedef Outcome<Error, Model::ModifyElastictaskResult> ModifyElastictaskOutcome;
|
||||
typedef std::future<ModifyElastictaskOutcome> ModifyElastictaskOutcomeCallable;
|
||||
typedef std::function<void(const ElasticsearchClient*, const Model::ModifyElastictaskRequest&, const ModifyElastictaskOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> ModifyElastictaskAsyncHandler;
|
||||
typedef Outcome<Error, Model::ModifyWhiteIpsResult> ModifyWhiteIpsOutcome;
|
||||
typedef std::future<ModifyWhiteIpsOutcome> ModifyWhiteIpsOutcomeCallable;
|
||||
typedef std::function<void(const ElasticsearchClient*, const Model::ModifyWhiteIpsRequest&, const ModifyWhiteIpsOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> ModifyWhiteIpsAsyncHandler;
|
||||
@@ -534,6 +549,12 @@ namespace AlibabaCloud
|
||||
DescribeRegionsOutcome describeRegions(const Model::DescribeRegionsRequest &request)const;
|
||||
void describeRegionsAsync(const Model::DescribeRegionsRequest& request, const DescribeRegionsAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
DescribeRegionsOutcomeCallable describeRegionsCallable(const Model::DescribeRegionsRequest& request) const;
|
||||
DescribeSnapshotSettingOutcome describeSnapshotSetting(const Model::DescribeSnapshotSettingRequest &request)const;
|
||||
void describeSnapshotSettingAsync(const Model::DescribeSnapshotSettingRequest& request, const DescribeSnapshotSettingAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
DescribeSnapshotSettingOutcomeCallable describeSnapshotSettingCallable(const Model::DescribeSnapshotSettingRequest& request) const;
|
||||
GetElastictaskOutcome getElastictask(const Model::GetElastictaskRequest &request)const;
|
||||
void getElastictaskAsync(const Model::GetElastictaskRequest& request, const GetElastictaskAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
GetElastictaskOutcomeCallable getElastictaskCallable(const Model::GetElastictaskRequest& request) const;
|
||||
GetRegionConfigurationOutcome getRegionConfiguration(const Model::GetRegionConfigurationRequest &request)const;
|
||||
void getRegionConfigurationAsync(const Model::GetRegionConfigurationRequest& request, const GetRegionConfigurationAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
GetRegionConfigurationOutcomeCallable getRegionConfigurationCallable(const Model::GetRegionConfigurationRequest& request) const;
|
||||
@@ -597,6 +618,9 @@ namespace AlibabaCloud
|
||||
ListTagResourcesOutcome listTagResources(const Model::ListTagResourcesRequest &request)const;
|
||||
void listTagResourcesAsync(const Model::ListTagResourcesRequest& request, const ListTagResourcesAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
ListTagResourcesOutcomeCallable listTagResourcesCallable(const Model::ListTagResourcesRequest& request) const;
|
||||
ModifyElastictaskOutcome modifyElastictask(const Model::ModifyElastictaskRequest &request)const;
|
||||
void modifyElastictaskAsync(const Model::ModifyElastictaskRequest& request, const ModifyElastictaskAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
ModifyElastictaskOutcomeCallable modifyElastictaskCallable(const Model::ModifyElastictaskRequest& request) const;
|
||||
ModifyWhiteIpsOutcome modifyWhiteIps(const Model::ModifyWhiteIpsRequest &request)const;
|
||||
void modifyWhiteIpsAsync(const Model::ModifyWhiteIpsRequest& request, const ModifyWhiteIpsAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
ModifyWhiteIpsOutcomeCallable modifyWhiteIpsCallable(const Model::ModifyWhiteIpsRequest& request) const;
|
||||
|
||||
@@ -37,11 +37,14 @@ namespace AlibabaCloud
|
||||
|
||||
std::string getInstanceId()const;
|
||||
void setInstanceId(const std::string& instanceId);
|
||||
std::string getClientToken()const;
|
||||
void setClientToken(const std::string& clientToken);
|
||||
std::string getRepoPath()const;
|
||||
void setRepoPath(const std::string& repoPath);
|
||||
|
||||
private:
|
||||
std::string instanceId_;
|
||||
std::string clientToken_;
|
||||
std::string repoPath_;
|
||||
|
||||
};
|
||||
|
||||
@@ -79,6 +79,14 @@ namespace AlibabaCloud
|
||||
{
|
||||
std::string gcName;
|
||||
};
|
||||
struct ElasticDataNodeConfiguration
|
||||
{
|
||||
std::string diskType;
|
||||
bool diskEncryption;
|
||||
int amount;
|
||||
std::string spec;
|
||||
int disk;
|
||||
};
|
||||
struct DictListItem
|
||||
{
|
||||
std::string type;
|
||||
@@ -113,6 +121,7 @@ namespace AlibabaCloud
|
||||
MasterConfiguration masterConfiguration;
|
||||
std::string description;
|
||||
std::string resourceGroupId;
|
||||
ElasticDataNodeConfiguration elasticDataNodeConfiguration;
|
||||
bool dedicateMaster;
|
||||
std::vector<std::string> esIPBlacklist;
|
||||
std::vector<ZoneInfo> zoneInfos;
|
||||
|
||||
@@ -0,0 +1,48 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_ELASTICSEARCH_MODEL_DESCRIBESNAPSHOTSETTINGREQUEST_H_
|
||||
#define ALIBABACLOUD_ELASTICSEARCH_MODEL_DESCRIBESNAPSHOTSETTINGREQUEST_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <alibabacloud/core/RoaServiceRequest.h>
|
||||
#include <alibabacloud/elasticsearch/ElasticsearchExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Elasticsearch
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_ELASTICSEARCH_EXPORT DescribeSnapshotSettingRequest : public RoaServiceRequest
|
||||
{
|
||||
|
||||
public:
|
||||
DescribeSnapshotSettingRequest();
|
||||
~DescribeSnapshotSettingRequest();
|
||||
|
||||
std::string getInstanceId()const;
|
||||
void setInstanceId(const std::string& instanceId);
|
||||
|
||||
private:
|
||||
std::string instanceId_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_ELASTICSEARCH_MODEL_DESCRIBESNAPSHOTSETTINGREQUEST_H_
|
||||
@@ -0,0 +1,56 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_ELASTICSEARCH_MODEL_DESCRIBESNAPSHOTSETTINGRESULT_H_
|
||||
#define ALIBABACLOUD_ELASTICSEARCH_MODEL_DESCRIBESNAPSHOTSETTINGRESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/elasticsearch/ElasticsearchExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Elasticsearch
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_ELASTICSEARCH_EXPORT DescribeSnapshotSettingResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
struct Result
|
||||
{
|
||||
bool enable;
|
||||
std::string quartzRegex;
|
||||
};
|
||||
|
||||
|
||||
DescribeSnapshotSettingResult();
|
||||
explicit DescribeSnapshotSettingResult(const std::string &payload);
|
||||
~DescribeSnapshotSettingResult();
|
||||
Result getResult()const;
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
Result result_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_ELASTICSEARCH_MODEL_DESCRIBESNAPSHOTSETTINGRESULT_H_
|
||||
@@ -0,0 +1,48 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_ELASTICSEARCH_MODEL_GETELASTICTASKREQUEST_H_
|
||||
#define ALIBABACLOUD_ELASTICSEARCH_MODEL_GETELASTICTASKREQUEST_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <alibabacloud/core/RoaServiceRequest.h>
|
||||
#include <alibabacloud/elasticsearch/ElasticsearchExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Elasticsearch
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_ELASTICSEARCH_EXPORT GetElastictaskRequest : public RoaServiceRequest
|
||||
{
|
||||
|
||||
public:
|
||||
GetElastictaskRequest();
|
||||
~GetElastictaskRequest();
|
||||
|
||||
std::string getInstanceId()const;
|
||||
void setInstanceId(const std::string& instanceId);
|
||||
|
||||
private:
|
||||
std::string instanceId_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_ELASTICSEARCH_MODEL_GETELASTICTASKREQUEST_H_
|
||||
@@ -0,0 +1,72 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_ELASTICSEARCH_MODEL_GETELASTICTASKRESULT_H_
|
||||
#define ALIBABACLOUD_ELASTICSEARCH_MODEL_GETELASTICTASKRESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/elasticsearch/ElasticsearchExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Elasticsearch
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_ELASTICSEARCH_EXPORT GetElastictaskResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
struct Result
|
||||
{
|
||||
struct ElasticExpansionTask
|
||||
{
|
||||
std::string triggerType;
|
||||
int replicaCount;
|
||||
std::string cronExpression;
|
||||
int elasticNodeCount;
|
||||
std::vector<std::string> targetIndices;
|
||||
};
|
||||
struct ElasticShrinkTask
|
||||
{
|
||||
std::string triggerType;
|
||||
int replicaCount;
|
||||
std::string cronExpression;
|
||||
int elasticNodeCount;
|
||||
std::vector<std::string> targetIndices1;
|
||||
};
|
||||
ElasticShrinkTask elasticShrinkTask;
|
||||
ElasticExpansionTask elasticExpansionTask;
|
||||
};
|
||||
|
||||
|
||||
GetElastictaskResult();
|
||||
explicit GetElastictaskResult(const std::string &payload);
|
||||
~GetElastictaskResult();
|
||||
Result getResult()const;
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
Result result_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_ELASTICSEARCH_MODEL_GETELASTICTASKRESULT_H_
|
||||
@@ -62,6 +62,7 @@ namespace AlibabaCloud
|
||||
std::string diskType;
|
||||
int minSize;
|
||||
int scaleLimit;
|
||||
bool diskEncryption;
|
||||
std::vector<std::string> valueLimitSet2;
|
||||
int maxSize;
|
||||
};
|
||||
@@ -79,6 +80,26 @@ namespace AlibabaCloud
|
||||
AmountRange4 amountRange4;
|
||||
std::vector<std::string> spec3;
|
||||
};
|
||||
struct ElasticNodeProperties
|
||||
{
|
||||
struct AmountRange6
|
||||
{
|
||||
int minAmount;
|
||||
int maxAmount;
|
||||
};
|
||||
struct Disk8
|
||||
{
|
||||
std::string diskType;
|
||||
int minSize;
|
||||
int scaleLimit;
|
||||
std::vector<std::string> valueLimitSet9;
|
||||
bool diskEncryption;
|
||||
int maxSize;
|
||||
};
|
||||
AmountRange6 amountRange6;
|
||||
std::vector<Disk8> diskList7;
|
||||
std::vector<std::string> spec5;
|
||||
};
|
||||
struct DataDiskListItem
|
||||
{
|
||||
std::string diskType;
|
||||
@@ -127,6 +148,7 @@ namespace AlibabaCloud
|
||||
std::vector<CategoryEntity> supportVersions;
|
||||
WarmNodeProperties warmNodeProperties;
|
||||
std::vector<Disk> clientNodeDiskList;
|
||||
ElasticNodeProperties elasticNodeProperties;
|
||||
std::vector<EsVersionsLatestListItem> esVersionsLatestList;
|
||||
std::string env;
|
||||
std::vector<std::string> clientNodeSpec;
|
||||
@@ -137,6 +159,7 @@ namespace AlibabaCloud
|
||||
std::string regionId;
|
||||
std::vector<std::string> esVersions;
|
||||
std::vector<std::string> masterSpec;
|
||||
std::vector<std::string> instanceSupportNodes;
|
||||
};
|
||||
|
||||
|
||||
|
||||
@@ -35,6 +35,8 @@ namespace AlibabaCloud
|
||||
GetSuggestShrinkableNodesRequest();
|
||||
~GetSuggestShrinkableNodesRequest();
|
||||
|
||||
bool getIgnoreStatus()const;
|
||||
void setIgnoreStatus(bool ignoreStatus);
|
||||
std::string getInstanceId()const;
|
||||
void setInstanceId(const std::string& instanceId);
|
||||
std::string getNodeType()const;
|
||||
@@ -43,6 +45,7 @@ namespace AlibabaCloud
|
||||
void setCount(int count);
|
||||
|
||||
private:
|
||||
bool ignoreStatus_;
|
||||
std::string instanceId_;
|
||||
std::string nodeType_;
|
||||
int count_;
|
||||
|
||||
@@ -65,6 +65,21 @@ namespace AlibabaCloud
|
||||
std::string spec;
|
||||
int disk;
|
||||
};
|
||||
struct ElasticDataNodeConfiguration
|
||||
{
|
||||
std::string diskType;
|
||||
bool diskEncryption;
|
||||
int amount;
|
||||
std::string spec;
|
||||
int disk;
|
||||
};
|
||||
struct ClientNodeConfiguration
|
||||
{
|
||||
std::string diskType;
|
||||
int amount;
|
||||
std::string spec;
|
||||
int disk;
|
||||
};
|
||||
struct Tag
|
||||
{
|
||||
std::string tagKey;
|
||||
@@ -74,6 +89,7 @@ namespace AlibabaCloud
|
||||
std::string status;
|
||||
std::string description;
|
||||
std::string resourceGroupId;
|
||||
ElasticDataNodeConfiguration elasticDataNodeConfiguration;
|
||||
std::string instanceId;
|
||||
bool dedicateMaster;
|
||||
std::string createdAt;
|
||||
@@ -86,6 +102,7 @@ namespace AlibabaCloud
|
||||
bool advancedDedicateMaster;
|
||||
NodeSpec nodeSpec;
|
||||
std::string paymentType;
|
||||
ClientNodeConfiguration clientNodeConfiguration;
|
||||
};
|
||||
|
||||
|
||||
|
||||
@@ -0,0 +1,48 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_ELASTICSEARCH_MODEL_MODIFYELASTICTASKREQUEST_H_
|
||||
#define ALIBABACLOUD_ELASTICSEARCH_MODEL_MODIFYELASTICTASKREQUEST_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <alibabacloud/core/RoaServiceRequest.h>
|
||||
#include <alibabacloud/elasticsearch/ElasticsearchExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Elasticsearch
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_ELASTICSEARCH_EXPORT ModifyElastictaskRequest : public RoaServiceRequest
|
||||
{
|
||||
|
||||
public:
|
||||
ModifyElastictaskRequest();
|
||||
~ModifyElastictaskRequest();
|
||||
|
||||
std::string getInstanceId()const;
|
||||
void setInstanceId(const std::string& instanceId);
|
||||
|
||||
private:
|
||||
std::string instanceId_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_ELASTICSEARCH_MODEL_MODIFYELASTICTASKREQUEST_H_
|
||||
@@ -0,0 +1,72 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#ifndef ALIBABACLOUD_ELASTICSEARCH_MODEL_MODIFYELASTICTASKRESULT_H_
|
||||
#define ALIBABACLOUD_ELASTICSEARCH_MODEL_MODIFYELASTICTASKRESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/elasticsearch/ElasticsearchExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Elasticsearch
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_ELASTICSEARCH_EXPORT ModifyElastictaskResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
struct Result
|
||||
{
|
||||
struct ElasticExpansionTask
|
||||
{
|
||||
std::string triggerType;
|
||||
int replicaCount;
|
||||
std::string cronExpression;
|
||||
int elasticNodeCount;
|
||||
std::vector<std::string> targetIndices;
|
||||
};
|
||||
struct ElasticShrinkTask
|
||||
{
|
||||
std::string triggerType;
|
||||
int replicaCount;
|
||||
std::string cronExpression;
|
||||
int elasticNodeCount;
|
||||
std::vector<std::string> targetIndices1;
|
||||
};
|
||||
ElasticShrinkTask elasticShrinkTask;
|
||||
ElasticExpansionTask elasticExpansionTask;
|
||||
};
|
||||
|
||||
|
||||
ModifyElastictaskResult();
|
||||
explicit ModifyElastictaskResult(const std::string &payload);
|
||||
~ModifyElastictaskResult();
|
||||
Result getResult()const;
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
Result result_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_ELASTICSEARCH_MODEL_MODIFYELASTICTASKRESULT_H_
|
||||
@@ -35,6 +35,8 @@ namespace AlibabaCloud
|
||||
ShrinkNodeRequest();
|
||||
~ShrinkNodeRequest();
|
||||
|
||||
bool getIgnoreStatus()const;
|
||||
void setIgnoreStatus(bool ignoreStatus);
|
||||
std::string getInstanceId()const;
|
||||
void setInstanceId(const std::string& instanceId);
|
||||
std::string getNodeType()const;
|
||||
@@ -43,6 +45,7 @@ namespace AlibabaCloud
|
||||
void setClientToken(const std::string& clientToken);
|
||||
|
||||
private:
|
||||
bool ignoreStatus_;
|
||||
std::string instanceId_;
|
||||
std::string nodeType_;
|
||||
std::string clientToken_;
|
||||
|
||||
@@ -35,12 +35,15 @@ namespace AlibabaCloud
|
||||
UpdateInstanceRequest();
|
||||
~UpdateInstanceRequest();
|
||||
|
||||
bool getIgnoreStatus()const;
|
||||
void setIgnoreStatus(bool ignoreStatus);
|
||||
std::string getInstanceId()const;
|
||||
void setInstanceId(const std::string& instanceId);
|
||||
std::string getClientToken()const;
|
||||
void setClientToken(const std::string& clientToken);
|
||||
|
||||
private:
|
||||
bool ignoreStatus_;
|
||||
std::string instanceId_;
|
||||
std::string clientToken_;
|
||||
|
||||
|
||||
@@ -35,12 +35,15 @@ namespace AlibabaCloud
|
||||
ValidateShrinkNodesRequest();
|
||||
~ValidateShrinkNodesRequest();
|
||||
|
||||
bool getIgnoreStatus()const;
|
||||
void setIgnoreStatus(bool ignoreStatus);
|
||||
std::string getInstanceId()const;
|
||||
void setInstanceId(const std::string& instanceId);
|
||||
std::string getNodeType()const;
|
||||
void setNodeType(const std::string& nodeType);
|
||||
|
||||
private:
|
||||
bool ignoreStatus_;
|
||||
std::string instanceId_;
|
||||
std::string nodeType_;
|
||||
|
||||
|
||||
@@ -807,6 +807,78 @@ ElasticsearchClient::DescribeRegionsOutcomeCallable ElasticsearchClient::describ
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
ElasticsearchClient::DescribeSnapshotSettingOutcome ElasticsearchClient::describeSnapshotSetting(const DescribeSnapshotSettingRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return DescribeSnapshotSettingOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return DescribeSnapshotSettingOutcome(DescribeSnapshotSettingResult(outcome.result()));
|
||||
else
|
||||
return DescribeSnapshotSettingOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void ElasticsearchClient::describeSnapshotSettingAsync(const DescribeSnapshotSettingRequest& request, const DescribeSnapshotSettingAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, describeSnapshotSetting(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
ElasticsearchClient::DescribeSnapshotSettingOutcomeCallable ElasticsearchClient::describeSnapshotSettingCallable(const DescribeSnapshotSettingRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<DescribeSnapshotSettingOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->describeSnapshotSetting(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
ElasticsearchClient::GetElastictaskOutcome ElasticsearchClient::getElastictask(const GetElastictaskRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return GetElastictaskOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return GetElastictaskOutcome(GetElastictaskResult(outcome.result()));
|
||||
else
|
||||
return GetElastictaskOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void ElasticsearchClient::getElastictaskAsync(const GetElastictaskRequest& request, const GetElastictaskAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, getElastictask(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
ElasticsearchClient::GetElastictaskOutcomeCallable ElasticsearchClient::getElastictaskCallable(const GetElastictaskRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<GetElastictaskOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->getElastictask(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
ElasticsearchClient::GetRegionConfigurationOutcome ElasticsearchClient::getRegionConfiguration(const GetRegionConfigurationRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
@@ -1563,6 +1635,42 @@ ElasticsearchClient::ListTagResourcesOutcomeCallable ElasticsearchClient::listTa
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
ElasticsearchClient::ModifyElastictaskOutcome ElasticsearchClient::modifyElastictask(const ModifyElastictaskRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return ModifyElastictaskOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return ModifyElastictaskOutcome(ModifyElastictaskResult(outcome.result()));
|
||||
else
|
||||
return ModifyElastictaskOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void ElasticsearchClient::modifyElastictaskAsync(const ModifyElastictaskRequest& request, const ModifyElastictaskAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, modifyElastictask(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
ElasticsearchClient::ModifyElastictaskOutcomeCallable ElasticsearchClient::modifyElastictaskCallable(const ModifyElastictaskRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<ModifyElastictaskOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->modifyElastictask(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
ElasticsearchClient::ModifyWhiteIpsOutcome ElasticsearchClient::modifyWhiteIps(const ModifyWhiteIpsRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
|
||||
@@ -39,6 +39,17 @@ void DeleteSnapshotRepoRequest::setInstanceId(const std::string& instanceId)
|
||||
setParameter("InstanceId", instanceId);
|
||||
}
|
||||
|
||||
std::string DeleteSnapshotRepoRequest::getClientToken()const
|
||||
{
|
||||
return clientToken_;
|
||||
}
|
||||
|
||||
void DeleteSnapshotRepoRequest::setClientToken(const std::string& clientToken)
|
||||
{
|
||||
clientToken_ = clientToken;
|
||||
setParameter("ClientToken", clientToken);
|
||||
}
|
||||
|
||||
std::string DeleteSnapshotRepoRequest::getRepoPath()const
|
||||
{
|
||||
return repoPath_;
|
||||
|
||||
@@ -211,6 +211,17 @@ void DescribeInstanceResult::parse(const std::string &payload)
|
||||
auto advancedSettingNode = resultNode["advancedSetting"];
|
||||
if(!advancedSettingNode["gcName"].isNull())
|
||||
result_.advancedSetting.gcName = advancedSettingNode["gcName"].asString();
|
||||
auto elasticDataNodeConfigurationNode = resultNode["elasticDataNodeConfiguration"];
|
||||
if(!elasticDataNodeConfigurationNode["spec"].isNull())
|
||||
result_.elasticDataNodeConfiguration.spec = elasticDataNodeConfigurationNode["spec"].asString();
|
||||
if(!elasticDataNodeConfigurationNode["amount"].isNull())
|
||||
result_.elasticDataNodeConfiguration.amount = std::stoi(elasticDataNodeConfigurationNode["amount"].asString());
|
||||
if(!elasticDataNodeConfigurationNode["diskType"].isNull())
|
||||
result_.elasticDataNodeConfiguration.diskType = elasticDataNodeConfigurationNode["diskType"].asString();
|
||||
if(!elasticDataNodeConfigurationNode["disk"].isNull())
|
||||
result_.elasticDataNodeConfiguration.disk = std::stoi(elasticDataNodeConfigurationNode["disk"].asString());
|
||||
if(!elasticDataNodeConfigurationNode["diskEncryption"].isNull())
|
||||
result_.elasticDataNodeConfiguration.diskEncryption = elasticDataNodeConfigurationNode["diskEncryption"].asString() == "true";
|
||||
auto allEsIPWhitelist = resultNode["esIPWhitelist"]["EsIPWhitelist"];
|
||||
for (auto value : allEsIPWhitelist)
|
||||
result_.esIPWhitelist.push_back(value.asString());
|
||||
|
||||
41
elasticsearch/src/model/DescribeSnapshotSettingRequest.cc
Normal file
41
elasticsearch/src/model/DescribeSnapshotSettingRequest.cc
Normal file
@@ -0,0 +1,41 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include <alibabacloud/elasticsearch/model/DescribeSnapshotSettingRequest.h>
|
||||
|
||||
using AlibabaCloud::Elasticsearch::Model::DescribeSnapshotSettingRequest;
|
||||
|
||||
DescribeSnapshotSettingRequest::DescribeSnapshotSettingRequest() :
|
||||
RoaServiceRequest("elasticsearch", "2017-06-13")
|
||||
{
|
||||
setResourcePath("/openapi/instances/[InstanceId]/snapshot-setting");
|
||||
setMethod(HttpRequest::Method::Get);
|
||||
}
|
||||
|
||||
DescribeSnapshotSettingRequest::~DescribeSnapshotSettingRequest()
|
||||
{}
|
||||
|
||||
std::string DescribeSnapshotSettingRequest::getInstanceId()const
|
||||
{
|
||||
return instanceId_;
|
||||
}
|
||||
|
||||
void DescribeSnapshotSettingRequest::setInstanceId(const std::string& instanceId)
|
||||
{
|
||||
instanceId_ = instanceId;
|
||||
setParameter("InstanceId", instanceId);
|
||||
}
|
||||
|
||||
54
elasticsearch/src/model/DescribeSnapshotSettingResult.cc
Normal file
54
elasticsearch/src/model/DescribeSnapshotSettingResult.cc
Normal file
@@ -0,0 +1,54 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include <alibabacloud/elasticsearch/model/DescribeSnapshotSettingResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Elasticsearch;
|
||||
using namespace AlibabaCloud::Elasticsearch::Model;
|
||||
|
||||
DescribeSnapshotSettingResult::DescribeSnapshotSettingResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
DescribeSnapshotSettingResult::DescribeSnapshotSettingResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
DescribeSnapshotSettingResult::~DescribeSnapshotSettingResult()
|
||||
{}
|
||||
|
||||
void DescribeSnapshotSettingResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
auto resultNode = value["Result"];
|
||||
if(!resultNode["QuartzRegex"].isNull())
|
||||
result_.quartzRegex = resultNode["QuartzRegex"].asString();
|
||||
if(!resultNode["Enable"].isNull())
|
||||
result_.enable = resultNode["Enable"].asString() == "true";
|
||||
|
||||
}
|
||||
|
||||
DescribeSnapshotSettingResult::Result DescribeSnapshotSettingResult::getResult()const
|
||||
{
|
||||
return result_;
|
||||
}
|
||||
|
||||
41
elasticsearch/src/model/GetElastictaskRequest.cc
Normal file
41
elasticsearch/src/model/GetElastictaskRequest.cc
Normal file
@@ -0,0 +1,41 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include <alibabacloud/elasticsearch/model/GetElastictaskRequest.h>
|
||||
|
||||
using AlibabaCloud::Elasticsearch::Model::GetElastictaskRequest;
|
||||
|
||||
GetElastictaskRequest::GetElastictaskRequest() :
|
||||
RoaServiceRequest("elasticsearch", "2017-06-13")
|
||||
{
|
||||
setResourcePath("/openapi/instances/[InstanceId]/elastic-task");
|
||||
setMethod(HttpRequest::Method::Get);
|
||||
}
|
||||
|
||||
GetElastictaskRequest::~GetElastictaskRequest()
|
||||
{}
|
||||
|
||||
std::string GetElastictaskRequest::getInstanceId()const
|
||||
{
|
||||
return instanceId_;
|
||||
}
|
||||
|
||||
void GetElastictaskRequest::setInstanceId(const std::string& instanceId)
|
||||
{
|
||||
instanceId_ = instanceId;
|
||||
setParameter("InstanceId", instanceId);
|
||||
}
|
||||
|
||||
74
elasticsearch/src/model/GetElastictaskResult.cc
Normal file
74
elasticsearch/src/model/GetElastictaskResult.cc
Normal file
@@ -0,0 +1,74 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include <alibabacloud/elasticsearch/model/GetElastictaskResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Elasticsearch;
|
||||
using namespace AlibabaCloud::Elasticsearch::Model;
|
||||
|
||||
GetElastictaskResult::GetElastictaskResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
GetElastictaskResult::GetElastictaskResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
GetElastictaskResult::~GetElastictaskResult()
|
||||
{}
|
||||
|
||||
void GetElastictaskResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
auto resultNode = value["Result"];
|
||||
auto elasticExpansionTaskNode = resultNode["ElasticExpansionTask"];
|
||||
if(!elasticExpansionTaskNode["TriggerType"].isNull())
|
||||
result_.elasticExpansionTask.triggerType = elasticExpansionTaskNode["TriggerType"].asString();
|
||||
if(!elasticExpansionTaskNode["CronExpression"].isNull())
|
||||
result_.elasticExpansionTask.cronExpression = elasticExpansionTaskNode["CronExpression"].asString();
|
||||
if(!elasticExpansionTaskNode["ElasticNodeCount"].isNull())
|
||||
result_.elasticExpansionTask.elasticNodeCount = std::stoi(elasticExpansionTaskNode["ElasticNodeCount"].asString());
|
||||
if(!elasticExpansionTaskNode["ReplicaCount"].isNull())
|
||||
result_.elasticExpansionTask.replicaCount = std::stoi(elasticExpansionTaskNode["ReplicaCount"].asString());
|
||||
auto allTargetIndices = elasticExpansionTaskNode["TargetIndices"]["TargetIndices"];
|
||||
for (auto value : allTargetIndices)
|
||||
result_.elasticExpansionTask.targetIndices.push_back(value.asString());
|
||||
auto elasticShrinkTaskNode = resultNode["ElasticShrinkTask"];
|
||||
if(!elasticShrinkTaskNode["TriggerType"].isNull())
|
||||
result_.elasticShrinkTask.triggerType = elasticShrinkTaskNode["TriggerType"].asString();
|
||||
if(!elasticShrinkTaskNode["CronExpression"].isNull())
|
||||
result_.elasticShrinkTask.cronExpression = elasticShrinkTaskNode["CronExpression"].asString();
|
||||
if(!elasticShrinkTaskNode["ElasticNodeCount"].isNull())
|
||||
result_.elasticShrinkTask.elasticNodeCount = std::stoi(elasticShrinkTaskNode["ElasticNodeCount"].asString());
|
||||
if(!elasticShrinkTaskNode["ReplicaCount"].isNull())
|
||||
result_.elasticShrinkTask.replicaCount = std::stoi(elasticShrinkTaskNode["ReplicaCount"].asString());
|
||||
auto allTargetIndices1 = elasticShrinkTaskNode["TargetIndices"]["TargetIndices"];
|
||||
for (auto value : allTargetIndices1)
|
||||
result_.elasticShrinkTask.targetIndices1.push_back(value.asString());
|
||||
|
||||
}
|
||||
|
||||
GetElastictaskResult::Result GetElastictaskResult::getResult()const
|
||||
{
|
||||
return result_;
|
||||
}
|
||||
|
||||
@@ -165,34 +165,64 @@ void GetRegionConfigurationResult::parse(const std::string &payload)
|
||||
Result::WarmNodeProperties::Disk1 disk1Object;
|
||||
if(!warmNodePropertiesNodediskListdisk["diskType"].isNull())
|
||||
disk1Object.diskType = warmNodePropertiesNodediskListdisk["diskType"].asString();
|
||||
if(!warmNodePropertiesNodediskListdisk["minSize"].isNull())
|
||||
disk1Object.minSize = std::stoi(warmNodePropertiesNodediskListdisk["minSize"].asString());
|
||||
if(!warmNodePropertiesNodediskListdisk["maxSize"].isNull())
|
||||
disk1Object.maxSize = std::stoi(warmNodePropertiesNodediskListdisk["maxSize"].asString());
|
||||
if(!warmNodePropertiesNodediskListdisk["minSize"].isNull())
|
||||
disk1Object.minSize = std::stoi(warmNodePropertiesNodediskListdisk["minSize"].asString());
|
||||
if(!warmNodePropertiesNodediskListdisk["scaleLimit"].isNull())
|
||||
disk1Object.scaleLimit = std::stoi(warmNodePropertiesNodediskListdisk["scaleLimit"].asString());
|
||||
if(!warmNodePropertiesNodediskListdisk["diskEncryption"].isNull())
|
||||
disk1Object.diskEncryption = warmNodePropertiesNodediskListdisk["diskEncryption"].asString() == "true";
|
||||
auto allValueLimitSet2 = value["valueLimitSet"]["valueLimitSet"];
|
||||
for (auto value : allValueLimitSet2)
|
||||
disk1Object.valueLimitSet2.push_back(value.asString());
|
||||
result_.warmNodeProperties.diskList.push_back(disk1Object);
|
||||
}
|
||||
auto amountRangeNode = warmNodePropertiesNode["amountRange"];
|
||||
if(!amountRangeNode["minAmount"].isNull())
|
||||
result_.warmNodeProperties.amountRange.minAmount = std::stoi(amountRangeNode["minAmount"].asString());
|
||||
if(!amountRangeNode["maxAmount"].isNull())
|
||||
result_.warmNodeProperties.amountRange.maxAmount = std::stoi(amountRangeNode["maxAmount"].asString());
|
||||
if(!amountRangeNode["minAmount"].isNull())
|
||||
result_.warmNodeProperties.amountRange.minAmount = std::stoi(amountRangeNode["minAmount"].asString());
|
||||
auto allSpec = warmNodePropertiesNode["spec"]["spec"];
|
||||
for (auto value : allSpec)
|
||||
result_.warmNodeProperties.spec.push_back(value.asString());
|
||||
auto kibanaNodePropertiesNode = resultNode["kibanaNodeProperties"];
|
||||
auto amountRange4Node = kibanaNodePropertiesNode["amountRange"];
|
||||
if(!amountRange4Node["minAmount"].isNull())
|
||||
result_.kibanaNodeProperties.amountRange4.minAmount = std::stoi(amountRange4Node["minAmount"].asString());
|
||||
if(!amountRange4Node["maxAmount"].isNull())
|
||||
result_.kibanaNodeProperties.amountRange4.maxAmount = std::stoi(amountRange4Node["maxAmount"].asString());
|
||||
if(!amountRange4Node["minAmount"].isNull())
|
||||
result_.kibanaNodeProperties.amountRange4.minAmount = std::stoi(amountRange4Node["minAmount"].asString());
|
||||
auto allSpec3 = kibanaNodePropertiesNode["spec"]["spec"];
|
||||
for (auto value : allSpec3)
|
||||
result_.kibanaNodeProperties.spec3.push_back(value.asString());
|
||||
auto elasticNodePropertiesNode = resultNode["elasticNodeProperties"];
|
||||
auto alldiskList7Node = elasticNodePropertiesNode["diskList"]["disk"];
|
||||
for (auto elasticNodePropertiesNodediskListdisk : alldiskList7Node)
|
||||
{
|
||||
Result::ElasticNodeProperties::Disk8 disk8Object;
|
||||
if(!elasticNodePropertiesNodediskListdisk["diskType"].isNull())
|
||||
disk8Object.diskType = elasticNodePropertiesNodediskListdisk["diskType"].asString();
|
||||
if(!elasticNodePropertiesNodediskListdisk["maxSize"].isNull())
|
||||
disk8Object.maxSize = std::stoi(elasticNodePropertiesNodediskListdisk["maxSize"].asString());
|
||||
if(!elasticNodePropertiesNodediskListdisk["minSize"].isNull())
|
||||
disk8Object.minSize = std::stoi(elasticNodePropertiesNodediskListdisk["minSize"].asString());
|
||||
if(!elasticNodePropertiesNodediskListdisk["scaleLimit"].isNull())
|
||||
disk8Object.scaleLimit = std::stoi(elasticNodePropertiesNodediskListdisk["scaleLimit"].asString());
|
||||
if(!elasticNodePropertiesNodediskListdisk["diskEncryption"].isNull())
|
||||
disk8Object.diskEncryption = elasticNodePropertiesNodediskListdisk["diskEncryption"].asString() == "true";
|
||||
auto allValueLimitSet9 = value["valueLimitSet"]["valueLimitSet"];
|
||||
for (auto value : allValueLimitSet9)
|
||||
disk8Object.valueLimitSet9.push_back(value.asString());
|
||||
result_.elasticNodeProperties.diskList7.push_back(disk8Object);
|
||||
}
|
||||
auto amountRange6Node = elasticNodePropertiesNode["amountRange"];
|
||||
if(!amountRange6Node["maxAmount"].isNull())
|
||||
result_.elasticNodeProperties.amountRange6.maxAmount = std::stoi(amountRange6Node["maxAmount"].asString());
|
||||
if(!amountRange6Node["minAmount"].isNull())
|
||||
result_.elasticNodeProperties.amountRange6.minAmount = std::stoi(amountRange6Node["minAmount"].asString());
|
||||
auto allSpec5 = elasticNodePropertiesNode["spec"]["spec"];
|
||||
for (auto value : allSpec5)
|
||||
result_.elasticNodeProperties.spec5.push_back(value.asString());
|
||||
auto allZones = resultNode["zones"]["zones"];
|
||||
for (auto value : allZones)
|
||||
result_.zones.push_back(value.asString());
|
||||
@@ -205,6 +235,9 @@ void GetRegionConfigurationResult::parse(const std::string &payload)
|
||||
auto allClientNodeSpec = resultNode["clientNodeSpec"]["spec"];
|
||||
for (auto value : allClientNodeSpec)
|
||||
result_.clientNodeSpec.push_back(value.asString());
|
||||
auto allInstanceSupportNodes = resultNode["instanceSupportNodes"]["instanceSupportNodes"];
|
||||
for (auto value : allInstanceSupportNodes)
|
||||
result_.instanceSupportNodes.push_back(value.asString());
|
||||
|
||||
}
|
||||
|
||||
|
||||
@@ -28,6 +28,17 @@ GetSuggestShrinkableNodesRequest::GetSuggestShrinkableNodesRequest() :
|
||||
GetSuggestShrinkableNodesRequest::~GetSuggestShrinkableNodesRequest()
|
||||
{}
|
||||
|
||||
bool GetSuggestShrinkableNodesRequest::getIgnoreStatus()const
|
||||
{
|
||||
return ignoreStatus_;
|
||||
}
|
||||
|
||||
void GetSuggestShrinkableNodesRequest::setIgnoreStatus(bool ignoreStatus)
|
||||
{
|
||||
ignoreStatus_ = ignoreStatus;
|
||||
setParameter("IgnoreStatus", ignoreStatus ? "true" : "false");
|
||||
}
|
||||
|
||||
std::string GetSuggestShrinkableNodesRequest::getInstanceId()const
|
||||
{
|
||||
return instanceId_;
|
||||
|
||||
@@ -109,6 +109,26 @@ void ListInstanceResult::parse(const std::string &payload)
|
||||
resultObject.kibanaConfiguration.amount = std::stoi(kibanaConfigurationNode["amount"].asString());
|
||||
if(!kibanaConfigurationNode["diskType"].isNull())
|
||||
resultObject.kibanaConfiguration.diskType = kibanaConfigurationNode["diskType"].asString();
|
||||
auto elasticDataNodeConfigurationNode = value["elasticDataNodeConfiguration"];
|
||||
if(!elasticDataNodeConfigurationNode["spec"].isNull())
|
||||
resultObject.elasticDataNodeConfiguration.spec = elasticDataNodeConfigurationNode["spec"].asString();
|
||||
if(!elasticDataNodeConfigurationNode["amount"].isNull())
|
||||
resultObject.elasticDataNodeConfiguration.amount = std::stoi(elasticDataNodeConfigurationNode["amount"].asString());
|
||||
if(!elasticDataNodeConfigurationNode["diskType"].isNull())
|
||||
resultObject.elasticDataNodeConfiguration.diskType = elasticDataNodeConfigurationNode["diskType"].asString();
|
||||
if(!elasticDataNodeConfigurationNode["disk"].isNull())
|
||||
resultObject.elasticDataNodeConfiguration.disk = std::stoi(elasticDataNodeConfigurationNode["disk"].asString());
|
||||
if(!elasticDataNodeConfigurationNode["diskEncryption"].isNull())
|
||||
resultObject.elasticDataNodeConfiguration.diskEncryption = elasticDataNodeConfigurationNode["diskEncryption"].asString() == "true";
|
||||
auto clientNodeConfigurationNode = value["clientNodeConfiguration"];
|
||||
if(!clientNodeConfigurationNode["spec"].isNull())
|
||||
resultObject.clientNodeConfiguration.spec = clientNodeConfigurationNode["spec"].asString();
|
||||
if(!clientNodeConfigurationNode["amount"].isNull())
|
||||
resultObject.clientNodeConfiguration.amount = std::stoi(clientNodeConfigurationNode["amount"].asString());
|
||||
if(!clientNodeConfigurationNode["diskType"].isNull())
|
||||
resultObject.clientNodeConfiguration.diskType = clientNodeConfigurationNode["diskType"].asString();
|
||||
if(!clientNodeConfigurationNode["disk"].isNull())
|
||||
resultObject.clientNodeConfiguration.disk = std::stoi(clientNodeConfigurationNode["disk"].asString());
|
||||
result_.push_back(resultObject);
|
||||
}
|
||||
auto headersNode = value["Headers"];
|
||||
|
||||
41
elasticsearch/src/model/ModifyElastictaskRequest.cc
Normal file
41
elasticsearch/src/model/ModifyElastictaskRequest.cc
Normal file
@@ -0,0 +1,41 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include <alibabacloud/elasticsearch/model/ModifyElastictaskRequest.h>
|
||||
|
||||
using AlibabaCloud::Elasticsearch::Model::ModifyElastictaskRequest;
|
||||
|
||||
ModifyElastictaskRequest::ModifyElastictaskRequest() :
|
||||
RoaServiceRequest("elasticsearch", "2017-06-13")
|
||||
{
|
||||
setResourcePath("/openapi/instances/[InstanceId]/elastic-task");
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
ModifyElastictaskRequest::~ModifyElastictaskRequest()
|
||||
{}
|
||||
|
||||
std::string ModifyElastictaskRequest::getInstanceId()const
|
||||
{
|
||||
return instanceId_;
|
||||
}
|
||||
|
||||
void ModifyElastictaskRequest::setInstanceId(const std::string& instanceId)
|
||||
{
|
||||
instanceId_ = instanceId;
|
||||
setParameter("InstanceId", instanceId);
|
||||
}
|
||||
|
||||
74
elasticsearch/src/model/ModifyElastictaskResult.cc
Normal file
74
elasticsearch/src/model/ModifyElastictaskResult.cc
Normal file
@@ -0,0 +1,74 @@
|
||||
/*
|
||||
* Copyright 2009-2017 Alibaba Cloud All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include <alibabacloud/elasticsearch/model/ModifyElastictaskResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Elasticsearch;
|
||||
using namespace AlibabaCloud::Elasticsearch::Model;
|
||||
|
||||
ModifyElastictaskResult::ModifyElastictaskResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
ModifyElastictaskResult::ModifyElastictaskResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
ModifyElastictaskResult::~ModifyElastictaskResult()
|
||||
{}
|
||||
|
||||
void ModifyElastictaskResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
auto resultNode = value["Result"];
|
||||
auto elasticExpansionTaskNode = resultNode["ElasticExpansionTask"];
|
||||
if(!elasticExpansionTaskNode["TriggerType"].isNull())
|
||||
result_.elasticExpansionTask.triggerType = elasticExpansionTaskNode["TriggerType"].asString();
|
||||
if(!elasticExpansionTaskNode["CronExpression"].isNull())
|
||||
result_.elasticExpansionTask.cronExpression = elasticExpansionTaskNode["CronExpression"].asString();
|
||||
if(!elasticExpansionTaskNode["ElasticNodeCount"].isNull())
|
||||
result_.elasticExpansionTask.elasticNodeCount = std::stoi(elasticExpansionTaskNode["ElasticNodeCount"].asString());
|
||||
if(!elasticExpansionTaskNode["ReplicaCount"].isNull())
|
||||
result_.elasticExpansionTask.replicaCount = std::stoi(elasticExpansionTaskNode["ReplicaCount"].asString());
|
||||
auto allTargetIndices = elasticExpansionTaskNode["TargetIndices"]["TargetIndices"];
|
||||
for (auto value : allTargetIndices)
|
||||
result_.elasticExpansionTask.targetIndices.push_back(value.asString());
|
||||
auto elasticShrinkTaskNode = resultNode["ElasticShrinkTask"];
|
||||
if(!elasticShrinkTaskNode["TriggerType"].isNull())
|
||||
result_.elasticShrinkTask.triggerType = elasticShrinkTaskNode["TriggerType"].asString();
|
||||
if(!elasticShrinkTaskNode["CronExpression"].isNull())
|
||||
result_.elasticShrinkTask.cronExpression = elasticShrinkTaskNode["CronExpression"].asString();
|
||||
if(!elasticShrinkTaskNode["ElasticNodeCount"].isNull())
|
||||
result_.elasticShrinkTask.elasticNodeCount = std::stoi(elasticShrinkTaskNode["ElasticNodeCount"].asString());
|
||||
if(!elasticShrinkTaskNode["ReplicaCount"].isNull())
|
||||
result_.elasticShrinkTask.replicaCount = std::stoi(elasticShrinkTaskNode["ReplicaCount"].asString());
|
||||
auto allTargetIndices1 = elasticShrinkTaskNode["TargetIndices"]["TargetIndices"];
|
||||
for (auto value : allTargetIndices1)
|
||||
result_.elasticShrinkTask.targetIndices1.push_back(value.asString());
|
||||
|
||||
}
|
||||
|
||||
ModifyElastictaskResult::Result ModifyElastictaskResult::getResult()const
|
||||
{
|
||||
return result_;
|
||||
}
|
||||
|
||||
@@ -28,6 +28,17 @@ ShrinkNodeRequest::ShrinkNodeRequest() :
|
||||
ShrinkNodeRequest::~ShrinkNodeRequest()
|
||||
{}
|
||||
|
||||
bool ShrinkNodeRequest::getIgnoreStatus()const
|
||||
{
|
||||
return ignoreStatus_;
|
||||
}
|
||||
|
||||
void ShrinkNodeRequest::setIgnoreStatus(bool ignoreStatus)
|
||||
{
|
||||
ignoreStatus_ = ignoreStatus;
|
||||
setParameter("IgnoreStatus", ignoreStatus ? "true" : "false");
|
||||
}
|
||||
|
||||
std::string ShrinkNodeRequest::getInstanceId()const
|
||||
{
|
||||
return instanceId_;
|
||||
|
||||
@@ -28,6 +28,17 @@ UpdateInstanceRequest::UpdateInstanceRequest() :
|
||||
UpdateInstanceRequest::~UpdateInstanceRequest()
|
||||
{}
|
||||
|
||||
bool UpdateInstanceRequest::getIgnoreStatus()const
|
||||
{
|
||||
return ignoreStatus_;
|
||||
}
|
||||
|
||||
void UpdateInstanceRequest::setIgnoreStatus(bool ignoreStatus)
|
||||
{
|
||||
ignoreStatus_ = ignoreStatus;
|
||||
setParameter("IgnoreStatus", ignoreStatus ? "true" : "false");
|
||||
}
|
||||
|
||||
std::string UpdateInstanceRequest::getInstanceId()const
|
||||
{
|
||||
return instanceId_;
|
||||
|
||||
@@ -22,7 +22,7 @@ UpdateLogstashRequest::UpdateLogstashRequest() :
|
||||
RoaServiceRequest("elasticsearch", "2017-06-13")
|
||||
{
|
||||
setResourcePath("/openapi/logstashes/[InstanceId]");
|
||||
setMethod(HttpRequest::Method::Get);
|
||||
setMethod(HttpRequest::Method::Put);
|
||||
}
|
||||
|
||||
UpdateLogstashRequest::~UpdateLogstashRequest()
|
||||
|
||||
@@ -28,6 +28,17 @@ ValidateShrinkNodesRequest::ValidateShrinkNodesRequest() :
|
||||
ValidateShrinkNodesRequest::~ValidateShrinkNodesRequest()
|
||||
{}
|
||||
|
||||
bool ValidateShrinkNodesRequest::getIgnoreStatus()const
|
||||
{
|
||||
return ignoreStatus_;
|
||||
}
|
||||
|
||||
void ValidateShrinkNodesRequest::setIgnoreStatus(bool ignoreStatus)
|
||||
{
|
||||
ignoreStatus_ = ignoreStatus;
|
||||
setParameter("IgnoreStatus", ignoreStatus ? "true" : "false");
|
||||
}
|
||||
|
||||
std::string ValidateShrinkNodesRequest::getInstanceId()const
|
||||
{
|
||||
return instanceId_;
|
||||
|
||||
Reference in New Issue
Block a user