UNPKG

tencentcloud-sdk-nodejs-intl-en

Version:
1,714 lines (1,444 loc) • 121 kB
/* * Copyright (c) 2018 THL A29 Limited, a Tencent company. 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. */ const AbstractModel = require("../../common/abstract_model"); /** * DescribeTask request structure. * @class */ class DescribeTaskRequest extends AbstractModel { constructor(){ super(); /** * Task ID * @type {number || null} */ this.TaskId = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.TaskId = 'TaskId' in params ? params.TaskId : null; } } /** * DescribeActionFieldConfigList request structure. * @class */ class DescribeActionFieldConfigListRequest extends AbstractModel { constructor(){ super(); /** * Action ID list * @type {Array.<number> || null} */ this.ActionIds = null; /** * Object type ID * @type {number || null} */ this.ObjectTypeId = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.ActionIds = 'ActionIds' in params ? params.ActionIds : null; this.ObjectTypeId = 'ObjectTypeId' in params ? params.ObjectTypeId : null; } } /** * Task group action * @class */ class TaskGroupAction extends AbstractModel { constructor(){ super(); /** * Task group action ID * @type {number || null} */ this.TaskGroupActionId = null; /** * Action instance list of the task group * @type {Array.<TaskGroupInstance> || null} */ this.TaskGroupInstances = null; /** * Action ID * @type {number || null} */ this.ActionId = null; /** * Order of actions in the group * @type {number || null} */ this.TaskGroupActionOrder = null; /** * General configurations of actions in the group Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.TaskGroupActionGeneralConfiguration = null; /** * Custom configurations of actions in the group Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.TaskGroupActionCustomConfiguration = null; /** * Status of actions in the group * @type {number || null} */ this.TaskGroupActionStatus = null; /** * Action group creation time * @type {string || null} */ this.TaskGroupActionCreateTime = null; /** * Action group update time * @type {string || null} */ this.TaskGroupActionUpdateTime = null; /** * Action name * @type {string || null} */ this.ActionTitle = null; /** * Status. 0: no status; 1: successful; 2; failed; 3: terminated; 4: skipped. * @type {number || null} */ this.TaskGroupActionStatusType = null; /** * RandomId Note: This field may return null, indicating that no valid values can be obtained. * @type {number || null} */ this.TaskGroupActionRandomId = null; /** * RecoverId Note: This field may return null, indicating that no valid values can be obtained. * @type {number || null} */ this.TaskGroupActionRecoverId = null; /** * ExecuteId Note: This field may return null, indicating that no valid values can be obtained. * @type {number || null} */ this.TaskGroupActionExecuteId = null; /** * Called API type. 0: tat; 1: cloud API. Note: This field may return null, indicating that no valid values can be obtained. * @type {number || null} */ this.ActionApiType = null; /** * 1: fault; 2: recovery. Note: This field may return null, indicating that no valid values can be obtained. * @type {number || null} */ this.ActionAttribute = null; /** * Action type: platform and custom Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.ActionType = null; /** * Whether retry is allowed Note: This field may return null, indicating that no valid values can be obtained. * @type {boolean || null} */ this.IsExecuteRedo = null; /** * Action risk level Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.ActionRisk = null; /** * Action running time Note: This field may return null, indicating that no valid values can be obtained. * @type {number || null} */ this.TaskGroupActionExecuteTime = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.TaskGroupActionId = 'TaskGroupActionId' in params ? params.TaskGroupActionId : null; if (params.TaskGroupInstances) { this.TaskGroupInstances = new Array(); for (let z in params.TaskGroupInstances) { let obj = new TaskGroupInstance(); obj.deserialize(params.TaskGroupInstances[z]); this.TaskGroupInstances.push(obj); } } this.ActionId = 'ActionId' in params ? params.ActionId : null; this.TaskGroupActionOrder = 'TaskGroupActionOrder' in params ? params.TaskGroupActionOrder : null; this.TaskGroupActionGeneralConfiguration = 'TaskGroupActionGeneralConfiguration' in params ? params.TaskGroupActionGeneralConfiguration : null; this.TaskGroupActionCustomConfiguration = 'TaskGroupActionCustomConfiguration' in params ? params.TaskGroupActionCustomConfiguration : null; this.TaskGroupActionStatus = 'TaskGroupActionStatus' in params ? params.TaskGroupActionStatus : null; this.TaskGroupActionCreateTime = 'TaskGroupActionCreateTime' in params ? params.TaskGroupActionCreateTime : null; this.TaskGroupActionUpdateTime = 'TaskGroupActionUpdateTime' in params ? params.TaskGroupActionUpdateTime : null; this.ActionTitle = 'ActionTitle' in params ? params.ActionTitle : null; this.TaskGroupActionStatusType = 'TaskGroupActionStatusType' in params ? params.TaskGroupActionStatusType : null; this.TaskGroupActionRandomId = 'TaskGroupActionRandomId' in params ? params.TaskGroupActionRandomId : null; this.TaskGroupActionRecoverId = 'TaskGroupActionRecoverId' in params ? params.TaskGroupActionRecoverId : null; this.TaskGroupActionExecuteId = 'TaskGroupActionExecuteId' in params ? params.TaskGroupActionExecuteId : null; this.ActionApiType = 'ActionApiType' in params ? params.ActionApiType : null; this.ActionAttribute = 'ActionAttribute' in params ? params.ActionAttribute : null; this.ActionType = 'ActionType' in params ? params.ActionType : null; this.IsExecuteRedo = 'IsExecuteRedo' in params ? params.IsExecuteRedo : null; this.ActionRisk = 'ActionRisk' in params ? params.ActionRisk : null; this.TaskGroupActionExecuteTime = 'TaskGroupActionExecuteTime' in params ? params.TaskGroupActionExecuteTime : null; } } /** * Application information on Application Performance Monitoring * @class */ class ApmServiceInfo extends AbstractModel { constructor(){ super(); /** * Business ID Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.InstanceId = null; /** * Application name Note: This field may return null, indicating that no valid values can be obtained. * @type {Array.<string> || null} */ this.ServiceNameList = null; /** * Region ID Note: This field may return null, indicating that no valid values can be obtained. * @type {number || null} */ this.RegionId = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.InstanceId = 'InstanceId' in params ? params.InstanceId : null; this.ServiceNameList = 'ServiceNameList' in params ? params.ServiceNameList : null; this.RegionId = 'RegionId' in params ? params.RegionId : null; } } /** * Machine selection rule * @class */ class TaskGroupInstancesExecuteRules extends AbstractModel { constructor(){ super(); /** * Instance selection mode Note: This field may return null, indicating that no valid values can be obtained. * @type {number || null} */ this.TaskGroupInstancesExecuteMode = null; /** * Proportion of selected machines in selection by proportion mode Note: This field may return null, indicating that no valid values can be obtained. * @type {number || null} */ this.TaskGroupInstancesExecutePercent = null; /** * Number of selected machines in selection by quantity mode Note: This field may return null, indicating that no valid values can be obtained. * @type {number || null} */ this.TaskGroupInstancesExecuteNum = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.TaskGroupInstancesExecuteMode = 'TaskGroupInstancesExecuteMode' in params ? params.TaskGroupInstancesExecuteMode : null; this.TaskGroupInstancesExecutePercent = 'TaskGroupInstancesExecutePercent' in params ? params.TaskGroupInstancesExecutePercent : null; this.TaskGroupInstancesExecuteNum = 'TaskGroupInstancesExecuteNum' in params ? params.TaskGroupInstancesExecuteNum : null; } } /** * CreateTaskFromAction request structure. * @class */ class CreateTaskFromActionRequest extends AbstractModel { constructor(){ super(); /** * Action ID, which can be obtained by using the action list API DescribeActionLibraryList. * @type {number || null} */ this.TaskActionId = null; /** * ID of the instance participating in the experiment. * @type {Array.<string> || null} */ this.TaskInstances = null; /** * Experiment name. If this parameter is left blank, the action name is used by default. * @type {string || null} */ this.TaskTitle = null; /** * Experiment description. If this parameter is left blank, the action description is used by default. * @type {string || null} */ this.TaskDescription = null; /** * General action parameters, which need to be passed in after JSON serialization. The parameters can be obtained by using the action details API DescribeActionFieldConfigList. If this field is left blank, the default action parameters are used by default. * @type {string || null} */ this.TaskActionGeneralConfiguration = null; /** * Action custom parameters need to be passed in as json serialization. They can be obtained from the action details interface DescribeActionFieldConfigList. If not filled in, the default action parameters will be used. Note: Required parameters have no default values. Be sure to pass in valid values. * @type {string || null} */ this.TaskActionCustomConfiguration = null; /** * Automatic experiment pause time, in minutes. If this parameter is left blank, the default value 60 is used. * @type {number || null} */ this.TaskPauseDuration = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.TaskActionId = 'TaskActionId' in params ? params.TaskActionId : null; this.TaskInstances = 'TaskInstances' in params ? params.TaskInstances : null; this.TaskTitle = 'TaskTitle' in params ? params.TaskTitle : null; this.TaskDescription = 'TaskDescription' in params ? params.TaskDescription : null; this.TaskActionGeneralConfiguration = 'TaskActionGeneralConfiguration' in params ? params.TaskActionGeneralConfiguration : null; this.TaskActionCustomConfiguration = 'TaskActionCustomConfiguration' in params ? params.TaskActionCustomConfiguration : null; this.TaskPauseDuration = 'TaskPauseDuration' in params ? params.TaskPauseDuration : null; } } /** * DeleteTask request structure. * @class */ class DeleteTaskRequest extends AbstractModel { constructor(){ super(); /** * Task ID * @type {number || null} */ this.TaskId = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.TaskId = 'TaskId' in params ? params.TaskId : null; } } /** * DescribeActionLibraryList request structure. * @class */ class DescribeActionLibraryListRequest extends AbstractModel { constructor(){ super(); /** * 0-100 * @type {number || null} */ this.Limit = null; /** * Default value: 0 * @type {number || null} */ this.Offset = null; /** * Object type ID * @type {number || null} */ this.ObjectType = null; /** * Keyword value {"action name": "a_title", "description": "a_desc", "action type": "a_type", "creation time": "a_create_time", "level-2 type": "a_resource_type"} * @type {Array.<ActionFilter> || null} */ this.Filters = null; /** * Action type. 1: fault action; 2: recovery action. * @type {Array.<number> || null} */ this.Attribute = null; /** * Filter item - action ID * @type {Array.<number> || null} */ this.ActionIds = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.Limit = 'Limit' in params ? params.Limit : null; this.Offset = 'Offset' in params ? params.Offset : null; this.ObjectType = 'ObjectType' in params ? params.ObjectType : null; if (params.Filters) { this.Filters = new Array(); for (let z in params.Filters) { let obj = new ActionFilter(); obj.deserialize(params.Filters[z]); this.Filters.push(obj); } } this.Attribute = 'Attribute' in params ? params.Attribute : null; this.ActionIds = 'ActionIds' in params ? params.ActionIds : null; } } /** * Task group * @class */ class TaskGroup extends AbstractModel { constructor(){ super(); /** * Task action ID * @type {number || null} */ this.TaskGroupId = null; /** * Group name * @type {string || null} */ this.TaskGroupTitle = null; /** * Group description Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.TaskGroupDescription = null; /** * Task group order * @type {number || null} */ this.TaskGroupOrder = null; /** * Object type ID * @type {number || null} */ this.ObjectTypeId = null; /** * Task group creation time * @type {string || null} */ this.TaskGroupCreateTime = null; /** * Task group update time * @type {string || null} */ this.TaskGroupUpdateTime = null; /** * List of actions in the group * @type {Array.<TaskGroupAction> || null} */ this.TaskGroupActions = null; /** * Instance list * @type {Array.<string> || null} */ this.TaskGroupInstanceList = null; /** * Execution mode. 1: sequential execution; 2: execution by stage. * @type {number || null} */ this.TaskGroupMode = null; /** * List of instances not involved in the experiment * @type {Array.<string> || null} */ this.TaskGroupDiscardInstanceList = null; /** * List of instances involved in the experiment Note: This field may return null, indicating that no valid values can be obtained. * @type {Array.<string> || null} */ this.TaskGroupSelectedInstanceList = null; /** * Machine selection rule Note: This field may return null, indicating that no valid values can be obtained. * @type {Array.<TaskGroupInstancesExecuteRules> || null} */ this.TaskGroupInstancesExecuteRule = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.TaskGroupId = 'TaskGroupId' in params ? params.TaskGroupId : null; this.TaskGroupTitle = 'TaskGroupTitle' in params ? params.TaskGroupTitle : null; this.TaskGroupDescription = 'TaskGroupDescription' in params ? params.TaskGroupDescription : null; this.TaskGroupOrder = 'TaskGroupOrder' in params ? params.TaskGroupOrder : null; this.ObjectTypeId = 'ObjectTypeId' in params ? params.ObjectTypeId : null; this.TaskGroupCreateTime = 'TaskGroupCreateTime' in params ? params.TaskGroupCreateTime : null; this.TaskGroupUpdateTime = 'TaskGroupUpdateTime' in params ? params.TaskGroupUpdateTime : null; if (params.TaskGroupActions) { this.TaskGroupActions = new Array(); for (let z in params.TaskGroupActions) { let obj = new TaskGroupAction(); obj.deserialize(params.TaskGroupActions[z]); this.TaskGroupActions.push(obj); } } this.TaskGroupInstanceList = 'TaskGroupInstanceList' in params ? params.TaskGroupInstanceList : null; this.TaskGroupMode = 'TaskGroupMode' in params ? params.TaskGroupMode : null; this.TaskGroupDiscardInstanceList = 'TaskGroupDiscardInstanceList' in params ? params.TaskGroupDiscardInstanceList : null; this.TaskGroupSelectedInstanceList = 'TaskGroupSelectedInstanceList' in params ? params.TaskGroupSelectedInstanceList : null; if (params.TaskGroupInstancesExecuteRule) { this.TaskGroupInstancesExecuteRule = new Array(); for (let z in params.TaskGroupInstancesExecuteRule) { let obj = new TaskGroupInstancesExecuteRules(); obj.deserialize(params.TaskGroupInstancesExecuteRule[z]); this.TaskGroupInstancesExecuteRule.push(obj); } } } } /** * ExecuteTask response structure. * @class */ class ExecuteTaskResponse extends AbstractModel { constructor(){ super(); /** * The unique request ID, generated by the server, will be returned for every request (if the request fails to reach the server for other reasons, the request will not obtain a RequestId). RequestId is required for locating a problem. * @type {string || null} */ this.RequestId = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.RequestId = 'RequestId' in params ? params.RequestId : null; } } /** * DescribeActionFieldConfigList response structure. * @class */ class DescribeActionFieldConfigListResponse extends AbstractModel { constructor(){ super(); /** * List of general filed configuration parameters * @type {Array.<ActionFieldConfigResult> || null} */ this.Common = null; /** * List of action filed configuration parameters * @type {Array.<ActionFieldConfigResult> || null} */ this.Results = null; /** * Information on the decommissioned resource Note: This field may return null, indicating that no valid values can be obtained. * @type {Array.<ResourceOffline> || null} */ this.ResourceOffline = null; /** * The unique request ID, generated by the server, will be returned for every request (if the request fails to reach the server for other reasons, the request will not obtain a RequestId). RequestId is required for locating a problem. * @type {string || null} */ this.RequestId = null; } /** * @private */ deserialize(params) { if (!params) { return; } if (params.Common) { this.Common = new Array(); for (let z in params.Common) { let obj = new ActionFieldConfigResult(); obj.deserialize(params.Common[z]); this.Common.push(obj); } } if (params.Results) { this.Results = new Array(); for (let z in params.Results) { let obj = new ActionFieldConfigResult(); obj.deserialize(params.Results[z]); this.Results.push(obj); } } if (params.ResourceOffline) { this.ResourceOffline = new Array(); for (let z in params.ResourceOffline) { let obj = new ResourceOffline(); obj.deserialize(params.ResourceOffline[z]); this.ResourceOffline.push(obj); } } this.RequestId = 'RequestId' in params ? params.RequestId : null; } } /** * Response format of dynamic action parameters * @class */ class ActionFieldConfigDetail extends AbstractModel { constructor(){ super(); /** * Component type The options are as follows: input: text box textarea: multi-line text box number: number input box select: selector cascader: cascade selector radio: single choice time: time selection * @type {string || null} */ this.Type = null; /** * Component label * @type {string || null} */ this.Lable = null; /** * Unique identifier of the component, key when it is sent back to the backend * @type {string || null} */ this.Field = null; /** * Default value Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.DefaultValue = null; /** * The supported configuration items are as follows. You can select the configuration items as needed. If no configuration is required, set the value to {}. { placeholder: string (placeholder) tooltip: string (prompt message) reg: RegExp (regular expression for the input content format) max: number (maximum number of input characters for text boxes and upper limit of the input number for number input boxes) min: number (lower limit of the input number for number input boxes) step: number (step size for number input boxes; default value: 1) format: string (format for time selection, for example YYYY-MM-DD and YYYY-MM-DD HH:mm:ss) separator: string[] (separator for multi-line input boxes. If it is left blank, no separator is used, and the text string entered by the user is returned directly.) multiple: boolean (multiple-choice or not, valid for selectors and cascade selectors) options: selector options (support the following two forms) Directly provide the option array: { value: string; label: string }[] Obtain options by calling the API: { api: string (API URL), params: string[] (interface parameters, corresponding to field of the parameter configuration. The frontend uses the input values of all components corresponding to field as parameters to query data. If no value is input, the frontend directly requests data when components are loaded.) } } * @type {string || null} */ this.Config = null; /** * Whether it is required (0: no; 1: yes) * @type {number || null} */ this.Required = null; /** * The compute configuration passes the verification when other fields that it depends on meet the conditions. (For example, at least one of the three form items must be filled in.) [fieldName, { config: This item is retained and will be refined based on subsequent scenes. } ] * @type {string || null} */ this.Validate = null; /** * Whether it is visible * @type {string || null} */ this.Visible = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.Type = 'Type' in params ? params.Type : null; this.Lable = 'Lable' in params ? params.Lable : null; this.Field = 'Field' in params ? params.Field : null; this.DefaultValue = 'DefaultValue' in params ? params.DefaultValue : null; this.Config = 'Config' in params ? params.Config : null; this.Required = 'Required' in params ? params.Required : null; this.Validate = 'Validate' in params ? params.Validate : null; this.Visible = 'Visible' in params ? params.Visible : null; } } /** * Task group action * @class */ class TemplateGroupAction extends AbstractModel { constructor(){ super(); /** * Template library group action ID * @type {number || null} */ this.TemplateGroupActionId = null; /** * Action ID * @type {number || null} */ this.ActionId = null; /** * Order of actions in the group * @type {number || null} */ this.Order = null; /** * General configurations of actions in the group Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.GeneralConfiguration = null; /** * Custom configurations of actions in the group Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.CustomConfiguration = null; /** * Action group creation time * @type {string || null} */ this.CreateTime = null; /** * Action group update time * @type {string || null} */ this.UpdateTime = null; /** * Action name * @type {string || null} */ this.ActionTitle = null; /** * Random ID Note: This field may return null, indicating that no valid values can be obtained. * @type {number || null} */ this.RandomId = null; /** * Recovery action ID Note: This field may return null, indicating that no valid values can be obtained. * @type {number || null} */ this.RecoverId = null; /** * Executed action ID Note: This field may return null, indicating that no valid values can be obtained. * @type {number || null} */ this.ExecuteId = null; /** * Called API type. 0: tat; 1: cloud API. Note: This field may return null, indicating that no valid values can be obtained. * @type {number || null} */ this.ActionApiType = null; /** * 1: fault; 2: recovery. Note: This field may return null, indicating that no valid values can be obtained. * @type {number || null} */ this.ActionAttribute = null; /** * Action type: platform and custom Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.ActionType = null; /** * Action risk level. 1: low-risk; 2: medium-risk; 3: high-risk. Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.ActionRisk = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.TemplateGroupActionId = 'TemplateGroupActionId' in params ? params.TemplateGroupActionId : null; this.ActionId = 'ActionId' in params ? params.ActionId : null; this.Order = 'Order' in params ? params.Order : null; this.GeneralConfiguration = 'GeneralConfiguration' in params ? params.GeneralConfiguration : null; this.CustomConfiguration = 'CustomConfiguration' in params ? params.CustomConfiguration : null; this.CreateTime = 'CreateTime' in params ? params.CreateTime : null; this.UpdateTime = 'UpdateTime' in params ? params.UpdateTime : null; this.ActionTitle = 'ActionTitle' in params ? params.ActionTitle : null; this.RandomId = 'RandomId' in params ? params.RandomId : null; this.RecoverId = 'RecoverId' in params ? params.RecoverId : null; this.ExecuteId = 'ExecuteId' in params ? params.ExecuteId : null; this.ActionApiType = 'ActionApiType' in params ? params.ActionApiType : null; this.ActionAttribute = 'ActionAttribute' in params ? params.ActionAttribute : null; this.ActionType = 'ActionType' in params ? params.ActionType : null; this.ActionRisk = 'ActionRisk' in params ? params.ActionRisk : null; } } /** * Template library * @class */ class Template extends AbstractModel { constructor(){ super(); /** * Template library ID * @type {number || null} */ this.TemplateId = null; /** * Template library name * @type {string || null} */ this.TemplateTitle = null; /** * Template library description * @type {string || null} */ this.TemplateDescription = null; /** * Custom tag Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.TemplateTag = null; /** * Usage status. 1: in use; 2: not in use. * @type {number || null} */ this.TemplateIsUsed = null; /** * Template library creation time * @type {string || null} */ this.TemplateCreateTime = null; /** * Template library update time * @type {string || null} */ this.TemplateUpdateTime = null; /** * Template library mode. 1: manual execution; 2: automatic execution. * @type {number || null} */ this.TemplateMode = null; /** * Automatic pause duration. Unit: minutes. * @type {number || null} */ this.TemplatePauseDuration = null; /** * Main account that creates the experiment * @type {string || null} */ this.TemplateOwnerUin = null; /** * Region ID * @type {number || null} */ this.TemplateRegionId = null; /** * Action group * @type {Array.<TemplateGroup> || null} */ this.TemplateGroups = null; /** * Monitoring metrics * @type {Array.<TemplateMonitor> || null} */ this.TemplateMonitors = null; /** * Guardrail monitoring Note: This field may return null, indicating that no valid values can be obtained. * @type {TemplatePolicy || null} */ this.TemplatePolicy = null; /** * Tag list Note: This field may return null, indicating that no valid values can be obtained. * @type {Array.<TagWithDescribe> || null} */ this.Tags = null; /** * Template library source. 0: self-built; 1: recommended by experts. Note: This field may return null, indicating that no valid values can be obtained. * @type {number || null} */ this.TemplateSource = null; /** * Application information on Application Performance Monitoring Note: This field may return null, indicating that no valid values can be obtained. * @type {Array.<ApmServiceInfo> || null} */ this.ApmServiceList = null; /** * Alarm metrics Note: This field may return null, indicating that no valid values can be obtained. * @type {Array.<string> || null} */ this.AlarmPolicy = null; /** * Guardrail processing method. 1: roll back sequentially; 2: pause experiment. Note: This field may return null, indicating that no valid values can be obtained. * @type {number || null} */ this.PolicyDealType = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.TemplateId = 'TemplateId' in params ? params.TemplateId : null; this.TemplateTitle = 'TemplateTitle' in params ? params.TemplateTitle : null; this.TemplateDescription = 'TemplateDescription' in params ? params.TemplateDescription : null; this.TemplateTag = 'TemplateTag' in params ? params.TemplateTag : null; this.TemplateIsUsed = 'TemplateIsUsed' in params ? params.TemplateIsUsed : null; this.TemplateCreateTime = 'TemplateCreateTime' in params ? params.TemplateCreateTime : null; this.TemplateUpdateTime = 'TemplateUpdateTime' in params ? params.TemplateUpdateTime : null; this.TemplateMode = 'TemplateMode' in params ? params.TemplateMode : null; this.TemplatePauseDuration = 'TemplatePauseDuration' in params ? params.TemplatePauseDuration : null; this.TemplateOwnerUin = 'TemplateOwnerUin' in params ? params.TemplateOwnerUin : null; this.TemplateRegionId = 'TemplateRegionId' in params ? params.TemplateRegionId : null; if (params.TemplateGroups) { this.TemplateGroups = new Array(); for (let z in params.TemplateGroups) { let obj = new TemplateGroup(); obj.deserialize(params.TemplateGroups[z]); this.TemplateGroups.push(obj); } } if (params.TemplateMonitors) { this.TemplateMonitors = new Array(); for (let z in params.TemplateMonitors) { let obj = new TemplateMonitor(); obj.deserialize(params.TemplateMonitors[z]); this.TemplateMonitors.push(obj); } } if (params.TemplatePolicy) { let obj = new TemplatePolicy(); obj.deserialize(params.TemplatePolicy) this.TemplatePolicy = obj; } if (params.Tags) { this.Tags = new Array(); for (let z in params.Tags) { let obj = new TagWithDescribe(); obj.deserialize(params.Tags[z]); this.Tags.push(obj); } } this.TemplateSource = 'TemplateSource' in params ? params.TemplateSource : null; if (params.ApmServiceList) { this.ApmServiceList = new Array(); for (let z in params.ApmServiceList) { let obj = new ApmServiceInfo(); obj.deserialize(params.ApmServiceList[z]); this.ApmServiceList.push(obj); } } this.AlarmPolicy = 'AlarmPolicy' in params ? params.AlarmPolicy : null; this.PolicyDealType = 'PolicyDealType' in params ? params.PolicyDealType : null; } } /** * DescribeTaskExecuteLogs request structure. * @class */ class DescribeTaskExecuteLogsRequest extends AbstractModel { constructor(){ super(); /** * Task ID * @type {number || null} */ this.TaskId = null; /** * Number of returned content lines * @type {number || null} */ this.Limit = null; /** * Log start line * @type {number || null} */ this.Offset = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.TaskId = 'TaskId' in params ? params.TaskId : null; this.Limit = 'Limit' in params ? params.Limit : null; this.Offset = 'Offset' in params ? params.Offset : null; } } /** * DescribeObjectTypeList response structure. * @class */ class DescribeObjectTypeListResponse extends AbstractModel { constructor(){ super(); /** * Object type list * @type {Array.<ObjectType> || null} */ this.ObjectTypeList = null; /** * The unique request ID, generated by the server, will be returned for every request (if the request fails to reach the server for other reasons, the request will not obtain a RequestId). RequestId is required for locating a problem. * @type {string || null} */ this.RequestId = null; } /** * @private */ deserialize(params) { if (!params) { return; } if (params.ObjectTypeList) { this.ObjectTypeList = new Array(); for (let z in params.ObjectTypeList) { let obj = new ObjectType(); obj.deserialize(params.ObjectTypeList[z]); this.ObjectTypeList.push(obj); } } this.RequestId = 'RequestId' in params ? params.RequestId : null; } } /** * ModifyTaskRunStatus request structure. * @class */ class ModifyTaskRunStatusRequest extends AbstractModel { constructor(){ super(); /** * Task ID * @type {number || null} */ this.TaskId = null; /** * Task status. 1001: not started; 1002: in progress (executing); 1003: in progress (paused); 1004: execution ended. * @type {number || null} */ this.Status = null; /** * Whether the execution result meets expectations (This field is required when the task status is Execution Ended.) * @type {boolean || null} */ this.IsExpect = null; /** * Experiment result (This field is required when the experiment status changes to Execution Ended.) * @type {string || null} */ this.Summary = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.TaskId = 'TaskId' in params ? params.TaskId : null; this.Status = 'Status' in params ? params.Status : null; this.IsExpect = 'IsExpect' in params ? params.IsExpect : null; this.Summary = 'Summary' in params ? params.Summary : null; } } /** * DescribeTemplate response structure. * @class */ class DescribeTemplateResponse extends AbstractModel { constructor(){ super(); /** * Template library details * @type {Template || null} */ this.Template = null; /** * The unique request ID, generated by the server, will be returned for every request (if the request fails to reach the server for other reasons, the request will not obtain a RequestId). RequestId is required for locating a problem. * @type {string || null} */ this.RequestId = null; } /** * @private */ deserialize(params) { if (!params) { return; } if (params.Template) { let obj = new Template(); obj.deserialize(params.Template) this.Template = obj; } this.RequestId = 'RequestId' in params ? params.RequestId : null; } } /** * Protection policy * @class */ class DescribePolicy extends AbstractModel { constructor(){ super(); /** * Protection policy ID list * @type {Array.<string> || null} */ this.TaskPolicyIdList = null; /** * Protection policy status * @type {string || null} */ this.TaskPolicyStatus = null; /** * Policy rule * @type {string || null} */ this.TaskPolicyRule = null; /** * Process method when the guardrail policy takes effect. 1: sequential execution, 2: pausing. Note: This field may return null, indicating that no valid values can be obtained. * @type {number || null} */ this.TaskPolicyDealType = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.TaskPolicyIdList = 'TaskPolicyIdList' in params ? params.TaskPolicyIdList : null; this.TaskPolicyStatus = 'TaskPolicyStatus' in params ? params.TaskPolicyStatus : null; this.TaskPolicyRule = 'TaskPolicyRule' in params ? params.TaskPolicyRule : null; this.TaskPolicyDealType = 'TaskPolicyDealType' in params ? params.TaskPolicyDealType : null; } } /** * Action library filtering field * @class */ class ActionFilter extends AbstractModel { constructor(){ super(); /** * Keyword * @type {string || null} */ this.Keyword = null; /** * Content for search * @type {Array.<string> || null} */ this.Values = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.Keyword = 'Keyword' in params ? params.Keyword : null; this.Values = 'Values' in params ? params.Values : null; } } /** * Guardrail policy triggering log * @class */ class PolicyTriggerLog extends AbstractModel { constructor(){ super(); /** * Experiment ID Note: This field may return null, indicating that no valid values can be obtained. * @type {number || null} */ this.TaskId = null; /** * Name Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.Name = null; /** * Type. 0: trigger; 1: recovery. Note: This field may return null, indicating that no valid values can be obtained. * @type {number || null} */ this.TriggerType = null; /** * Content Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.Content = null; /** * Triggering time Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.CreatTime = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.TaskId = 'TaskId' in params ? params.TaskId : null; this.Name = 'Name' in params ? params.Name : null; this.TriggerType = 'TriggerType' in params ? params.TriggerType : null; this.Content = 'Content' in params ? params.Content : null; this.CreatTime = 'CreatTime' in params ? params.CreatTime : null; } } /** * DescribeTemplate request structure. * @class */ class DescribeTemplateRequest extends AbstractModel { constructor(){ super(); /** * Template library ID * @type {number || null} */ this.TemplateId = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.TemplateId = 'TemplateId' in params ? params.TemplateId : null; } } /** * ExecuteTaskInstance request structure. * @class */ class ExecuteTaskInstanceRequest extends AbstractModel { constructor(){ super(); /** * Task ID * @type {number || null} */ this.TaskId = null; /** * Task action ID * @type {number || null} */ this.TaskActionId = null; /** * Task action instance ID * @type {Array.<number> || null} */ this.TaskInstanceIds = null; /** * Whether to operate on the entire task * @type {boolean || null} */ this.IsOperateAll = null; /** * Operation type (1: start; 2: execute; 3: skip; 5: retry) * @type {number || null} */ this.ActionType = null; /** * Action group ID * @type {number || null} */ this.TaskGroupId = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.TaskId = 'TaskId' in params ? params.TaskId : null; this.TaskActionId = 'TaskActionId' in params ? params.TaskActionId : null; this.TaskInstanceIds = 'TaskInstanceIds' in params ? params.TaskInstanceIds : null; this.IsOperateAll = 'IsOperateAll' in params ? params.IsOperateAll : null; this.ActionType = 'ActionType' in params ? params.ActionType : null; this.TaskGroupId = 'TaskGroupId' in params ? params.TaskGroupId : null; } } /** * Task group action instance * @class */ class TaskGroupInstance extends AbstractModel { constructor(){ super(); /** * Instance ID * @type {number || null} */ this.TaskGroupInstanceId = null; /** * Instance ID Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.TaskGroupInstanceObjectId = null; /** * Instance action execution status * @type {number || null} */ this.TaskGroupInstanceStatus = null; /** * Instance creation time * @type {string || null} */ this.TaskGroupInstanceCreateTime = null; /** * Instance update time * @type {string || null} */ this.TaskGroupInstanceUpdateTime = null; /** * Status. 0: no status; 1: successful; 2: failed; 3: terminated; 4: skipped. * @type {number || null} */ this.TaskGroupInstanceStatusType = null; /** * Execution start time Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.TaskGroupInstanceStartTime = null; /** * Execution end time Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.TaskGroupInstanceEndTime = null; /** * Instance action execution log Note: This field may return null, indicating that no valid values can be obtained. * @type {string || null} */ this.TaskGroupInstanceExecuteLog = null; /** * Whether the instance can be retried Note: This field may return null, indicating that no valid values can be obtained. * @type {boolean || null} */ this.TaskGroupInstanceIsRedo = null; /** * Action instance execution time Note: This field may return null, indicating that no valid values can be obtained. * @type {number || null} */ this.TaskGroupInstanceExecuteTime = null; } /** * @private */ deserialize(params) { if (!params) { return; } this.TaskGroupInstanceId = 'TaskGroupInstanceId' in params ? params.TaskGroupInstanceId : null; this.TaskGroupInstanceObjectId = 'TaskGroupInstanceObjectId' in params ? params.TaskGroupInstanceObjectId : null; this.TaskGroupInstanceStatus = 'TaskGroupInstanceStatus' in params ? params.TaskGroupInstanceStatus : null; this.TaskGroupInstanceCreateTime = 'TaskGroupInstanceCreateTime' in params ? params.TaskGroupInstanceCreateTime : null; this.TaskGroupInstanceUpdateTime = 'TaskGroupInstanceUpdateTime' in params ? params.TaskGroupInstanceUpdateTime : null; this.TaskGroupInstanceStatusType = 'TaskGroupInstanceStatusType' in params ? params.TaskGroupInstanceStatusType : null; this.TaskGroupInstanceStartTime = 'TaskGroupInstanceStartTime' in params ?