Add QueryCubePerformance, QueryComponentPerformance, QueryCubeOptimization, and QueryReportPerformance APIs.
This commit is contained in:
@@ -105,6 +105,12 @@ set(quickbi-public_public_header_model
|
||||
include/alibabacloud/quickbi-public/model/ListUserGroupsByUserIdResult.h
|
||||
include/alibabacloud/quickbi-public/model/ModifyApiDatasourceParametersRequest.h
|
||||
include/alibabacloud/quickbi-public/model/ModifyApiDatasourceParametersResult.h
|
||||
include/alibabacloud/quickbi-public/model/QueryComponentPerformanceRequest.h
|
||||
include/alibabacloud/quickbi-public/model/QueryComponentPerformanceResult.h
|
||||
include/alibabacloud/quickbi-public/model/QueryCubeOptimizationRequest.h
|
||||
include/alibabacloud/quickbi-public/model/QueryCubeOptimizationResult.h
|
||||
include/alibabacloud/quickbi-public/model/QueryCubePerformanceRequest.h
|
||||
include/alibabacloud/quickbi-public/model/QueryCubePerformanceResult.h
|
||||
include/alibabacloud/quickbi-public/model/QueryDataServiceRequest.h
|
||||
include/alibabacloud/quickbi-public/model/QueryDataServiceResult.h
|
||||
include/alibabacloud/quickbi-public/model/QueryDatasetDetailInfoRequest.h
|
||||
@@ -123,6 +129,8 @@ set(quickbi-public_public_header_model
|
||||
include/alibabacloud/quickbi-public/model/QueryOrganizationWorkspaceListResult.h
|
||||
include/alibabacloud/quickbi-public/model/QueryReadableResourcesListByUserIdRequest.h
|
||||
include/alibabacloud/quickbi-public/model/QueryReadableResourcesListByUserIdResult.h
|
||||
include/alibabacloud/quickbi-public/model/QueryReportPerformanceRequest.h
|
||||
include/alibabacloud/quickbi-public/model/QueryReportPerformanceResult.h
|
||||
include/alibabacloud/quickbi-public/model/QueryShareListRequest.h
|
||||
include/alibabacloud/quickbi-public/model/QueryShareListResult.h
|
||||
include/alibabacloud/quickbi-public/model/QuerySharesToUserListRequest.h
|
||||
@@ -272,6 +280,12 @@ set(quickbi-public_src
|
||||
src/model/ListUserGroupsByUserIdResult.cc
|
||||
src/model/ModifyApiDatasourceParametersRequest.cc
|
||||
src/model/ModifyApiDatasourceParametersResult.cc
|
||||
src/model/QueryComponentPerformanceRequest.cc
|
||||
src/model/QueryComponentPerformanceResult.cc
|
||||
src/model/QueryCubeOptimizationRequest.cc
|
||||
src/model/QueryCubeOptimizationResult.cc
|
||||
src/model/QueryCubePerformanceRequest.cc
|
||||
src/model/QueryCubePerformanceResult.cc
|
||||
src/model/QueryDataServiceRequest.cc
|
||||
src/model/QueryDataServiceResult.cc
|
||||
src/model/QueryDatasetDetailInfoRequest.cc
|
||||
@@ -290,6 +304,8 @@ set(quickbi-public_src
|
||||
src/model/QueryOrganizationWorkspaceListResult.cc
|
||||
src/model/QueryReadableResourcesListByUserIdRequest.cc
|
||||
src/model/QueryReadableResourcesListByUserIdResult.cc
|
||||
src/model/QueryReportPerformanceRequest.cc
|
||||
src/model/QueryReportPerformanceResult.cc
|
||||
src/model/QueryShareListRequest.cc
|
||||
src/model/QueryShareListResult.cc
|
||||
src/model/QuerySharesToUserListRequest.cc
|
||||
|
||||
@@ -106,6 +106,12 @@
|
||||
#include "model/ListUserGroupsByUserIdResult.h"
|
||||
#include "model/ModifyApiDatasourceParametersRequest.h"
|
||||
#include "model/ModifyApiDatasourceParametersResult.h"
|
||||
#include "model/QueryComponentPerformanceRequest.h"
|
||||
#include "model/QueryComponentPerformanceResult.h"
|
||||
#include "model/QueryCubeOptimizationRequest.h"
|
||||
#include "model/QueryCubeOptimizationResult.h"
|
||||
#include "model/QueryCubePerformanceRequest.h"
|
||||
#include "model/QueryCubePerformanceResult.h"
|
||||
#include "model/QueryDataServiceRequest.h"
|
||||
#include "model/QueryDataServiceResult.h"
|
||||
#include "model/QueryDatasetDetailInfoRequest.h"
|
||||
@@ -124,6 +130,8 @@
|
||||
#include "model/QueryOrganizationWorkspaceListResult.h"
|
||||
#include "model/QueryReadableResourcesListByUserIdRequest.h"
|
||||
#include "model/QueryReadableResourcesListByUserIdResult.h"
|
||||
#include "model/QueryReportPerformanceRequest.h"
|
||||
#include "model/QueryReportPerformanceResult.h"
|
||||
#include "model/QueryShareListRequest.h"
|
||||
#include "model/QueryShareListResult.h"
|
||||
#include "model/QuerySharesToUserListRequest.h"
|
||||
@@ -321,6 +329,15 @@ namespace AlibabaCloud
|
||||
typedef Outcome<Error, Model::ModifyApiDatasourceParametersResult> ModifyApiDatasourceParametersOutcome;
|
||||
typedef std::future<ModifyApiDatasourceParametersOutcome> ModifyApiDatasourceParametersOutcomeCallable;
|
||||
typedef std::function<void(const Quickbi_publicClient*, const Model::ModifyApiDatasourceParametersRequest&, const ModifyApiDatasourceParametersOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> ModifyApiDatasourceParametersAsyncHandler;
|
||||
typedef Outcome<Error, Model::QueryComponentPerformanceResult> QueryComponentPerformanceOutcome;
|
||||
typedef std::future<QueryComponentPerformanceOutcome> QueryComponentPerformanceOutcomeCallable;
|
||||
typedef std::function<void(const Quickbi_publicClient*, const Model::QueryComponentPerformanceRequest&, const QueryComponentPerformanceOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> QueryComponentPerformanceAsyncHandler;
|
||||
typedef Outcome<Error, Model::QueryCubeOptimizationResult> QueryCubeOptimizationOutcome;
|
||||
typedef std::future<QueryCubeOptimizationOutcome> QueryCubeOptimizationOutcomeCallable;
|
||||
typedef std::function<void(const Quickbi_publicClient*, const Model::QueryCubeOptimizationRequest&, const QueryCubeOptimizationOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> QueryCubeOptimizationAsyncHandler;
|
||||
typedef Outcome<Error, Model::QueryCubePerformanceResult> QueryCubePerformanceOutcome;
|
||||
typedef std::future<QueryCubePerformanceOutcome> QueryCubePerformanceOutcomeCallable;
|
||||
typedef std::function<void(const Quickbi_publicClient*, const Model::QueryCubePerformanceRequest&, const QueryCubePerformanceOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> QueryCubePerformanceAsyncHandler;
|
||||
typedef Outcome<Error, Model::QueryDataServiceResult> QueryDataServiceOutcome;
|
||||
typedef std::future<QueryDataServiceOutcome> QueryDataServiceOutcomeCallable;
|
||||
typedef std::function<void(const Quickbi_publicClient*, const Model::QueryDataServiceRequest&, const QueryDataServiceOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> QueryDataServiceAsyncHandler;
|
||||
@@ -348,6 +365,9 @@ namespace AlibabaCloud
|
||||
typedef Outcome<Error, Model::QueryReadableResourcesListByUserIdResult> QueryReadableResourcesListByUserIdOutcome;
|
||||
typedef std::future<QueryReadableResourcesListByUserIdOutcome> QueryReadableResourcesListByUserIdOutcomeCallable;
|
||||
typedef std::function<void(const Quickbi_publicClient*, const Model::QueryReadableResourcesListByUserIdRequest&, const QueryReadableResourcesListByUserIdOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> QueryReadableResourcesListByUserIdAsyncHandler;
|
||||
typedef Outcome<Error, Model::QueryReportPerformanceResult> QueryReportPerformanceOutcome;
|
||||
typedef std::future<QueryReportPerformanceOutcome> QueryReportPerformanceOutcomeCallable;
|
||||
typedef std::function<void(const Quickbi_publicClient*, const Model::QueryReportPerformanceRequest&, const QueryReportPerformanceOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> QueryReportPerformanceAsyncHandler;
|
||||
typedef Outcome<Error, Model::QueryShareListResult> QueryShareListOutcome;
|
||||
typedef std::future<QueryShareListOutcome> QueryShareListOutcomeCallable;
|
||||
typedef std::function<void(const Quickbi_publicClient*, const Model::QueryShareListRequest&, const QueryShareListOutcome&, const std::shared_ptr<const AsyncCallerContext>&)> QueryShareListAsyncHandler;
|
||||
@@ -572,6 +592,15 @@ namespace AlibabaCloud
|
||||
ModifyApiDatasourceParametersOutcome modifyApiDatasourceParameters(const Model::ModifyApiDatasourceParametersRequest &request)const;
|
||||
void modifyApiDatasourceParametersAsync(const Model::ModifyApiDatasourceParametersRequest& request, const ModifyApiDatasourceParametersAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
ModifyApiDatasourceParametersOutcomeCallable modifyApiDatasourceParametersCallable(const Model::ModifyApiDatasourceParametersRequest& request) const;
|
||||
QueryComponentPerformanceOutcome queryComponentPerformance(const Model::QueryComponentPerformanceRequest &request)const;
|
||||
void queryComponentPerformanceAsync(const Model::QueryComponentPerformanceRequest& request, const QueryComponentPerformanceAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
QueryComponentPerformanceOutcomeCallable queryComponentPerformanceCallable(const Model::QueryComponentPerformanceRequest& request) const;
|
||||
QueryCubeOptimizationOutcome queryCubeOptimization(const Model::QueryCubeOptimizationRequest &request)const;
|
||||
void queryCubeOptimizationAsync(const Model::QueryCubeOptimizationRequest& request, const QueryCubeOptimizationAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
QueryCubeOptimizationOutcomeCallable queryCubeOptimizationCallable(const Model::QueryCubeOptimizationRequest& request) const;
|
||||
QueryCubePerformanceOutcome queryCubePerformance(const Model::QueryCubePerformanceRequest &request)const;
|
||||
void queryCubePerformanceAsync(const Model::QueryCubePerformanceRequest& request, const QueryCubePerformanceAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
QueryCubePerformanceOutcomeCallable queryCubePerformanceCallable(const Model::QueryCubePerformanceRequest& request) const;
|
||||
QueryDataServiceOutcome queryDataService(const Model::QueryDataServiceRequest &request)const;
|
||||
void queryDataServiceAsync(const Model::QueryDataServiceRequest& request, const QueryDataServiceAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
QueryDataServiceOutcomeCallable queryDataServiceCallable(const Model::QueryDataServiceRequest& request) const;
|
||||
@@ -599,6 +628,9 @@ namespace AlibabaCloud
|
||||
QueryReadableResourcesListByUserIdOutcome queryReadableResourcesListByUserId(const Model::QueryReadableResourcesListByUserIdRequest &request)const;
|
||||
void queryReadableResourcesListByUserIdAsync(const Model::QueryReadableResourcesListByUserIdRequest& request, const QueryReadableResourcesListByUserIdAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
QueryReadableResourcesListByUserIdOutcomeCallable queryReadableResourcesListByUserIdCallable(const Model::QueryReadableResourcesListByUserIdRequest& request) const;
|
||||
QueryReportPerformanceOutcome queryReportPerformance(const Model::QueryReportPerformanceRequest &request)const;
|
||||
void queryReportPerformanceAsync(const Model::QueryReportPerformanceRequest& request, const QueryReportPerformanceAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
QueryReportPerformanceOutcomeCallable queryReportPerformanceCallable(const Model::QueryReportPerformanceRequest& request) const;
|
||||
QueryShareListOutcome queryShareList(const Model::QueryShareListRequest &request)const;
|
||||
void queryShareListAsync(const Model::QueryShareListRequest& request, const QueryShareListAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context = nullptr) const;
|
||||
QueryShareListOutcomeCallable queryShareListCallable(const Model::QueryShareListRequest& request) const;
|
||||
|
||||
@@ -0,0 +1,66 @@
|
||||
/*
|
||||
* 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_QUICKBI_PUBLIC_MODEL_QUERYCOMPONENTPERFORMANCEREQUEST_H_
|
||||
#define ALIBABACLOUD_QUICKBI_PUBLIC_MODEL_QUERYCOMPONENTPERFORMANCEREQUEST_H_
|
||||
|
||||
#include <alibabacloud/quickbi-public/Quickbi_publicExport.h>
|
||||
#include <alibabacloud/core/RpcServiceRequest.h>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <map>
|
||||
|
||||
namespace AlibabaCloud {
|
||||
namespace Quickbi_public {
|
||||
namespace Model {
|
||||
class ALIBABACLOUD_QUICKBI_PUBLIC_EXPORT QueryComponentPerformanceRequest : public RpcServiceRequest {
|
||||
public:
|
||||
QueryComponentPerformanceRequest();
|
||||
~QueryComponentPerformanceRequest();
|
||||
std::string getReportId() const;
|
||||
void setReportId(const std::string &reportId);
|
||||
std::string getAccessPoint() const;
|
||||
void setAccessPoint(const std::string &accessPoint);
|
||||
std::string getSignType() const;
|
||||
void setSignType(const std::string &signType);
|
||||
int getPageNum() const;
|
||||
void setPageNum(int pageNum);
|
||||
std::string getResourceType() const;
|
||||
void setResourceType(const std::string &resourceType);
|
||||
int getPageSize() const;
|
||||
void setPageSize(int pageSize);
|
||||
int getCostTimeAvgMin() const;
|
||||
void setCostTimeAvgMin(int costTimeAvgMin);
|
||||
std::string getQueryType() const;
|
||||
void setQueryType(const std::string &queryType);
|
||||
std::string getWorkspaceId() const;
|
||||
void setWorkspaceId(const std::string &workspaceId);
|
||||
|
||||
private:
|
||||
std::string reportId_;
|
||||
std::string accessPoint_;
|
||||
std::string signType_;
|
||||
int pageNum_;
|
||||
std::string resourceType_;
|
||||
int pageSize_;
|
||||
int costTimeAvgMin_;
|
||||
std::string queryType_;
|
||||
std::string workspaceId_;
|
||||
};
|
||||
} // namespace Model
|
||||
} // namespace Quickbi_public
|
||||
} // namespace AlibabaCloud
|
||||
#endif // !ALIBABACLOUD_QUICKBI_PUBLIC_MODEL_QUERYCOMPONENTPERFORMANCEREQUEST_H_
|
||||
@@ -0,0 +1,80 @@
|
||||
/*
|
||||
* 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_QUICKBI_PUBLIC_MODEL_QUERYCOMPONENTPERFORMANCERESULT_H_
|
||||
#define ALIBABACLOUD_QUICKBI_PUBLIC_MODEL_QUERYCOMPONENTPERFORMANCERESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/quickbi-public/Quickbi_publicExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Quickbi_public
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_QUICKBI_PUBLIC_EXPORT QueryComponentPerformanceResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
struct Data
|
||||
{
|
||||
double queryTimeoutCountPercent;
|
||||
double queryOverTenSecPercentNum;
|
||||
std::string repeatSqlQueryPercent;
|
||||
std::string workspaceId;
|
||||
std::string reportId;
|
||||
std::string queryOverTenSecPercent;
|
||||
int quickIndexQueryCount;
|
||||
int queryTimeoutCount;
|
||||
int cacheQueryCount;
|
||||
double cacheCostTimeAvg;
|
||||
double quickIndexCostTimeAvg;
|
||||
double queryCountAvg;
|
||||
std::string reportName;
|
||||
double costTimeAvg;
|
||||
int queryCount;
|
||||
std::string workspaceName;
|
||||
std::string componentName;
|
||||
double repeatQueryPercentNum;
|
||||
int repeatSqlQueryCount;
|
||||
double queryOverFivePercentNum;
|
||||
std::string queryOverFiveSecPercent;
|
||||
std::string componentId;
|
||||
std::string reportType;
|
||||
std::string repeatQueryPercent;
|
||||
};
|
||||
|
||||
|
||||
QueryComponentPerformanceResult();
|
||||
explicit QueryComponentPerformanceResult(const std::string &payload);
|
||||
~QueryComponentPerformanceResult();
|
||||
bool getSuccess()const;
|
||||
std::vector<Data> getResult()const;
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
bool success_;
|
||||
std::vector<Data> result_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_QUICKBI_PUBLIC_MODEL_QUERYCOMPONENTPERFORMANCERESULT_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_QUICKBI_PUBLIC_MODEL_QUERYCUBEOPTIMIZATIONREQUEST_H_
|
||||
#define ALIBABACLOUD_QUICKBI_PUBLIC_MODEL_QUERYCUBEOPTIMIZATIONREQUEST_H_
|
||||
|
||||
#include <alibabacloud/quickbi-public/Quickbi_publicExport.h>
|
||||
#include <alibabacloud/core/RpcServiceRequest.h>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <map>
|
||||
|
||||
namespace AlibabaCloud {
|
||||
namespace Quickbi_public {
|
||||
namespace Model {
|
||||
class ALIBABACLOUD_QUICKBI_PUBLIC_EXPORT QueryCubeOptimizationRequest : public RpcServiceRequest {
|
||||
public:
|
||||
QueryCubeOptimizationRequest();
|
||||
~QueryCubeOptimizationRequest();
|
||||
std::string getAccessPoint() const;
|
||||
void setAccessPoint(const std::string &accessPoint);
|
||||
std::string getSignType() const;
|
||||
void setSignType(const std::string &signType);
|
||||
std::string getWorkspaceId() const;
|
||||
void setWorkspaceId(const std::string &workspaceId);
|
||||
|
||||
private:
|
||||
std::string accessPoint_;
|
||||
std::string signType_;
|
||||
std::string workspaceId_;
|
||||
};
|
||||
} // namespace Model
|
||||
} // namespace Quickbi_public
|
||||
} // namespace AlibabaCloud
|
||||
#endif // !ALIBABACLOUD_QUICKBI_PUBLIC_MODEL_QUERYCUBEOPTIMIZATIONREQUEST_H_
|
||||
@@ -0,0 +1,82 @@
|
||||
/*
|
||||
* 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_QUICKBI_PUBLIC_MODEL_QUERYCUBEOPTIMIZATIONRESULT_H_
|
||||
#define ALIBABACLOUD_QUICKBI_PUBLIC_MODEL_QUERYCUBEOPTIMIZATIONRESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/quickbi-public/Quickbi_publicExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Quickbi_public
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_QUICKBI_PUBLIC_EXPORT QueryCubeOptimizationResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
struct Data
|
||||
{
|
||||
struct CubePerformanceDiagnoseModel
|
||||
{
|
||||
double queryTimeoutCountPercent;
|
||||
std::string cubeId;
|
||||
double queryOverTenSecPercentNum;
|
||||
std::string repeatSqlQueryPercent;
|
||||
std::string workspaceId;
|
||||
std::string queryOverTenSecPercent;
|
||||
int quickIndexQueryCount;
|
||||
int queryTimeoutCount;
|
||||
int cacheQueryCount;
|
||||
double cacheCostTimeAvg;
|
||||
double quickIndexCostTimeAvg;
|
||||
double queryCountAvg;
|
||||
std::string cubeName;
|
||||
double costTimeAvg;
|
||||
int queryCount;
|
||||
std::string workspaceName;
|
||||
double repeatQueryPercentNum;
|
||||
int repeatSqlQueryCount;
|
||||
double queryOverFivePercentNum;
|
||||
std::string queryOverFiveSecPercent;
|
||||
std::string repeatQueryPercent;
|
||||
};
|
||||
std::string adviceType;
|
||||
CubePerformanceDiagnoseModel cubePerformanceDiagnoseModel;
|
||||
};
|
||||
|
||||
|
||||
QueryCubeOptimizationResult();
|
||||
explicit QueryCubeOptimizationResult(const std::string &payload);
|
||||
~QueryCubeOptimizationResult();
|
||||
bool getSuccess()const;
|
||||
std::vector<Data> getResult()const;
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
bool success_;
|
||||
std::vector<Data> result_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_QUICKBI_PUBLIC_MODEL_QUERYCUBEOPTIMIZATIONRESULT_H_
|
||||
@@ -0,0 +1,63 @@
|
||||
/*
|
||||
* 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_QUICKBI_PUBLIC_MODEL_QUERYCUBEPERFORMANCEREQUEST_H_
|
||||
#define ALIBABACLOUD_QUICKBI_PUBLIC_MODEL_QUERYCUBEPERFORMANCEREQUEST_H_
|
||||
|
||||
#include <alibabacloud/quickbi-public/Quickbi_publicExport.h>
|
||||
#include <alibabacloud/core/RpcServiceRequest.h>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <map>
|
||||
|
||||
namespace AlibabaCloud {
|
||||
namespace Quickbi_public {
|
||||
namespace Model {
|
||||
class ALIBABACLOUD_QUICKBI_PUBLIC_EXPORT QueryCubePerformanceRequest : public RpcServiceRequest {
|
||||
public:
|
||||
QueryCubePerformanceRequest();
|
||||
~QueryCubePerformanceRequest();
|
||||
std::string getAccessPoint() const;
|
||||
void setAccessPoint(const std::string &accessPoint);
|
||||
std::string getSignType() const;
|
||||
void setSignType(const std::string &signType);
|
||||
int getPageNum() const;
|
||||
void setPageNum(int pageNum);
|
||||
int getPageSize() const;
|
||||
void setPageSize(int pageSize);
|
||||
int getCostTimeAvgMin() const;
|
||||
void setCostTimeAvgMin(int costTimeAvgMin);
|
||||
std::string getQueryType() const;
|
||||
void setQueryType(const std::string &queryType);
|
||||
std::string getCubeId() const;
|
||||
void setCubeId(const std::string &cubeId);
|
||||
std::string getWorkspaceId() const;
|
||||
void setWorkspaceId(const std::string &workspaceId);
|
||||
|
||||
private:
|
||||
std::string accessPoint_;
|
||||
std::string signType_;
|
||||
int pageNum_;
|
||||
int pageSize_;
|
||||
int costTimeAvgMin_;
|
||||
std::string queryType_;
|
||||
std::string cubeId_;
|
||||
std::string workspaceId_;
|
||||
};
|
||||
} // namespace Model
|
||||
} // namespace Quickbi_public
|
||||
} // namespace AlibabaCloud
|
||||
#endif // !ALIBABACLOUD_QUICKBI_PUBLIC_MODEL_QUERYCUBEPERFORMANCEREQUEST_H_
|
||||
@@ -0,0 +1,77 @@
|
||||
/*
|
||||
* 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_QUICKBI_PUBLIC_MODEL_QUERYCUBEPERFORMANCERESULT_H_
|
||||
#define ALIBABACLOUD_QUICKBI_PUBLIC_MODEL_QUERYCUBEPERFORMANCERESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/quickbi-public/Quickbi_publicExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Quickbi_public
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_QUICKBI_PUBLIC_EXPORT QueryCubePerformanceResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
struct Data
|
||||
{
|
||||
double queryTimeoutCountPercent;
|
||||
std::string cubeId;
|
||||
double queryOverTenSecPercentNum;
|
||||
std::string repeatSqlQueryPercent;
|
||||
std::string workspaceId;
|
||||
std::string queryOverTenSecPercent;
|
||||
int quickIndexQueryCount;
|
||||
int queryTimeoutCount;
|
||||
int cacheQueryCount;
|
||||
double cacheCostTimeAvg;
|
||||
double quickIndexCostTimeAvg;
|
||||
double queryCountAvg;
|
||||
std::string cubeName;
|
||||
double costTimeAvg;
|
||||
int queryCount;
|
||||
std::string workspaceName;
|
||||
double repeatQueryPercentNum;
|
||||
int repeatSqlQueryCount;
|
||||
double queryOverFivePercentNum;
|
||||
std::string queryOverFiveSecPercent;
|
||||
std::string repeatQueryPercent;
|
||||
};
|
||||
|
||||
|
||||
QueryCubePerformanceResult();
|
||||
explicit QueryCubePerformanceResult(const std::string &payload);
|
||||
~QueryCubePerformanceResult();
|
||||
bool getSuccess()const;
|
||||
std::vector<Data> getResult()const;
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
bool success_;
|
||||
std::vector<Data> result_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_QUICKBI_PUBLIC_MODEL_QUERYCUBEPERFORMANCERESULT_H_
|
||||
@@ -0,0 +1,66 @@
|
||||
/*
|
||||
* 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_QUICKBI_PUBLIC_MODEL_QUERYREPORTPERFORMANCEREQUEST_H_
|
||||
#define ALIBABACLOUD_QUICKBI_PUBLIC_MODEL_QUERYREPORTPERFORMANCEREQUEST_H_
|
||||
|
||||
#include <alibabacloud/quickbi-public/Quickbi_publicExport.h>
|
||||
#include <alibabacloud/core/RpcServiceRequest.h>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <map>
|
||||
|
||||
namespace AlibabaCloud {
|
||||
namespace Quickbi_public {
|
||||
namespace Model {
|
||||
class ALIBABACLOUD_QUICKBI_PUBLIC_EXPORT QueryReportPerformanceRequest : public RpcServiceRequest {
|
||||
public:
|
||||
QueryReportPerformanceRequest();
|
||||
~QueryReportPerformanceRequest();
|
||||
std::string getReportId() const;
|
||||
void setReportId(const std::string &reportId);
|
||||
std::string getAccessPoint() const;
|
||||
void setAccessPoint(const std::string &accessPoint);
|
||||
std::string getSignType() const;
|
||||
void setSignType(const std::string &signType);
|
||||
int getPageNum() const;
|
||||
void setPageNum(int pageNum);
|
||||
std::string getResourceType() const;
|
||||
void setResourceType(const std::string &resourceType);
|
||||
int getPageSize() const;
|
||||
void setPageSize(int pageSize);
|
||||
int getCostTimeAvgMin() const;
|
||||
void setCostTimeAvgMin(int costTimeAvgMin);
|
||||
std::string getQueryType() const;
|
||||
void setQueryType(const std::string &queryType);
|
||||
std::string getWorkspaceId() const;
|
||||
void setWorkspaceId(const std::string &workspaceId);
|
||||
|
||||
private:
|
||||
std::string reportId_;
|
||||
std::string accessPoint_;
|
||||
std::string signType_;
|
||||
int pageNum_;
|
||||
std::string resourceType_;
|
||||
int pageSize_;
|
||||
int costTimeAvgMin_;
|
||||
std::string queryType_;
|
||||
std::string workspaceId_;
|
||||
};
|
||||
} // namespace Model
|
||||
} // namespace Quickbi_public
|
||||
} // namespace AlibabaCloud
|
||||
#endif // !ALIBABACLOUD_QUICKBI_PUBLIC_MODEL_QUERYREPORTPERFORMANCEREQUEST_H_
|
||||
@@ -0,0 +1,80 @@
|
||||
/*
|
||||
* 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_QUICKBI_PUBLIC_MODEL_QUERYREPORTPERFORMANCERESULT_H_
|
||||
#define ALIBABACLOUD_QUICKBI_PUBLIC_MODEL_QUERYREPORTPERFORMANCERESULT_H_
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <utility>
|
||||
#include <alibabacloud/core/ServiceResult.h>
|
||||
#include <alibabacloud/quickbi-public/Quickbi_publicExport.h>
|
||||
|
||||
namespace AlibabaCloud
|
||||
{
|
||||
namespace Quickbi_public
|
||||
{
|
||||
namespace Model
|
||||
{
|
||||
class ALIBABACLOUD_QUICKBI_PUBLIC_EXPORT QueryReportPerformanceResult : public ServiceResult
|
||||
{
|
||||
public:
|
||||
struct Data
|
||||
{
|
||||
double queryTimeoutCountPercent;
|
||||
double queryOverTenSecPercentNum;
|
||||
std::string repeatSqlQueryPercent;
|
||||
std::string workspaceId;
|
||||
std::string reportId;
|
||||
std::string queryOverTenSecPercent;
|
||||
int quickIndexQueryCount;
|
||||
int queryTimeoutCount;
|
||||
int cacheQueryCount;
|
||||
double cacheCostTimeAvg;
|
||||
double quickIndexCostTimeAvg;
|
||||
double queryCountAvg;
|
||||
std::string reportName;
|
||||
int componentQueryCount;
|
||||
double costTimeAvg;
|
||||
int queryCount;
|
||||
std::string workspaceName;
|
||||
double repeatQueryPercentNum;
|
||||
int repeatSqlQueryCount;
|
||||
double queryOverFivePercentNum;
|
||||
std::string queryOverFiveSecPercent;
|
||||
std::string reportType;
|
||||
std::string repeatQueryPercent;
|
||||
double componentQueryCountAvg;
|
||||
};
|
||||
|
||||
|
||||
QueryReportPerformanceResult();
|
||||
explicit QueryReportPerformanceResult(const std::string &payload);
|
||||
~QueryReportPerformanceResult();
|
||||
bool getSuccess()const;
|
||||
std::vector<Data> getResult()const;
|
||||
|
||||
protected:
|
||||
void parse(const std::string &payload);
|
||||
private:
|
||||
bool success_;
|
||||
std::vector<Data> result_;
|
||||
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif // !ALIBABACLOUD_QUICKBI_PUBLIC_MODEL_QUERYREPORTPERFORMANCERESULT_H_
|
||||
@@ -1563,6 +1563,114 @@ Quickbi_publicClient::ModifyApiDatasourceParametersOutcomeCallable Quickbi_publi
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
Quickbi_publicClient::QueryComponentPerformanceOutcome Quickbi_publicClient::queryComponentPerformance(const QueryComponentPerformanceRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return QueryComponentPerformanceOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return QueryComponentPerformanceOutcome(QueryComponentPerformanceResult(outcome.result()));
|
||||
else
|
||||
return QueryComponentPerformanceOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void Quickbi_publicClient::queryComponentPerformanceAsync(const QueryComponentPerformanceRequest& request, const QueryComponentPerformanceAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, queryComponentPerformance(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
Quickbi_publicClient::QueryComponentPerformanceOutcomeCallable Quickbi_publicClient::queryComponentPerformanceCallable(const QueryComponentPerformanceRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<QueryComponentPerformanceOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->queryComponentPerformance(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
Quickbi_publicClient::QueryCubeOptimizationOutcome Quickbi_publicClient::queryCubeOptimization(const QueryCubeOptimizationRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return QueryCubeOptimizationOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return QueryCubeOptimizationOutcome(QueryCubeOptimizationResult(outcome.result()));
|
||||
else
|
||||
return QueryCubeOptimizationOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void Quickbi_publicClient::queryCubeOptimizationAsync(const QueryCubeOptimizationRequest& request, const QueryCubeOptimizationAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, queryCubeOptimization(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
Quickbi_publicClient::QueryCubeOptimizationOutcomeCallable Quickbi_publicClient::queryCubeOptimizationCallable(const QueryCubeOptimizationRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<QueryCubeOptimizationOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->queryCubeOptimization(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
Quickbi_publicClient::QueryCubePerformanceOutcome Quickbi_publicClient::queryCubePerformance(const QueryCubePerformanceRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return QueryCubePerformanceOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return QueryCubePerformanceOutcome(QueryCubePerformanceResult(outcome.result()));
|
||||
else
|
||||
return QueryCubePerformanceOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void Quickbi_publicClient::queryCubePerformanceAsync(const QueryCubePerformanceRequest& request, const QueryCubePerformanceAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, queryCubePerformance(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
Quickbi_publicClient::QueryCubePerformanceOutcomeCallable Quickbi_publicClient::queryCubePerformanceCallable(const QueryCubePerformanceRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<QueryCubePerformanceOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->queryCubePerformance(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
Quickbi_publicClient::QueryDataServiceOutcome Quickbi_publicClient::queryDataService(const QueryDataServiceRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
@@ -1887,6 +1995,42 @@ Quickbi_publicClient::QueryReadableResourcesListByUserIdOutcomeCallable Quickbi_
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
Quickbi_publicClient::QueryReportPerformanceOutcome Quickbi_publicClient::queryReportPerformance(const QueryReportPerformanceRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
if (!endpointOutcome.isSuccess())
|
||||
return QueryReportPerformanceOutcome(endpointOutcome.error());
|
||||
|
||||
auto outcome = makeRequest(endpointOutcome.result(), request);
|
||||
|
||||
if (outcome.isSuccess())
|
||||
return QueryReportPerformanceOutcome(QueryReportPerformanceResult(outcome.result()));
|
||||
else
|
||||
return QueryReportPerformanceOutcome(outcome.error());
|
||||
}
|
||||
|
||||
void Quickbi_publicClient::queryReportPerformanceAsync(const QueryReportPerformanceRequest& request, const QueryReportPerformanceAsyncHandler& handler, const std::shared_ptr<const AsyncCallerContext>& context) const
|
||||
{
|
||||
auto fn = [this, request, handler, context]()
|
||||
{
|
||||
handler(this, request, queryReportPerformance(request), context);
|
||||
};
|
||||
|
||||
asyncExecute(new Runnable(fn));
|
||||
}
|
||||
|
||||
Quickbi_publicClient::QueryReportPerformanceOutcomeCallable Quickbi_publicClient::queryReportPerformanceCallable(const QueryReportPerformanceRequest &request) const
|
||||
{
|
||||
auto task = std::make_shared<std::packaged_task<QueryReportPerformanceOutcome()>>(
|
||||
[this, request]()
|
||||
{
|
||||
return this->queryReportPerformance(request);
|
||||
});
|
||||
|
||||
asyncExecute(new Runnable([task]() { (*task)(); }));
|
||||
return task->get_future();
|
||||
}
|
||||
|
||||
Quickbi_publicClient::QueryShareListOutcome Quickbi_publicClient::queryShareList(const QueryShareListRequest &request) const
|
||||
{
|
||||
auto endpointOutcome = endpointProvider_->getEndpoint();
|
||||
|
||||
108
quickbi-public/src/model/QueryComponentPerformanceRequest.cc
Normal file
108
quickbi-public/src/model/QueryComponentPerformanceRequest.cc
Normal file
@@ -0,0 +1,108 @@
|
||||
/*
|
||||
* 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/quickbi-public/model/QueryComponentPerformanceRequest.h>
|
||||
|
||||
using AlibabaCloud::Quickbi_public::Model::QueryComponentPerformanceRequest;
|
||||
|
||||
QueryComponentPerformanceRequest::QueryComponentPerformanceRequest()
|
||||
: RpcServiceRequest("quickbi-public", "2022-01-01", "QueryComponentPerformance") {
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
QueryComponentPerformanceRequest::~QueryComponentPerformanceRequest() {}
|
||||
|
||||
std::string QueryComponentPerformanceRequest::getReportId() const {
|
||||
return reportId_;
|
||||
}
|
||||
|
||||
void QueryComponentPerformanceRequest::setReportId(const std::string &reportId) {
|
||||
reportId_ = reportId;
|
||||
setParameter(std::string("ReportId"), reportId);
|
||||
}
|
||||
|
||||
std::string QueryComponentPerformanceRequest::getAccessPoint() const {
|
||||
return accessPoint_;
|
||||
}
|
||||
|
||||
void QueryComponentPerformanceRequest::setAccessPoint(const std::string &accessPoint) {
|
||||
accessPoint_ = accessPoint;
|
||||
setParameter(std::string("AccessPoint"), accessPoint);
|
||||
}
|
||||
|
||||
std::string QueryComponentPerformanceRequest::getSignType() const {
|
||||
return signType_;
|
||||
}
|
||||
|
||||
void QueryComponentPerformanceRequest::setSignType(const std::string &signType) {
|
||||
signType_ = signType;
|
||||
setParameter(std::string("SignType"), signType);
|
||||
}
|
||||
|
||||
int QueryComponentPerformanceRequest::getPageNum() const {
|
||||
return pageNum_;
|
||||
}
|
||||
|
||||
void QueryComponentPerformanceRequest::setPageNum(int pageNum) {
|
||||
pageNum_ = pageNum;
|
||||
setParameter(std::string("PageNum"), std::to_string(pageNum));
|
||||
}
|
||||
|
||||
std::string QueryComponentPerformanceRequest::getResourceType() const {
|
||||
return resourceType_;
|
||||
}
|
||||
|
||||
void QueryComponentPerformanceRequest::setResourceType(const std::string &resourceType) {
|
||||
resourceType_ = resourceType;
|
||||
setParameter(std::string("ResourceType"), resourceType);
|
||||
}
|
||||
|
||||
int QueryComponentPerformanceRequest::getPageSize() const {
|
||||
return pageSize_;
|
||||
}
|
||||
|
||||
void QueryComponentPerformanceRequest::setPageSize(int pageSize) {
|
||||
pageSize_ = pageSize;
|
||||
setParameter(std::string("PageSize"), std::to_string(pageSize));
|
||||
}
|
||||
|
||||
int QueryComponentPerformanceRequest::getCostTimeAvgMin() const {
|
||||
return costTimeAvgMin_;
|
||||
}
|
||||
|
||||
void QueryComponentPerformanceRequest::setCostTimeAvgMin(int costTimeAvgMin) {
|
||||
costTimeAvgMin_ = costTimeAvgMin;
|
||||
setParameter(std::string("CostTimeAvgMin"), std::to_string(costTimeAvgMin));
|
||||
}
|
||||
|
||||
std::string QueryComponentPerformanceRequest::getQueryType() const {
|
||||
return queryType_;
|
||||
}
|
||||
|
||||
void QueryComponentPerformanceRequest::setQueryType(const std::string &queryType) {
|
||||
queryType_ = queryType;
|
||||
setParameter(std::string("QueryType"), queryType);
|
||||
}
|
||||
|
||||
std::string QueryComponentPerformanceRequest::getWorkspaceId() const {
|
||||
return workspaceId_;
|
||||
}
|
||||
|
||||
void QueryComponentPerformanceRequest::setWorkspaceId(const std::string &workspaceId) {
|
||||
workspaceId_ = workspaceId;
|
||||
setParameter(std::string("WorkspaceId"), workspaceId);
|
||||
}
|
||||
|
||||
110
quickbi-public/src/model/QueryComponentPerformanceResult.cc
Normal file
110
quickbi-public/src/model/QueryComponentPerformanceResult.cc
Normal file
@@ -0,0 +1,110 @@
|
||||
/*
|
||||
* 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/quickbi-public/model/QueryComponentPerformanceResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Quickbi_public;
|
||||
using namespace AlibabaCloud::Quickbi_public::Model;
|
||||
|
||||
QueryComponentPerformanceResult::QueryComponentPerformanceResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
QueryComponentPerformanceResult::QueryComponentPerformanceResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
QueryComponentPerformanceResult::~QueryComponentPerformanceResult()
|
||||
{}
|
||||
|
||||
void QueryComponentPerformanceResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
auto allResultNode = value["Result"]["Data"];
|
||||
for (auto valueResultData : allResultNode)
|
||||
{
|
||||
Data resultObject;
|
||||
if(!valueResultData["ComponentId"].isNull())
|
||||
resultObject.componentId = valueResultData["ComponentId"].asString();
|
||||
if(!valueResultData["ComponentName"].isNull())
|
||||
resultObject.componentName = valueResultData["ComponentName"].asString();
|
||||
if(!valueResultData["ReportId"].isNull())
|
||||
resultObject.reportId = valueResultData["ReportId"].asString();
|
||||
if(!valueResultData["ReportName"].isNull())
|
||||
resultObject.reportName = valueResultData["ReportName"].asString();
|
||||
if(!valueResultData["ReportType"].isNull())
|
||||
resultObject.reportType = valueResultData["ReportType"].asString();
|
||||
if(!valueResultData["QueryTimeoutCount"].isNull())
|
||||
resultObject.queryTimeoutCount = std::stoi(valueResultData["QueryTimeoutCount"].asString());
|
||||
if(!valueResultData["RepeatSqlQueryPercent"].isNull())
|
||||
resultObject.repeatSqlQueryPercent = valueResultData["RepeatSqlQueryPercent"].asString();
|
||||
if(!valueResultData["WorkspaceName"].isNull())
|
||||
resultObject.workspaceName = valueResultData["WorkspaceName"].asString();
|
||||
if(!valueResultData["WorkspaceId"].isNull())
|
||||
resultObject.workspaceId = valueResultData["WorkspaceId"].asString();
|
||||
if(!valueResultData["RepeatQueryPercentNum"].isNull())
|
||||
resultObject.repeatQueryPercentNum = valueResultData["RepeatQueryPercentNum"].asString();
|
||||
if(!valueResultData["RepeatQueryPercent"].isNull())
|
||||
resultObject.repeatQueryPercent = valueResultData["RepeatQueryPercent"].asString();
|
||||
if(!valueResultData["QuickIndexCostTimeAvg"].isNull())
|
||||
resultObject.quickIndexCostTimeAvg = valueResultData["QuickIndexCostTimeAvg"].asString();
|
||||
if(!valueResultData["QuickIndexQueryCount"].isNull())
|
||||
resultObject.quickIndexQueryCount = std::stoi(valueResultData["QuickIndexQueryCount"].asString());
|
||||
if(!valueResultData["CacheCostTimeAvg"].isNull())
|
||||
resultObject.cacheCostTimeAvg = valueResultData["CacheCostTimeAvg"].asString();
|
||||
if(!valueResultData["CacheQueryCount"].isNull())
|
||||
resultObject.cacheQueryCount = std::stoi(valueResultData["CacheQueryCount"].asString());
|
||||
if(!valueResultData["RepeatSqlQueryCount"].isNull())
|
||||
resultObject.repeatSqlQueryCount = std::stoi(valueResultData["RepeatSqlQueryCount"].asString());
|
||||
if(!valueResultData["CostTimeAvg"].isNull())
|
||||
resultObject.costTimeAvg = valueResultData["CostTimeAvg"].asString();
|
||||
if(!valueResultData["QueryCountAvg"].isNull())
|
||||
resultObject.queryCountAvg = valueResultData["QueryCountAvg"].asString();
|
||||
if(!valueResultData["QueryCount"].isNull())
|
||||
resultObject.queryCount = std::stoi(valueResultData["QueryCount"].asString());
|
||||
if(!valueResultData["QueryTimeoutCountPercent"].isNull())
|
||||
resultObject.queryTimeoutCountPercent = valueResultData["QueryTimeoutCountPercent"].asString();
|
||||
if(!valueResultData["QueryOverTenSecPercentNum"].isNull())
|
||||
resultObject.queryOverTenSecPercentNum = valueResultData["QueryOverTenSecPercentNum"].asString();
|
||||
if(!valueResultData["QueryOverFivePercentNum"].isNull())
|
||||
resultObject.queryOverFivePercentNum = valueResultData["QueryOverFivePercentNum"].asString();
|
||||
if(!valueResultData["QueryOverTenSecPercent"].isNull())
|
||||
resultObject.queryOverTenSecPercent = valueResultData["QueryOverTenSecPercent"].asString();
|
||||
if(!valueResultData["QueryOverFiveSecPercent"].isNull())
|
||||
resultObject.queryOverFiveSecPercent = valueResultData["QueryOverFiveSecPercent"].asString();
|
||||
result_.push_back(resultObject);
|
||||
}
|
||||
if(!value["Success"].isNull())
|
||||
success_ = value["Success"].asString() == "true";
|
||||
|
||||
}
|
||||
|
||||
bool QueryComponentPerformanceResult::getSuccess()const
|
||||
{
|
||||
return success_;
|
||||
}
|
||||
|
||||
std::vector<QueryComponentPerformanceResult::Data> QueryComponentPerformanceResult::getResult()const
|
||||
{
|
||||
return result_;
|
||||
}
|
||||
|
||||
54
quickbi-public/src/model/QueryCubeOptimizationRequest.cc
Normal file
54
quickbi-public/src/model/QueryCubeOptimizationRequest.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/quickbi-public/model/QueryCubeOptimizationRequest.h>
|
||||
|
||||
using AlibabaCloud::Quickbi_public::Model::QueryCubeOptimizationRequest;
|
||||
|
||||
QueryCubeOptimizationRequest::QueryCubeOptimizationRequest()
|
||||
: RpcServiceRequest("quickbi-public", "2022-01-01", "QueryCubeOptimization") {
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
QueryCubeOptimizationRequest::~QueryCubeOptimizationRequest() {}
|
||||
|
||||
std::string QueryCubeOptimizationRequest::getAccessPoint() const {
|
||||
return accessPoint_;
|
||||
}
|
||||
|
||||
void QueryCubeOptimizationRequest::setAccessPoint(const std::string &accessPoint) {
|
||||
accessPoint_ = accessPoint;
|
||||
setParameter(std::string("AccessPoint"), accessPoint);
|
||||
}
|
||||
|
||||
std::string QueryCubeOptimizationRequest::getSignType() const {
|
||||
return signType_;
|
||||
}
|
||||
|
||||
void QueryCubeOptimizationRequest::setSignType(const std::string &signType) {
|
||||
signType_ = signType;
|
||||
setParameter(std::string("SignType"), signType);
|
||||
}
|
||||
|
||||
std::string QueryCubeOptimizationRequest::getWorkspaceId() const {
|
||||
return workspaceId_;
|
||||
}
|
||||
|
||||
void QueryCubeOptimizationRequest::setWorkspaceId(const std::string &workspaceId) {
|
||||
workspaceId_ = workspaceId;
|
||||
setParameter(std::string("WorkspaceId"), workspaceId);
|
||||
}
|
||||
|
||||
107
quickbi-public/src/model/QueryCubeOptimizationResult.cc
Normal file
107
quickbi-public/src/model/QueryCubeOptimizationResult.cc
Normal file
@@ -0,0 +1,107 @@
|
||||
/*
|
||||
* 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/quickbi-public/model/QueryCubeOptimizationResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Quickbi_public;
|
||||
using namespace AlibabaCloud::Quickbi_public::Model;
|
||||
|
||||
QueryCubeOptimizationResult::QueryCubeOptimizationResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
QueryCubeOptimizationResult::QueryCubeOptimizationResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
QueryCubeOptimizationResult::~QueryCubeOptimizationResult()
|
||||
{}
|
||||
|
||||
void QueryCubeOptimizationResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
auto allResultNode = value["Result"]["Data"];
|
||||
for (auto valueResultData : allResultNode)
|
||||
{
|
||||
Data resultObject;
|
||||
if(!valueResultData["AdviceType"].isNull())
|
||||
resultObject.adviceType = valueResultData["AdviceType"].asString();
|
||||
auto cubePerformanceDiagnoseModelNode = value["CubePerformanceDiagnoseModel"];
|
||||
if(!cubePerformanceDiagnoseModelNode["CubeId"].isNull())
|
||||
resultObject.cubePerformanceDiagnoseModel.cubeId = cubePerformanceDiagnoseModelNode["CubeId"].asString();
|
||||
if(!cubePerformanceDiagnoseModelNode["CubeName"].isNull())
|
||||
resultObject.cubePerformanceDiagnoseModel.cubeName = cubePerformanceDiagnoseModelNode["CubeName"].asString();
|
||||
if(!cubePerformanceDiagnoseModelNode["QueryTimeoutCount"].isNull())
|
||||
resultObject.cubePerformanceDiagnoseModel.queryTimeoutCount = std::stoi(cubePerformanceDiagnoseModelNode["QueryTimeoutCount"].asString());
|
||||
if(!cubePerformanceDiagnoseModelNode["RepeatSqlQueryPercent"].isNull())
|
||||
resultObject.cubePerformanceDiagnoseModel.repeatSqlQueryPercent = cubePerformanceDiagnoseModelNode["RepeatSqlQueryPercent"].asString();
|
||||
if(!cubePerformanceDiagnoseModelNode["WorkspaceName"].isNull())
|
||||
resultObject.cubePerformanceDiagnoseModel.workspaceName = cubePerformanceDiagnoseModelNode["WorkspaceName"].asString();
|
||||
if(!cubePerformanceDiagnoseModelNode["WorkspaceId"].isNull())
|
||||
resultObject.cubePerformanceDiagnoseModel.workspaceId = cubePerformanceDiagnoseModelNode["WorkspaceId"].asString();
|
||||
if(!cubePerformanceDiagnoseModelNode["RepeatQueryPercentNum"].isNull())
|
||||
resultObject.cubePerformanceDiagnoseModel.repeatQueryPercentNum = cubePerformanceDiagnoseModelNode["RepeatQueryPercentNum"].asString();
|
||||
if(!cubePerformanceDiagnoseModelNode["RepeatQueryPercent"].isNull())
|
||||
resultObject.cubePerformanceDiagnoseModel.repeatQueryPercent = cubePerformanceDiagnoseModelNode["RepeatQueryPercent"].asString();
|
||||
if(!cubePerformanceDiagnoseModelNode["QuickIndexCostTimeAvg"].isNull())
|
||||
resultObject.cubePerformanceDiagnoseModel.quickIndexCostTimeAvg = cubePerformanceDiagnoseModelNode["QuickIndexCostTimeAvg"].asString();
|
||||
if(!cubePerformanceDiagnoseModelNode["QuickIndexQueryCount"].isNull())
|
||||
resultObject.cubePerformanceDiagnoseModel.quickIndexQueryCount = std::stoi(cubePerformanceDiagnoseModelNode["QuickIndexQueryCount"].asString());
|
||||
if(!cubePerformanceDiagnoseModelNode["CacheCostTimeAvg"].isNull())
|
||||
resultObject.cubePerformanceDiagnoseModel.cacheCostTimeAvg = cubePerformanceDiagnoseModelNode["CacheCostTimeAvg"].asString();
|
||||
if(!cubePerformanceDiagnoseModelNode["CacheQueryCount"].isNull())
|
||||
resultObject.cubePerformanceDiagnoseModel.cacheQueryCount = std::stoi(cubePerformanceDiagnoseModelNode["CacheQueryCount"].asString());
|
||||
if(!cubePerformanceDiagnoseModelNode["RepeatSqlQueryCount"].isNull())
|
||||
resultObject.cubePerformanceDiagnoseModel.repeatSqlQueryCount = std::stoi(cubePerformanceDiagnoseModelNode["RepeatSqlQueryCount"].asString());
|
||||
if(!cubePerformanceDiagnoseModelNode["CostTimeAvg"].isNull())
|
||||
resultObject.cubePerformanceDiagnoseModel.costTimeAvg = cubePerformanceDiagnoseModelNode["CostTimeAvg"].asString();
|
||||
if(!cubePerformanceDiagnoseModelNode["QueryCountAvg"].isNull())
|
||||
resultObject.cubePerformanceDiagnoseModel.queryCountAvg = cubePerformanceDiagnoseModelNode["QueryCountAvg"].asString();
|
||||
if(!cubePerformanceDiagnoseModelNode["QueryCount"].isNull())
|
||||
resultObject.cubePerformanceDiagnoseModel.queryCount = std::stoi(cubePerformanceDiagnoseModelNode["QueryCount"].asString());
|
||||
if(!cubePerformanceDiagnoseModelNode["QueryTimeoutCountPercent"].isNull())
|
||||
resultObject.cubePerformanceDiagnoseModel.queryTimeoutCountPercent = cubePerformanceDiagnoseModelNode["QueryTimeoutCountPercent"].asString();
|
||||
if(!cubePerformanceDiagnoseModelNode["QueryOverTenSecPercentNum"].isNull())
|
||||
resultObject.cubePerformanceDiagnoseModel.queryOverTenSecPercentNum = cubePerformanceDiagnoseModelNode["QueryOverTenSecPercentNum"].asString();
|
||||
if(!cubePerformanceDiagnoseModelNode["QueryOverFivePercentNum"].isNull())
|
||||
resultObject.cubePerformanceDiagnoseModel.queryOverFivePercentNum = cubePerformanceDiagnoseModelNode["QueryOverFivePercentNum"].asString();
|
||||
if(!cubePerformanceDiagnoseModelNode["QueryOverTenSecPercent"].isNull())
|
||||
resultObject.cubePerformanceDiagnoseModel.queryOverTenSecPercent = cubePerformanceDiagnoseModelNode["QueryOverTenSecPercent"].asString();
|
||||
if(!cubePerformanceDiagnoseModelNode["QueryOverFiveSecPercent"].isNull())
|
||||
resultObject.cubePerformanceDiagnoseModel.queryOverFiveSecPercent = cubePerformanceDiagnoseModelNode["QueryOverFiveSecPercent"].asString();
|
||||
result_.push_back(resultObject);
|
||||
}
|
||||
if(!value["Success"].isNull())
|
||||
success_ = value["Success"].asString() == "true";
|
||||
|
||||
}
|
||||
|
||||
bool QueryCubeOptimizationResult::getSuccess()const
|
||||
{
|
||||
return success_;
|
||||
}
|
||||
|
||||
std::vector<QueryCubeOptimizationResult::Data> QueryCubeOptimizationResult::getResult()const
|
||||
{
|
||||
return result_;
|
||||
}
|
||||
|
||||
99
quickbi-public/src/model/QueryCubePerformanceRequest.cc
Normal file
99
quickbi-public/src/model/QueryCubePerformanceRequest.cc
Normal file
@@ -0,0 +1,99 @@
|
||||
/*
|
||||
* 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/quickbi-public/model/QueryCubePerformanceRequest.h>
|
||||
|
||||
using AlibabaCloud::Quickbi_public::Model::QueryCubePerformanceRequest;
|
||||
|
||||
QueryCubePerformanceRequest::QueryCubePerformanceRequest()
|
||||
: RpcServiceRequest("quickbi-public", "2022-01-01", "QueryCubePerformance") {
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
QueryCubePerformanceRequest::~QueryCubePerformanceRequest() {}
|
||||
|
||||
std::string QueryCubePerformanceRequest::getAccessPoint() const {
|
||||
return accessPoint_;
|
||||
}
|
||||
|
||||
void QueryCubePerformanceRequest::setAccessPoint(const std::string &accessPoint) {
|
||||
accessPoint_ = accessPoint;
|
||||
setParameter(std::string("AccessPoint"), accessPoint);
|
||||
}
|
||||
|
||||
std::string QueryCubePerformanceRequest::getSignType() const {
|
||||
return signType_;
|
||||
}
|
||||
|
||||
void QueryCubePerformanceRequest::setSignType(const std::string &signType) {
|
||||
signType_ = signType;
|
||||
setParameter(std::string("SignType"), signType);
|
||||
}
|
||||
|
||||
int QueryCubePerformanceRequest::getPageNum() const {
|
||||
return pageNum_;
|
||||
}
|
||||
|
||||
void QueryCubePerformanceRequest::setPageNum(int pageNum) {
|
||||
pageNum_ = pageNum;
|
||||
setParameter(std::string("PageNum"), std::to_string(pageNum));
|
||||
}
|
||||
|
||||
int QueryCubePerformanceRequest::getPageSize() const {
|
||||
return pageSize_;
|
||||
}
|
||||
|
||||
void QueryCubePerformanceRequest::setPageSize(int pageSize) {
|
||||
pageSize_ = pageSize;
|
||||
setParameter(std::string("PageSize"), std::to_string(pageSize));
|
||||
}
|
||||
|
||||
int QueryCubePerformanceRequest::getCostTimeAvgMin() const {
|
||||
return costTimeAvgMin_;
|
||||
}
|
||||
|
||||
void QueryCubePerformanceRequest::setCostTimeAvgMin(int costTimeAvgMin) {
|
||||
costTimeAvgMin_ = costTimeAvgMin;
|
||||
setParameter(std::string("CostTimeAvgMin"), std::to_string(costTimeAvgMin));
|
||||
}
|
||||
|
||||
std::string QueryCubePerformanceRequest::getQueryType() const {
|
||||
return queryType_;
|
||||
}
|
||||
|
||||
void QueryCubePerformanceRequest::setQueryType(const std::string &queryType) {
|
||||
queryType_ = queryType;
|
||||
setParameter(std::string("QueryType"), queryType);
|
||||
}
|
||||
|
||||
std::string QueryCubePerformanceRequest::getCubeId() const {
|
||||
return cubeId_;
|
||||
}
|
||||
|
||||
void QueryCubePerformanceRequest::setCubeId(const std::string &cubeId) {
|
||||
cubeId_ = cubeId;
|
||||
setParameter(std::string("CubeId"), cubeId);
|
||||
}
|
||||
|
||||
std::string QueryCubePerformanceRequest::getWorkspaceId() const {
|
||||
return workspaceId_;
|
||||
}
|
||||
|
||||
void QueryCubePerformanceRequest::setWorkspaceId(const std::string &workspaceId) {
|
||||
workspaceId_ = workspaceId;
|
||||
setParameter(std::string("WorkspaceId"), workspaceId);
|
||||
}
|
||||
|
||||
104
quickbi-public/src/model/QueryCubePerformanceResult.cc
Normal file
104
quickbi-public/src/model/QueryCubePerformanceResult.cc
Normal file
@@ -0,0 +1,104 @@
|
||||
/*
|
||||
* 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/quickbi-public/model/QueryCubePerformanceResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Quickbi_public;
|
||||
using namespace AlibabaCloud::Quickbi_public::Model;
|
||||
|
||||
QueryCubePerformanceResult::QueryCubePerformanceResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
QueryCubePerformanceResult::QueryCubePerformanceResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
QueryCubePerformanceResult::~QueryCubePerformanceResult()
|
||||
{}
|
||||
|
||||
void QueryCubePerformanceResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
auto allResultNode = value["Result"]["Data"];
|
||||
for (auto valueResultData : allResultNode)
|
||||
{
|
||||
Data resultObject;
|
||||
if(!valueResultData["CubeId"].isNull())
|
||||
resultObject.cubeId = valueResultData["CubeId"].asString();
|
||||
if(!valueResultData["CubeName"].isNull())
|
||||
resultObject.cubeName = valueResultData["CubeName"].asString();
|
||||
if(!valueResultData["QueryTimeoutCount"].isNull())
|
||||
resultObject.queryTimeoutCount = std::stoi(valueResultData["QueryTimeoutCount"].asString());
|
||||
if(!valueResultData["RepeatSqlQueryPercent"].isNull())
|
||||
resultObject.repeatSqlQueryPercent = valueResultData["RepeatSqlQueryPercent"].asString();
|
||||
if(!valueResultData["WorkspaceName"].isNull())
|
||||
resultObject.workspaceName = valueResultData["WorkspaceName"].asString();
|
||||
if(!valueResultData["WorkspaceId"].isNull())
|
||||
resultObject.workspaceId = valueResultData["WorkspaceId"].asString();
|
||||
if(!valueResultData["RepeatQueryPercentNum"].isNull())
|
||||
resultObject.repeatQueryPercentNum = valueResultData["RepeatQueryPercentNum"].asString();
|
||||
if(!valueResultData["RepeatQueryPercent"].isNull())
|
||||
resultObject.repeatQueryPercent = valueResultData["RepeatQueryPercent"].asString();
|
||||
if(!valueResultData["QuickIndexCostTimeAvg"].isNull())
|
||||
resultObject.quickIndexCostTimeAvg = valueResultData["QuickIndexCostTimeAvg"].asString();
|
||||
if(!valueResultData["QuickIndexQueryCount"].isNull())
|
||||
resultObject.quickIndexQueryCount = std::stoi(valueResultData["QuickIndexQueryCount"].asString());
|
||||
if(!valueResultData["CacheCostTimeAvg"].isNull())
|
||||
resultObject.cacheCostTimeAvg = valueResultData["CacheCostTimeAvg"].asString();
|
||||
if(!valueResultData["CacheQueryCount"].isNull())
|
||||
resultObject.cacheQueryCount = std::stoi(valueResultData["CacheQueryCount"].asString());
|
||||
if(!valueResultData["RepeatSqlQueryCount"].isNull())
|
||||
resultObject.repeatSqlQueryCount = std::stoi(valueResultData["RepeatSqlQueryCount"].asString());
|
||||
if(!valueResultData["CostTimeAvg"].isNull())
|
||||
resultObject.costTimeAvg = valueResultData["CostTimeAvg"].asString();
|
||||
if(!valueResultData["QueryCountAvg"].isNull())
|
||||
resultObject.queryCountAvg = valueResultData["QueryCountAvg"].asString();
|
||||
if(!valueResultData["QueryCount"].isNull())
|
||||
resultObject.queryCount = std::stoi(valueResultData["QueryCount"].asString());
|
||||
if(!valueResultData["QueryTimeoutCountPercent"].isNull())
|
||||
resultObject.queryTimeoutCountPercent = valueResultData["QueryTimeoutCountPercent"].asString();
|
||||
if(!valueResultData["QueryOverTenSecPercentNum"].isNull())
|
||||
resultObject.queryOverTenSecPercentNum = valueResultData["QueryOverTenSecPercentNum"].asString();
|
||||
if(!valueResultData["QueryOverFivePercentNum"].isNull())
|
||||
resultObject.queryOverFivePercentNum = valueResultData["QueryOverFivePercentNum"].asString();
|
||||
if(!valueResultData["QueryOverTenSecPercent"].isNull())
|
||||
resultObject.queryOverTenSecPercent = valueResultData["QueryOverTenSecPercent"].asString();
|
||||
if(!valueResultData["QueryOverFiveSecPercent"].isNull())
|
||||
resultObject.queryOverFiveSecPercent = valueResultData["QueryOverFiveSecPercent"].asString();
|
||||
result_.push_back(resultObject);
|
||||
}
|
||||
if(!value["Success"].isNull())
|
||||
success_ = value["Success"].asString() == "true";
|
||||
|
||||
}
|
||||
|
||||
bool QueryCubePerformanceResult::getSuccess()const
|
||||
{
|
||||
return success_;
|
||||
}
|
||||
|
||||
std::vector<QueryCubePerformanceResult::Data> QueryCubePerformanceResult::getResult()const
|
||||
{
|
||||
return result_;
|
||||
}
|
||||
|
||||
108
quickbi-public/src/model/QueryReportPerformanceRequest.cc
Normal file
108
quickbi-public/src/model/QueryReportPerformanceRequest.cc
Normal file
@@ -0,0 +1,108 @@
|
||||
/*
|
||||
* 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/quickbi-public/model/QueryReportPerformanceRequest.h>
|
||||
|
||||
using AlibabaCloud::Quickbi_public::Model::QueryReportPerformanceRequest;
|
||||
|
||||
QueryReportPerformanceRequest::QueryReportPerformanceRequest()
|
||||
: RpcServiceRequest("quickbi-public", "2022-01-01", "QueryReportPerformance") {
|
||||
setMethod(HttpRequest::Method::Post);
|
||||
}
|
||||
|
||||
QueryReportPerformanceRequest::~QueryReportPerformanceRequest() {}
|
||||
|
||||
std::string QueryReportPerformanceRequest::getReportId() const {
|
||||
return reportId_;
|
||||
}
|
||||
|
||||
void QueryReportPerformanceRequest::setReportId(const std::string &reportId) {
|
||||
reportId_ = reportId;
|
||||
setParameter(std::string("ReportId"), reportId);
|
||||
}
|
||||
|
||||
std::string QueryReportPerformanceRequest::getAccessPoint() const {
|
||||
return accessPoint_;
|
||||
}
|
||||
|
||||
void QueryReportPerformanceRequest::setAccessPoint(const std::string &accessPoint) {
|
||||
accessPoint_ = accessPoint;
|
||||
setParameter(std::string("AccessPoint"), accessPoint);
|
||||
}
|
||||
|
||||
std::string QueryReportPerformanceRequest::getSignType() const {
|
||||
return signType_;
|
||||
}
|
||||
|
||||
void QueryReportPerformanceRequest::setSignType(const std::string &signType) {
|
||||
signType_ = signType;
|
||||
setParameter(std::string("SignType"), signType);
|
||||
}
|
||||
|
||||
int QueryReportPerformanceRequest::getPageNum() const {
|
||||
return pageNum_;
|
||||
}
|
||||
|
||||
void QueryReportPerformanceRequest::setPageNum(int pageNum) {
|
||||
pageNum_ = pageNum;
|
||||
setParameter(std::string("PageNum"), std::to_string(pageNum));
|
||||
}
|
||||
|
||||
std::string QueryReportPerformanceRequest::getResourceType() const {
|
||||
return resourceType_;
|
||||
}
|
||||
|
||||
void QueryReportPerformanceRequest::setResourceType(const std::string &resourceType) {
|
||||
resourceType_ = resourceType;
|
||||
setParameter(std::string("ResourceType"), resourceType);
|
||||
}
|
||||
|
||||
int QueryReportPerformanceRequest::getPageSize() const {
|
||||
return pageSize_;
|
||||
}
|
||||
|
||||
void QueryReportPerformanceRequest::setPageSize(int pageSize) {
|
||||
pageSize_ = pageSize;
|
||||
setParameter(std::string("PageSize"), std::to_string(pageSize));
|
||||
}
|
||||
|
||||
int QueryReportPerformanceRequest::getCostTimeAvgMin() const {
|
||||
return costTimeAvgMin_;
|
||||
}
|
||||
|
||||
void QueryReportPerformanceRequest::setCostTimeAvgMin(int costTimeAvgMin) {
|
||||
costTimeAvgMin_ = costTimeAvgMin;
|
||||
setParameter(std::string("CostTimeAvgMin"), std::to_string(costTimeAvgMin));
|
||||
}
|
||||
|
||||
std::string QueryReportPerformanceRequest::getQueryType() const {
|
||||
return queryType_;
|
||||
}
|
||||
|
||||
void QueryReportPerformanceRequest::setQueryType(const std::string &queryType) {
|
||||
queryType_ = queryType;
|
||||
setParameter(std::string("QueryType"), queryType);
|
||||
}
|
||||
|
||||
std::string QueryReportPerformanceRequest::getWorkspaceId() const {
|
||||
return workspaceId_;
|
||||
}
|
||||
|
||||
void QueryReportPerformanceRequest::setWorkspaceId(const std::string &workspaceId) {
|
||||
workspaceId_ = workspaceId;
|
||||
setParameter(std::string("WorkspaceId"), workspaceId);
|
||||
}
|
||||
|
||||
110
quickbi-public/src/model/QueryReportPerformanceResult.cc
Normal file
110
quickbi-public/src/model/QueryReportPerformanceResult.cc
Normal file
@@ -0,0 +1,110 @@
|
||||
/*
|
||||
* 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/quickbi-public/model/QueryReportPerformanceResult.h>
|
||||
#include <json/json.h>
|
||||
|
||||
using namespace AlibabaCloud::Quickbi_public;
|
||||
using namespace AlibabaCloud::Quickbi_public::Model;
|
||||
|
||||
QueryReportPerformanceResult::QueryReportPerformanceResult() :
|
||||
ServiceResult()
|
||||
{}
|
||||
|
||||
QueryReportPerformanceResult::QueryReportPerformanceResult(const std::string &payload) :
|
||||
ServiceResult()
|
||||
{
|
||||
parse(payload);
|
||||
}
|
||||
|
||||
QueryReportPerformanceResult::~QueryReportPerformanceResult()
|
||||
{}
|
||||
|
||||
void QueryReportPerformanceResult::parse(const std::string &payload)
|
||||
{
|
||||
Json::Reader reader;
|
||||
Json::Value value;
|
||||
reader.parse(payload, value);
|
||||
setRequestId(value["RequestId"].asString());
|
||||
auto allResultNode = value["Result"]["Data"];
|
||||
for (auto valueResultData : allResultNode)
|
||||
{
|
||||
Data resultObject;
|
||||
if(!valueResultData["ReportId"].isNull())
|
||||
resultObject.reportId = valueResultData["ReportId"].asString();
|
||||
if(!valueResultData["ReportName"].isNull())
|
||||
resultObject.reportName = valueResultData["ReportName"].asString();
|
||||
if(!valueResultData["ComponentQueryCount"].isNull())
|
||||
resultObject.componentQueryCount = std::stoi(valueResultData["ComponentQueryCount"].asString());
|
||||
if(!valueResultData["ComponentQueryCountAvg"].isNull())
|
||||
resultObject.componentQueryCountAvg = valueResultData["ComponentQueryCountAvg"].asString();
|
||||
if(!valueResultData["ReportType"].isNull())
|
||||
resultObject.reportType = valueResultData["ReportType"].asString();
|
||||
if(!valueResultData["QueryTimeoutCount"].isNull())
|
||||
resultObject.queryTimeoutCount = std::stoi(valueResultData["QueryTimeoutCount"].asString());
|
||||
if(!valueResultData["RepeatSqlQueryPercent"].isNull())
|
||||
resultObject.repeatSqlQueryPercent = valueResultData["RepeatSqlQueryPercent"].asString();
|
||||
if(!valueResultData["WorkspaceName"].isNull())
|
||||
resultObject.workspaceName = valueResultData["WorkspaceName"].asString();
|
||||
if(!valueResultData["WorkspaceId"].isNull())
|
||||
resultObject.workspaceId = valueResultData["WorkspaceId"].asString();
|
||||
if(!valueResultData["RepeatQueryPercentNum"].isNull())
|
||||
resultObject.repeatQueryPercentNum = valueResultData["RepeatQueryPercentNum"].asString();
|
||||
if(!valueResultData["RepeatQueryPercent"].isNull())
|
||||
resultObject.repeatQueryPercent = valueResultData["RepeatQueryPercent"].asString();
|
||||
if(!valueResultData["QuickIndexCostTimeAvg"].isNull())
|
||||
resultObject.quickIndexCostTimeAvg = valueResultData["QuickIndexCostTimeAvg"].asString();
|
||||
if(!valueResultData["QuickIndexQueryCount"].isNull())
|
||||
resultObject.quickIndexQueryCount = std::stoi(valueResultData["QuickIndexQueryCount"].asString());
|
||||
if(!valueResultData["CacheCostTimeAvg"].isNull())
|
||||
resultObject.cacheCostTimeAvg = valueResultData["CacheCostTimeAvg"].asString();
|
||||
if(!valueResultData["CacheQueryCount"].isNull())
|
||||
resultObject.cacheQueryCount = std::stoi(valueResultData["CacheQueryCount"].asString());
|
||||
if(!valueResultData["RepeatSqlQueryCount"].isNull())
|
||||
resultObject.repeatSqlQueryCount = std::stoi(valueResultData["RepeatSqlQueryCount"].asString());
|
||||
if(!valueResultData["CostTimeAvg"].isNull())
|
||||
resultObject.costTimeAvg = valueResultData["CostTimeAvg"].asString();
|
||||
if(!valueResultData["QueryCountAvg"].isNull())
|
||||
resultObject.queryCountAvg = valueResultData["QueryCountAvg"].asString();
|
||||
if(!valueResultData["QueryCount"].isNull())
|
||||
resultObject.queryCount = std::stoi(valueResultData["QueryCount"].asString());
|
||||
if(!valueResultData["QueryTimeoutCountPercent"].isNull())
|
||||
resultObject.queryTimeoutCountPercent = valueResultData["QueryTimeoutCountPercent"].asString();
|
||||
if(!valueResultData["QueryOverTenSecPercentNum"].isNull())
|
||||
resultObject.queryOverTenSecPercentNum = valueResultData["QueryOverTenSecPercentNum"].asString();
|
||||
if(!valueResultData["QueryOverFivePercentNum"].isNull())
|
||||
resultObject.queryOverFivePercentNum = valueResultData["QueryOverFivePercentNum"].asString();
|
||||
if(!valueResultData["QueryOverTenSecPercent"].isNull())
|
||||
resultObject.queryOverTenSecPercent = valueResultData["QueryOverTenSecPercent"].asString();
|
||||
if(!valueResultData["QueryOverFiveSecPercent"].isNull())
|
||||
resultObject.queryOverFiveSecPercent = valueResultData["QueryOverFiveSecPercent"].asString();
|
||||
result_.push_back(resultObject);
|
||||
}
|
||||
if(!value["Success"].isNull())
|
||||
success_ = value["Success"].asString() == "true";
|
||||
|
||||
}
|
||||
|
||||
bool QueryReportPerformanceResult::getSuccess()const
|
||||
{
|
||||
return success_;
|
||||
}
|
||||
|
||||
std::vector<QueryReportPerformanceResult::Data> QueryReportPerformanceResult::getResult()const
|
||||
{
|
||||
return result_;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user