Skip to content

Commit ea99f91

Browse files
release 3.1.169 source code
1 parent 6a32ffc commit ea99f91

File tree

391 files changed

+35774
-4188
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

391 files changed

+35774
-4188
lines changed

CHANGELOG.md

Lines changed: 448 additions & 0 deletions
Large diffs are not rendered by default.

CHANGELOG_CN.md

Lines changed: 448 additions & 0 deletions
Large diffs are not rendered by default.

HuaweiCloud.sln

Lines changed: 1131 additions & 1131 deletions
Large diffs are not rendered by default.

Services/Aad/Aad.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
<GenerateAssemblyDescriptionAttribute>false</GenerateAssemblyDescriptionAttribute>
1616
<GenerateAssemblyInformationalVersionAttribute>false</GenerateAssemblyInformationalVersionAttribute>
1717
<PackageId>HuaweiCloud.SDK.Aad</PackageId>
18-
<Version>3.1.168</Version>
18+
<Version>3.1.169</Version>
1919
<Authors>HuaweiCloud</Authors>
2020
<Copyright>Copyright 2023 Huawei Technologies Co., Ltd.</Copyright>
2121
<Company>Huawei Technologies Co., Ltd.</Company>

Services/AntiDDoS/AntiDDoS.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
<GenerateAssemblyDescriptionAttribute>false</GenerateAssemblyDescriptionAttribute>
1616
<GenerateAssemblyInformationalVersionAttribute>false</GenerateAssemblyInformationalVersionAttribute>
1717
<PackageId>HuaweiCloud.SDK.AntiDDoS</PackageId>
18-
<Version>3.1.168</Version>
18+
<Version>3.1.169</Version>
1919
<Authors>HuaweiCloud</Authors>
2020
<Copyright>Copyright 2023 Huawei Technologies Co., Ltd.</Copyright>
2121
<Company>Huawei Technologies Co., Ltd.</Company>

Services/Aom/Aom.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
<GenerateAssemblyDescriptionAttribute>false</GenerateAssemblyDescriptionAttribute>
1616
<GenerateAssemblyInformationalVersionAttribute>false</GenerateAssemblyInformationalVersionAttribute>
1717
<PackageId>HuaweiCloud.SDK.Aom</PackageId>
18-
<Version>3.1.168</Version>
18+
<Version>3.1.169</Version>
1919
<Authors>HuaweiCloud</Authors>
2020
<Copyright>Copyright 2023 Huawei Technologies Co., Ltd.</Copyright>
2121
<Company>Huawei Technologies Co., Ltd.</Company>

Services/Aom/V2/AomAsyncClient.cs

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -183,6 +183,30 @@ public AsyncInvoker<AddOrUpdateServiceDiscoveryRulesResponse> AddOrUpdateService
183183
return new AsyncInvoker<AddOrUpdateServiceDiscoveryRulesResponse>(this, "PUT", request, JsonUtils.DeSerialize<AddOrUpdateServiceDiscoveryRulesResponse>);
184184
}
185185

186+
/// <summary>
187+
/// 批量更新Prometheus监控告警规则
188+
///
189+
/// 该接口用于批量启停Prometheus监控告警规则、批量修改Prometheus监控告警规则的告警行动规则。
190+
///
191+
/// Please refer to HUAWEI cloud API Explorer for details.
192+
/// </summary>
193+
public async Task<BatchUpdateAlarmRuleResponse> BatchUpdateAlarmRuleAsync(BatchUpdateAlarmRuleRequest batchUpdateAlarmRuleRequest)
194+
{
195+
var urlParam = new Dictionary<string, string>();
196+
var urlPath = HttpUtils.AddUrlPath("/v4/{project_id}/alarm-rules/batch-update", urlParam);
197+
var request = HttpUtils.InitSdkRequest(urlPath, "application/json", batchUpdateAlarmRuleRequest);
198+
var response = await DoHttpRequestAsync("PUT", request);
199+
return JsonUtils.DeSerialize<BatchUpdateAlarmRuleResponse>(response);
200+
}
201+
202+
public AsyncInvoker<BatchUpdateAlarmRuleResponse> BatchUpdateAlarmRuleAsyncInvoker(BatchUpdateAlarmRuleRequest batchUpdateAlarmRuleRequest)
203+
{
204+
var urlParam = new Dictionary<string, string>();
205+
var urlPath = HttpUtils.AddUrlPath("/v4/{project_id}/alarm-rules/batch-update", urlParam);
206+
var request = HttpUtils.InitSdkRequest(urlPath, "application/json", batchUpdateAlarmRuleRequest);
207+
return new AsyncInvoker<BatchUpdateAlarmRuleResponse>(this, "PUT", request, JsonUtils.DeSerialize<BatchUpdateAlarmRuleResponse>);
208+
}
209+
186210
/// <summary>
187211
/// 统计事件告警信息
188212
///

Services/Aom/V2/AomClient.cs

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -182,6 +182,30 @@ public SyncInvoker<AddOrUpdateServiceDiscoveryRulesResponse> AddOrUpdateServiceD
182182
return new SyncInvoker<AddOrUpdateServiceDiscoveryRulesResponse>(this, "PUT", request, JsonUtils.DeSerialize<AddOrUpdateServiceDiscoveryRulesResponse>);
183183
}
184184

185+
/// <summary>
186+
/// 批量更新Prometheus监控告警规则
187+
///
188+
/// 该接口用于批量启停Prometheus监控告警规则、批量修改Prometheus监控告警规则的告警行动规则。
189+
///
190+
/// Please refer to HUAWEI cloud API Explorer for details.
191+
/// </summary>
192+
public BatchUpdateAlarmRuleResponse BatchUpdateAlarmRule(BatchUpdateAlarmRuleRequest batchUpdateAlarmRuleRequest)
193+
{
194+
var urlParam = new Dictionary<string, string>();
195+
var urlPath = HttpUtils.AddUrlPath("/v4/{project_id}/alarm-rules/batch-update", urlParam);
196+
var request = HttpUtils.InitSdkRequest(urlPath, "application/json", batchUpdateAlarmRuleRequest);
197+
var response = DoHttpRequestSync("PUT", request);
198+
return JsonUtils.DeSerialize<BatchUpdateAlarmRuleResponse>(response);
199+
}
200+
201+
public SyncInvoker<BatchUpdateAlarmRuleResponse> BatchUpdateAlarmRuleInvoker(BatchUpdateAlarmRuleRequest batchUpdateAlarmRuleRequest)
202+
{
203+
var urlParam = new Dictionary<string, string>();
204+
var urlPath = HttpUtils.AddUrlPath("/v4/{project_id}/alarm-rules/batch-update", urlParam);
205+
var request = HttpUtils.InitSdkRequest(urlPath, "application/json", batchUpdateAlarmRuleRequest);
206+
return new SyncInvoker<BatchUpdateAlarmRuleResponse>(this, "PUT", request, JsonUtils.DeSerialize<BatchUpdateAlarmRuleResponse>);
207+
}
208+
185209
/// <summary>
186210
/// 统计事件告警信息
187211
///
Lines changed: 107 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,107 @@
1+
using System;
2+
using System.Collections.Generic;
3+
using System.Text;
4+
using System.Linq;
5+
using System.Runtime.Serialization;
6+
7+
using Newtonsoft.Json;
8+
using Newtonsoft.Json.Converters;
9+
using HuaweiCloud.SDK.Core;
10+
11+
namespace HuaweiCloud.SDK.Aom.V2.Model
12+
{
13+
/// <summary>
14+
///
15+
/// </summary>
16+
public class BatchAlarmRulesBody
17+
{
18+
19+
/// <summary>
20+
/// 当前状态是否启用。
21+
/// </summary>
22+
[JsonProperty("alarm_rule_enable", NullValueHandling = NullValueHandling.Ignore)]
23+
public bool? AlarmRuleEnable { get; set; }
24+
25+
/// <summary>
26+
/// 告警规则id。
27+
/// </summary>
28+
[JsonProperty("alarm_rule_id", NullValueHandling = NullValueHandling.Ignore)]
29+
public long? AlarmRuleId { get; set; }
30+
31+
/// <summary>
32+
/// 告警规则名称。
33+
/// </summary>
34+
[JsonProperty("alarm_rule_name", NullValueHandling = NullValueHandling.Ignore)]
35+
public string AlarmRuleName { get; set; }
36+
37+
/// <summary>
38+
/// 告警规则类型。 - metric:Prometheus指标 - event: 事件
39+
/// </summary>
40+
[JsonProperty("alarm_rule_type", NullValueHandling = NullValueHandling.Ignore)]
41+
public string AlarmRuleType { get; set; }
42+
43+
/// <summary>
44+
/// 企业项目id。获取方式请参见:[获取企业项目ID](aom_04_0024.xml) 。 批量启停或批量修改单个企业项目下实例,填写企业项目id。
45+
/// </summary>
46+
[JsonProperty("enterprise_project_id", NullValueHandling = NullValueHandling.Ignore)]
47+
public string EnterpriseProjectId { get; set; }
48+
49+
50+
51+
/// <summary>
52+
/// Get the string
53+
/// </summary>
54+
public override string ToString()
55+
{
56+
var sb = new StringBuilder();
57+
sb.Append("class BatchAlarmRulesBody {\n");
58+
sb.Append(" alarmRuleEnable: ").Append(AlarmRuleEnable).Append("\n");
59+
sb.Append(" alarmRuleId: ").Append(AlarmRuleId).Append("\n");
60+
sb.Append(" alarmRuleName: ").Append(AlarmRuleName).Append("\n");
61+
sb.Append(" alarmRuleType: ").Append(AlarmRuleType).Append("\n");
62+
sb.Append(" enterpriseProjectId: ").Append(EnterpriseProjectId).Append("\n");
63+
sb.Append("}\n");
64+
return sb.ToString();
65+
}
66+
67+
/// <summary>
68+
/// Returns true if objects are equal
69+
/// </summary>
70+
public override bool Equals(object input)
71+
{
72+
return this.Equals(input as BatchAlarmRulesBody);
73+
}
74+
75+
/// <summary>
76+
/// Returns true if objects are equal
77+
/// </summary>
78+
public bool Equals(BatchAlarmRulesBody input)
79+
{
80+
if (input == null) return false;
81+
if (this.AlarmRuleEnable != input.AlarmRuleEnable || (this.AlarmRuleEnable != null && !this.AlarmRuleEnable.Equals(input.AlarmRuleEnable))) return false;
82+
if (this.AlarmRuleId != input.AlarmRuleId || (this.AlarmRuleId != null && !this.AlarmRuleId.Equals(input.AlarmRuleId))) return false;
83+
if (this.AlarmRuleName != input.AlarmRuleName || (this.AlarmRuleName != null && !this.AlarmRuleName.Equals(input.AlarmRuleName))) return false;
84+
if (this.AlarmRuleType != input.AlarmRuleType || (this.AlarmRuleType != null && !this.AlarmRuleType.Equals(input.AlarmRuleType))) return false;
85+
if (this.EnterpriseProjectId != input.EnterpriseProjectId || (this.EnterpriseProjectId != null && !this.EnterpriseProjectId.Equals(input.EnterpriseProjectId))) return false;
86+
87+
return true;
88+
}
89+
90+
/// <summary>
91+
/// Get hash code
92+
/// </summary>
93+
public override int GetHashCode()
94+
{
95+
unchecked // Overflow is fine, just wrap
96+
{
97+
var hashCode = 41;
98+
if (this.AlarmRuleEnable != null) hashCode = hashCode * 59 + this.AlarmRuleEnable.GetHashCode();
99+
if (this.AlarmRuleId != null) hashCode = hashCode * 59 + this.AlarmRuleId.GetHashCode();
100+
if (this.AlarmRuleName != null) hashCode = hashCode * 59 + this.AlarmRuleName.GetHashCode();
101+
if (this.AlarmRuleType != null) hashCode = hashCode * 59 + this.AlarmRuleType.GetHashCode();
102+
if (this.EnterpriseProjectId != null) hashCode = hashCode * 59 + this.EnterpriseProjectId.GetHashCode();
103+
return hashCode;
104+
}
105+
}
106+
}
107+
}
Lines changed: 161 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,161 @@
1+
using System;
2+
using System.Collections.Generic;
3+
using System.Text;
4+
using System.Linq;
5+
using System.Runtime.Serialization;
6+
7+
using Newtonsoft.Json;
8+
using Newtonsoft.Json.Converters;
9+
using HuaweiCloud.SDK.Core;
10+
11+
namespace HuaweiCloud.SDK.Aom.V2.Model
12+
{
13+
/// <summary>
14+
///
15+
/// </summary>
16+
public class BatchUpdateActionRules
17+
{
18+
19+
/// <summary>
20+
/// 告警规则id。
21+
/// </summary>
22+
[JsonProperty("alarm_rule_id", NullValueHandling = NullValueHandling.Ignore)]
23+
public long? AlarmRuleId { get; set; }
24+
25+
/// <summary>
26+
/// 告警规则名称。
27+
/// </summary>
28+
[JsonProperty("alarm_rule_name", NullValueHandling = NullValueHandling.Ignore)]
29+
public string AlarmRuleName { get; set; }
30+
31+
/// <summary>
32+
/// 告警规则类型。
33+
/// </summary>
34+
[JsonProperty("alarm_rule_type", NullValueHandling = NullValueHandling.Ignore)]
35+
public string AlarmRuleType { get; set; }
36+
37+
/// <summary>
38+
/// 待绑定的告警行动规则名称。
39+
/// </summary>
40+
[JsonProperty("bind_notification_rule_id", NullValueHandling = NullValueHandling.Ignore)]
41+
public string BindNotificationRuleId { get; set; }
42+
43+
/// <summary>
44+
/// 通知频率 - 当通知类型为“alarm_policy”时,填“-1” - 当通知类型为“direct”时, - “0”:只告警一次 - “300”:每5分钟 - “600”:每10分钟 - “900”:每15分钟 - “1800”:每30分钟 - “3600”:每1小时 - “10800”:每3小时 - “21600”:每6小时 - “43200”:每12小时 - “86400”:每天
45+
/// </summary>
46+
[JsonProperty("frequency", NullValueHandling = NullValueHandling.Ignore)]
47+
public string Frequency { get; set; }
48+
49+
/// <summary>
50+
/// 是否启用告警通知规则。 - 当通知类型为“direct”时,填true - 当通知类型为“alarm_policy”时,填false 如果告警触发“notify_triggered”或告警恢复“notify_resolved”都设置为false(即都不进行告警通知),则notification_enable需设置为false。
51+
/// </summary>
52+
[JsonProperty("notification_enable", NullValueHandling = NullValueHandling.Ignore)]
53+
public bool? NotificationEnable { get; set; }
54+
55+
/// <summary>
56+
/// 通知类型。 - “direct”:直接告警 - “alarm_policy”:告警降噪
57+
/// </summary>
58+
[JsonProperty("notification_type", NullValueHandling = NullValueHandling.Ignore)]
59+
public string NotificationType { get; set; }
60+
61+
/// <summary>
62+
/// 告警解决是否通知。 - true:通知 - false:不通知
63+
/// </summary>
64+
[JsonProperty("notify_resolved", NullValueHandling = NullValueHandling.Ignore)]
65+
public bool? NotifyResolved { get; set; }
66+
67+
/// <summary>
68+
/// 告警触发是否通知。 - true:通知 - false:不通知
69+
/// </summary>
70+
[JsonProperty("notify_triggered", NullValueHandling = NullValueHandling.Ignore)]
71+
public bool? NotifyTriggered { get; set; }
72+
73+
/// <summary>
74+
/// 启用告警分组规则。 - 当通知类型为“alarm_policy”时:true - 当通知类型为“direct”时:false 如果告警触发“notify_triggered”或告警恢复“notify_resolved”都设置为false(即都不进行告警通知),则route_group_enable需设置为false。
75+
/// </summary>
76+
[JsonProperty("route_group_enable", NullValueHandling = NullValueHandling.Ignore)]
77+
public bool? RouteGroupEnable { get; set; }
78+
79+
/// <summary>
80+
/// 告警分组规则名称。 - 当route_group_enable 为true时,填告警分组规则名称 - 当route_group_enable 为false时,填“”
81+
/// </summary>
82+
[JsonProperty("route_group_rule", NullValueHandling = NullValueHandling.Ignore)]
83+
public string RouteGroupRule { get; set; }
84+
85+
86+
87+
/// <summary>
88+
/// Get the string
89+
/// </summary>
90+
public override string ToString()
91+
{
92+
var sb = new StringBuilder();
93+
sb.Append("class BatchUpdateActionRules {\n");
94+
sb.Append(" alarmRuleId: ").Append(AlarmRuleId).Append("\n");
95+
sb.Append(" alarmRuleName: ").Append(AlarmRuleName).Append("\n");
96+
sb.Append(" alarmRuleType: ").Append(AlarmRuleType).Append("\n");
97+
sb.Append(" bindNotificationRuleId: ").Append(BindNotificationRuleId).Append("\n");
98+
sb.Append(" frequency: ").Append(Frequency).Append("\n");
99+
sb.Append(" notificationEnable: ").Append(NotificationEnable).Append("\n");
100+
sb.Append(" notificationType: ").Append(NotificationType).Append("\n");
101+
sb.Append(" notifyResolved: ").Append(NotifyResolved).Append("\n");
102+
sb.Append(" notifyTriggered: ").Append(NotifyTriggered).Append("\n");
103+
sb.Append(" routeGroupEnable: ").Append(RouteGroupEnable).Append("\n");
104+
sb.Append(" routeGroupRule: ").Append(RouteGroupRule).Append("\n");
105+
sb.Append("}\n");
106+
return sb.ToString();
107+
}
108+
109+
/// <summary>
110+
/// Returns true if objects are equal
111+
/// </summary>
112+
public override bool Equals(object input)
113+
{
114+
return this.Equals(input as BatchUpdateActionRules);
115+
}
116+
117+
/// <summary>
118+
/// Returns true if objects are equal
119+
/// </summary>
120+
public bool Equals(BatchUpdateActionRules input)
121+
{
122+
if (input == null) return false;
123+
if (this.AlarmRuleId != input.AlarmRuleId || (this.AlarmRuleId != null && !this.AlarmRuleId.Equals(input.AlarmRuleId))) return false;
124+
if (this.AlarmRuleName != input.AlarmRuleName || (this.AlarmRuleName != null && !this.AlarmRuleName.Equals(input.AlarmRuleName))) return false;
125+
if (this.AlarmRuleType != input.AlarmRuleType || (this.AlarmRuleType != null && !this.AlarmRuleType.Equals(input.AlarmRuleType))) return false;
126+
if (this.BindNotificationRuleId != input.BindNotificationRuleId || (this.BindNotificationRuleId != null && !this.BindNotificationRuleId.Equals(input.BindNotificationRuleId))) return false;
127+
if (this.Frequency != input.Frequency || (this.Frequency != null && !this.Frequency.Equals(input.Frequency))) return false;
128+
if (this.NotificationEnable != input.NotificationEnable || (this.NotificationEnable != null && !this.NotificationEnable.Equals(input.NotificationEnable))) return false;
129+
if (this.NotificationType != input.NotificationType || (this.NotificationType != null && !this.NotificationType.Equals(input.NotificationType))) return false;
130+
if (this.NotifyResolved != input.NotifyResolved || (this.NotifyResolved != null && !this.NotifyResolved.Equals(input.NotifyResolved))) return false;
131+
if (this.NotifyTriggered != input.NotifyTriggered || (this.NotifyTriggered != null && !this.NotifyTriggered.Equals(input.NotifyTriggered))) return false;
132+
if (this.RouteGroupEnable != input.RouteGroupEnable || (this.RouteGroupEnable != null && !this.RouteGroupEnable.Equals(input.RouteGroupEnable))) return false;
133+
if (this.RouteGroupRule != input.RouteGroupRule || (this.RouteGroupRule != null && !this.RouteGroupRule.Equals(input.RouteGroupRule))) return false;
134+
135+
return true;
136+
}
137+
138+
/// <summary>
139+
/// Get hash code
140+
/// </summary>
141+
public override int GetHashCode()
142+
{
143+
unchecked // Overflow is fine, just wrap
144+
{
145+
var hashCode = 41;
146+
if (this.AlarmRuleId != null) hashCode = hashCode * 59 + this.AlarmRuleId.GetHashCode();
147+
if (this.AlarmRuleName != null) hashCode = hashCode * 59 + this.AlarmRuleName.GetHashCode();
148+
if (this.AlarmRuleType != null) hashCode = hashCode * 59 + this.AlarmRuleType.GetHashCode();
149+
if (this.BindNotificationRuleId != null) hashCode = hashCode * 59 + this.BindNotificationRuleId.GetHashCode();
150+
if (this.Frequency != null) hashCode = hashCode * 59 + this.Frequency.GetHashCode();
151+
if (this.NotificationEnable != null) hashCode = hashCode * 59 + this.NotificationEnable.GetHashCode();
152+
if (this.NotificationType != null) hashCode = hashCode * 59 + this.NotificationType.GetHashCode();
153+
if (this.NotifyResolved != null) hashCode = hashCode * 59 + this.NotifyResolved.GetHashCode();
154+
if (this.NotifyTriggered != null) hashCode = hashCode * 59 + this.NotifyTriggered.GetHashCode();
155+
if (this.RouteGroupEnable != null) hashCode = hashCode * 59 + this.RouteGroupEnable.GetHashCode();
156+
if (this.RouteGroupRule != null) hashCode = hashCode * 59 + this.RouteGroupRule.GetHashCode();
157+
return hashCode;
158+
}
159+
}
160+
}
161+
}

0 commit comments

Comments
 (0)