@daocloud-proto/mcamel-postgresql 0.0.2-65 → 0.0.2-652
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/cloudshell.pb.ts +3 -3
- package/cluster.pb.ts +314 -10
- package/common.pb.ts +87 -2
- package/metric.pb.ts +13 -1
- package/package.json +1 -1
- package/postgresql.pb.ts +353 -25
- package/storage_config.pb.ts +188 -0
- package/template.pb.ts +200 -0
- package/version.pb.ts +8 -1
package/cloudshell.pb.ts
CHANGED
|
@@ -67,12 +67,12 @@ export type GetorDeleteCloudShellRequest = {
|
|
|
67
67
|
|
|
68
68
|
export class CloudShellService {
|
|
69
69
|
static CreateCloudShell(req: CreateCloudShellRequest, initReq?: fm.InitReq): Promise<CloudShell> {
|
|
70
|
-
return fm.fetchReq<CreateCloudShellRequest, CloudShell>(`/apis/mcamel.io/postgresql/
|
|
70
|
+
return fm.fetchReq<CreateCloudShellRequest, CloudShell>(`/apis/mcamel.io/postgresql/v1alpha2/cloudshells`, {...initReq, method: "POST", body: JSON.stringify(req)})
|
|
71
71
|
}
|
|
72
72
|
static GetCloudShell(req: GetorDeleteCloudShellRequest, initReq?: fm.InitReq): Promise<CloudShell> {
|
|
73
|
-
return fm.fetchReq<GetorDeleteCloudShellRequest, CloudShell>(`/apis/mcamel.io/postgresql/
|
|
73
|
+
return fm.fetchReq<GetorDeleteCloudShellRequest, CloudShell>(`/apis/mcamel.io/postgresql/v1alpha2/cloudshells/${req["name"]}?${fm.renderURLSearchParams(req, ["name"])}`, {...initReq, method: "GET"})
|
|
74
74
|
}
|
|
75
75
|
static DeleteCloudShell(req: GetorDeleteCloudShellRequest, initReq?: fm.InitReq): Promise<GoogleProtobufEmpty.Empty> {
|
|
76
|
-
return fm.fetchReq<GetorDeleteCloudShellRequest, GoogleProtobufEmpty.Empty>(`/apis/mcamel.io/postgresql/
|
|
76
|
+
return fm.fetchReq<GetorDeleteCloudShellRequest, GoogleProtobufEmpty.Empty>(`/apis/mcamel.io/postgresql/v1alpha2/cloudshells/${req["name"]}`, {...initReq, method: "DELETE"})
|
|
77
77
|
}
|
|
78
78
|
}
|
package/cluster.pb.ts
CHANGED
|
@@ -7,12 +7,50 @@
|
|
|
7
7
|
import * as CommonCommon from "./common.pb"
|
|
8
8
|
import * as fm from "./fetch.pb"
|
|
9
9
|
|
|
10
|
+
export enum PermissionsType {
|
|
11
|
+
None = "None",
|
|
12
|
+
GetInstance = "GetInstance",
|
|
13
|
+
CreateInstance = "CreateInstance",
|
|
14
|
+
UpdateInstance = "UpdateInstance",
|
|
15
|
+
DeleteInstance = "DeleteInstance",
|
|
16
|
+
GetMetric = "GetMetric",
|
|
17
|
+
GetInstanceLog = "GetInstanceLog",
|
|
18
|
+
GetConfig = "GetConfig",
|
|
19
|
+
UpdateConfig = "UpdateConfig",
|
|
20
|
+
GetBackup = "GetBackup",
|
|
21
|
+
CreateBackup = "CreateBackup",
|
|
22
|
+
UpdateBackup = "UpdateBackup",
|
|
23
|
+
DeleteBackup = "DeleteBackup",
|
|
24
|
+
GetBackupConf = "GetBackupConf",
|
|
25
|
+
CreateBackupConf = "CreateBackupConf",
|
|
26
|
+
UpdateBackupConf = "UpdateBackupConf",
|
|
27
|
+
DeleteBackupConf = "DeleteBackupConf",
|
|
28
|
+
GetTemplate = "GetTemplate",
|
|
29
|
+
CreateTemplate = "CreateTemplate",
|
|
30
|
+
UpdateTemplate = "UpdateTemplate",
|
|
31
|
+
DeleteTemplate = "DeleteTemplate",
|
|
32
|
+
GetUserPassword = "GetUserPassword",
|
|
33
|
+
ExportTemplate = "ExportTemplate",
|
|
34
|
+
ImportTemplate = "ImportTemplate",
|
|
35
|
+
}
|
|
36
|
+
|
|
10
37
|
export enum EventType {
|
|
11
38
|
EVENT_TYPE_UNSPECIFIED = "EVENT_TYPE_UNSPECIFIED",
|
|
12
39
|
Normal = "Normal",
|
|
13
40
|
Warning = "Warning",
|
|
14
41
|
}
|
|
15
42
|
|
|
43
|
+
export enum GetClusterNodeTaintListRespTaintEffect {
|
|
44
|
+
NoSchedule = "NoSchedule",
|
|
45
|
+
PreferNoSchedule = "PreferNoSchedule",
|
|
46
|
+
NoExecute = "NoExecute",
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
export enum InstallFileReqGVR {
|
|
50
|
+
None = "None",
|
|
51
|
+
CustomResourceDefinition = "CustomResourceDefinition",
|
|
52
|
+
}
|
|
53
|
+
|
|
16
54
|
export enum GetAllEventListReqSortDir {
|
|
17
55
|
ASC = "ASC",
|
|
18
56
|
DESC = "DESC",
|
|
@@ -28,11 +66,149 @@ export enum GetWorkspaceListReqSortDir {
|
|
|
28
66
|
DESC = "DESC",
|
|
29
67
|
}
|
|
30
68
|
|
|
69
|
+
export enum ClusterItemNetworkMode {
|
|
70
|
+
Unknown = "Unknown",
|
|
71
|
+
Flannel = "Flannel",
|
|
72
|
+
Calico = "Calico",
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
export enum ClusterSettingPluginPluginName {
|
|
76
|
+
PLUGIN_NAME_UNSPECIFIED = "PLUGIN_NAME_UNSPECIFIED",
|
|
77
|
+
HPA = "HPA",
|
|
78
|
+
Insight = "Insight",
|
|
79
|
+
GPU = "GPU",
|
|
80
|
+
METALLB = "METALLB",
|
|
81
|
+
Spiderpool = "Spiderpool",
|
|
82
|
+
CustomMetrics = "CustomMetrics",
|
|
83
|
+
CronHPA = "CronHPA",
|
|
84
|
+
VPA = "VPA",
|
|
85
|
+
Hwameistor = "Hwameistor",
|
|
86
|
+
Flannel = "Flannel",
|
|
87
|
+
KubeOvn = "KubeOvn",
|
|
88
|
+
OLM = "OLM",
|
|
89
|
+
EgressGateway = "EgressGateway",
|
|
90
|
+
Snapshot = "Snapshot",
|
|
91
|
+
DRA = "DRA",
|
|
92
|
+
}
|
|
93
|
+
|
|
31
94
|
export enum GetInsightAgentStatusRespInsightAgentStatus {
|
|
32
95
|
NotInstall = "NotInstall",
|
|
33
96
|
Install = "Install",
|
|
34
97
|
}
|
|
35
98
|
|
|
99
|
+
export type GetClusterNodeTaintListReq = {
|
|
100
|
+
cluster?: string
|
|
101
|
+
nodeName?: string
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
export type GetClusterNodeTaintListRespTaint = {
|
|
105
|
+
key?: string
|
|
106
|
+
value?: string
|
|
107
|
+
effect?: GetClusterNodeTaintListRespTaintEffect
|
|
108
|
+
nodeName?: string
|
|
109
|
+
}
|
|
110
|
+
|
|
111
|
+
export type GetClusterNodeTaintListResp = {
|
|
112
|
+
items?: GetClusterNodeTaintListRespTaint[]
|
|
113
|
+
}
|
|
114
|
+
|
|
115
|
+
export type GetClusterNodeListReq = {
|
|
116
|
+
cluster?: string
|
|
117
|
+
}
|
|
118
|
+
|
|
119
|
+
export type GetClusterNodeListRespNode = {
|
|
120
|
+
name?: string
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
export type GetClusterNodeListResp = {
|
|
124
|
+
items?: GetClusterNodeListRespNode[]
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
export type GetClusterReq = {
|
|
128
|
+
workspaceId?: number
|
|
129
|
+
name?: string
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
export type GetClusterResp = {
|
|
133
|
+
cluster?: ClusterItem
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
export type InstallFileReq = {
|
|
137
|
+
cluster?: string
|
|
138
|
+
path?: string
|
|
139
|
+
gvr?: InstallFileReqGVR
|
|
140
|
+
}
|
|
141
|
+
|
|
142
|
+
export type InstallFileResp = {
|
|
143
|
+
message?: string
|
|
144
|
+
}
|
|
145
|
+
|
|
146
|
+
export type GetInstallVersionReq = {
|
|
147
|
+
cluster?: string
|
|
148
|
+
}
|
|
149
|
+
|
|
150
|
+
export type GetInstallVersionRespSupportVersion = {
|
|
151
|
+
minVersion?: string
|
|
152
|
+
maxVersion?: string
|
|
153
|
+
}
|
|
154
|
+
|
|
155
|
+
export type GetInstallVersionRespStatus = {
|
|
156
|
+
inRange?: boolean
|
|
157
|
+
}
|
|
158
|
+
|
|
159
|
+
export type GetInstallVersionResp = {
|
|
160
|
+
clusterVersion?: string
|
|
161
|
+
supportVersion?: GetInstallVersionRespSupportVersion
|
|
162
|
+
status?: GetInstallVersionRespStatus
|
|
163
|
+
}
|
|
164
|
+
|
|
165
|
+
export type RestartInstanceReq = {
|
|
166
|
+
workspaceId?: number
|
|
167
|
+
cluster?: string
|
|
168
|
+
namespace?: string
|
|
169
|
+
name?: string
|
|
170
|
+
extra?: string
|
|
171
|
+
}
|
|
172
|
+
|
|
173
|
+
export type RestartInstanceResp = {
|
|
174
|
+
message?: string
|
|
175
|
+
}
|
|
176
|
+
|
|
177
|
+
export type GetPermissionsListReq = {
|
|
178
|
+
workspaceId?: number
|
|
179
|
+
}
|
|
180
|
+
|
|
181
|
+
export type GetPermissionsListRespPermissions = {
|
|
182
|
+
getInstance?: boolean
|
|
183
|
+
createInstance?: boolean
|
|
184
|
+
updateInstance?: boolean
|
|
185
|
+
deleteInstance?: boolean
|
|
186
|
+
getMetric?: boolean
|
|
187
|
+
getInstanceLog?: boolean
|
|
188
|
+
getConfig?: boolean
|
|
189
|
+
updateConfig?: boolean
|
|
190
|
+
getBackup?: boolean
|
|
191
|
+
createBackup?: boolean
|
|
192
|
+
updateBackup?: boolean
|
|
193
|
+
deleteBackup?: boolean
|
|
194
|
+
getBackupConf?: boolean
|
|
195
|
+
createBackupConf?: boolean
|
|
196
|
+
updateBackupConf?: boolean
|
|
197
|
+
deleteBackupConf?: boolean
|
|
198
|
+
getTemplate?: boolean
|
|
199
|
+
createTemplate?: boolean
|
|
200
|
+
updateTemplate?: boolean
|
|
201
|
+
deleteTemplate?: boolean
|
|
202
|
+
getUserPassword?: boolean
|
|
203
|
+
exportTemplate?: boolean
|
|
204
|
+
importTemplate?: boolean
|
|
205
|
+
}
|
|
206
|
+
|
|
207
|
+
export type GetPermissionsListResp = {
|
|
208
|
+
permissionsBool?: GetPermissionsListRespPermissions
|
|
209
|
+
permissions?: PermissionsType[]
|
|
210
|
+
}
|
|
211
|
+
|
|
36
212
|
export type GetAllEventKindsListResp = {
|
|
37
213
|
data?: string[]
|
|
38
214
|
}
|
|
@@ -52,6 +228,7 @@ export type GetAllEventListReq = {
|
|
|
52
228
|
name?: string
|
|
53
229
|
eventType?: EventType
|
|
54
230
|
kindName?: string
|
|
231
|
+
workspaceId?: number
|
|
55
232
|
}
|
|
56
233
|
|
|
57
234
|
export type GetAllEventListRespItemsSource = {
|
|
@@ -106,8 +283,32 @@ export type GetClusterNodeLabelListRespLabel = {
|
|
|
106
283
|
value?: string[]
|
|
107
284
|
}
|
|
108
285
|
|
|
286
|
+
export type GetClusterNodeLabelListRespNode2Label = {
|
|
287
|
+
nodeName?: string
|
|
288
|
+
label?: GetClusterNodeLabelListRespLabel[]
|
|
289
|
+
}
|
|
290
|
+
|
|
109
291
|
export type GetClusterNodeLabelListResp = {
|
|
110
292
|
items?: GetClusterNodeLabelListRespLabel[]
|
|
293
|
+
items1?: GetClusterNodeLabelListRespNode2Label[]
|
|
294
|
+
pagination?: CommonCommon.Pagination
|
|
295
|
+
}
|
|
296
|
+
|
|
297
|
+
export type GetClusterPodLabelListReq = {
|
|
298
|
+
page?: number
|
|
299
|
+
pageSize?: number
|
|
300
|
+
searchKey?: string
|
|
301
|
+
filterNamespace?: string
|
|
302
|
+
cluster?: string
|
|
303
|
+
}
|
|
304
|
+
|
|
305
|
+
export type GetClusterPodLabelListRespLabel = {
|
|
306
|
+
key?: string
|
|
307
|
+
value?: string[]
|
|
308
|
+
}
|
|
309
|
+
|
|
310
|
+
export type GetClusterPodLabelListResp = {
|
|
311
|
+
items?: GetClusterPodLabelListRespLabel[]
|
|
111
312
|
pagination?: CommonCommon.Pagination
|
|
112
313
|
}
|
|
113
314
|
|
|
@@ -183,6 +384,7 @@ export type GetWorkspaceListReq = {
|
|
|
183
384
|
export type GetWorkspaceListRespItem = {
|
|
184
385
|
workspaceId?: number
|
|
185
386
|
alias?: string
|
|
387
|
+
visible?: boolean
|
|
186
388
|
}
|
|
187
389
|
|
|
188
390
|
export type GetWorkspaceListResp = {
|
|
@@ -190,15 +392,55 @@ export type GetWorkspaceListResp = {
|
|
|
190
392
|
pagination?: CommonCommon.Pagination
|
|
191
393
|
}
|
|
192
394
|
|
|
395
|
+
export type GetClusterHostnetworkPortsReq = {
|
|
396
|
+
workspaceId?: number
|
|
397
|
+
cluster?: string
|
|
398
|
+
}
|
|
399
|
+
|
|
193
400
|
export type GetClusterListReq = {
|
|
194
401
|
workspaceId?: number
|
|
402
|
+
searchKey?: string
|
|
403
|
+
}
|
|
404
|
+
|
|
405
|
+
export type GetClusterHostnetworkPortsResp = {
|
|
406
|
+
items?: number[]
|
|
195
407
|
}
|
|
196
408
|
|
|
197
409
|
export type GetClusterListResp = {
|
|
198
410
|
items?: string[]
|
|
411
|
+
clusters?: ClusterItem[]
|
|
199
412
|
pagination?: CommonCommon.Pagination
|
|
200
413
|
}
|
|
201
414
|
|
|
415
|
+
export type ClusterItemMetadata = {
|
|
416
|
+
name?: string
|
|
417
|
+
}
|
|
418
|
+
|
|
419
|
+
export type ClusterItemStatus = {
|
|
420
|
+
networkMode?: ClusterItemNetworkMode[]
|
|
421
|
+
setting?: ClusterSetting
|
|
422
|
+
clusterStatus?: CommonCommon.ClusterStatus
|
|
423
|
+
}
|
|
424
|
+
|
|
425
|
+
export type ClusterItem = {
|
|
426
|
+
metadata?: ClusterItemMetadata
|
|
427
|
+
status?: ClusterItemStatus
|
|
428
|
+
}
|
|
429
|
+
|
|
430
|
+
export type ClusterSettingPlugin = {
|
|
431
|
+
name?: ClusterSettingPluginPluginName
|
|
432
|
+
enabled?: boolean
|
|
433
|
+
intelligentDetection?: boolean
|
|
434
|
+
externalAddress?: string
|
|
435
|
+
setting?: string
|
|
436
|
+
healthy?: boolean
|
|
437
|
+
}
|
|
438
|
+
|
|
439
|
+
export type ClusterSetting = {
|
|
440
|
+
plugins?: ClusterSettingPlugin[]
|
|
441
|
+
network?: ClusterSettingPlugin[]
|
|
442
|
+
}
|
|
443
|
+
|
|
202
444
|
export type GetClusterNamespaceListReq = {
|
|
203
445
|
workspaceId?: number
|
|
204
446
|
cluster?: string
|
|
@@ -206,6 +448,7 @@ export type GetClusterNamespaceListReq = {
|
|
|
206
448
|
|
|
207
449
|
export type GetClusterNamespaceListResp = {
|
|
208
450
|
items?: string[]
|
|
451
|
+
disableItems?: string[]
|
|
209
452
|
pagination?: CommonCommon.Pagination
|
|
210
453
|
}
|
|
211
454
|
|
|
@@ -215,37 +458,98 @@ export type GetInsightAgentStatusReq = {
|
|
|
215
458
|
|
|
216
459
|
export type GetInsightAgentStatusResp = {
|
|
217
460
|
status?: GetInsightAgentStatusRespInsightAgentStatus
|
|
461
|
+
clusterStatus?: CommonCommon.ClusterStatus
|
|
462
|
+
}
|
|
463
|
+
|
|
464
|
+
export type GetResourceQuotaReq = {
|
|
465
|
+
cluster?: string
|
|
466
|
+
namespace?: string
|
|
467
|
+
}
|
|
468
|
+
|
|
469
|
+
export type GetResourceQuotaRespMetadata = {
|
|
470
|
+
uid?: string
|
|
471
|
+
name?: string
|
|
472
|
+
namespace?: string
|
|
473
|
+
annotations?: {[key: string]: string}
|
|
474
|
+
resourceVersion?: string
|
|
475
|
+
creationTimestamp?: string
|
|
476
|
+
}
|
|
477
|
+
|
|
478
|
+
export type GetResourceQuotaRespSpec = {
|
|
479
|
+
hard?: {[key: string]: string}
|
|
480
|
+
}
|
|
481
|
+
|
|
482
|
+
export type GetResourceQuotaRespStatus = {
|
|
483
|
+
hard?: {[key: string]: string}
|
|
484
|
+
used?: {[key: string]: string}
|
|
485
|
+
available?: {[key: string]: string}
|
|
486
|
+
}
|
|
487
|
+
|
|
488
|
+
export type GetResourceQuotaResp = {
|
|
489
|
+
metadata?: GetResourceQuotaRespMetadata
|
|
490
|
+
spec?: GetResourceQuotaRespSpec
|
|
491
|
+
status?: GetResourceQuotaRespStatus
|
|
218
492
|
}
|
|
219
493
|
|
|
220
494
|
export class Cluster {
|
|
221
495
|
static GetClusterList(req: GetClusterListReq, initReq?: fm.InitReq): Promise<GetClusterListResp> {
|
|
222
|
-
return fm.fetchReq<GetClusterListReq, GetClusterListResp>(`/apis/mcamel.io/postgresql/
|
|
496
|
+
return fm.fetchReq<GetClusterListReq, GetClusterListResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["workspaceId"]}/clusters?${fm.renderURLSearchParams(req, ["workspaceId"])}`, {...initReq, method: "GET"})
|
|
497
|
+
}
|
|
498
|
+
static GetCluster(req: GetClusterReq, initReq?: fm.InitReq): Promise<GetClusterResp> {
|
|
499
|
+
return fm.fetchReq<GetClusterReq, GetClusterResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["workspaceId"]}/clusters/${req["name"]}?${fm.renderURLSearchParams(req, ["workspaceId", "name"])}`, {...initReq, method: "GET"})
|
|
500
|
+
}
|
|
501
|
+
static GetClusterHostnetworkPorts(req: GetClusterHostnetworkPortsReq, initReq?: fm.InitReq): Promise<GetClusterHostnetworkPortsResp> {
|
|
502
|
+
return fm.fetchReq<GetClusterHostnetworkPortsReq, GetClusterHostnetworkPortsResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["workspaceId"]}/hostnetwork-ports?${fm.renderURLSearchParams(req, ["workspaceId"])}`, {...initReq, method: "GET"})
|
|
223
503
|
}
|
|
224
504
|
static GetClusterNamespaceList(req: GetClusterNamespaceListReq, initReq?: fm.InitReq): Promise<GetClusterNamespaceListResp> {
|
|
225
|
-
return fm.fetchReq<GetClusterNamespaceListReq, GetClusterNamespaceListResp>(`/apis/mcamel.io/postgresql/
|
|
505
|
+
return fm.fetchReq<GetClusterNamespaceListReq, GetClusterNamespaceListResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["workspaceId"]}/${req["cluster"]}/namespaces?${fm.renderURLSearchParams(req, ["workspaceId", "cluster"])}`, {...initReq, method: "GET"})
|
|
226
506
|
}
|
|
227
507
|
static GetClusterNodePortList(req: GetClusterNodePortListReq, initReq?: fm.InitReq): Promise<GetClusterNodePortListResp> {
|
|
228
|
-
return fm.fetchReq<GetClusterNodePortListReq, GetClusterNodePortListResp>(`/apis/mcamel.io/postgresql/
|
|
508
|
+
return fm.fetchReq<GetClusterNodePortListReq, GetClusterNodePortListResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["cluster"]}/nodeports?${fm.renderURLSearchParams(req, ["cluster"])}`, {...initReq, method: "GET"})
|
|
229
509
|
}
|
|
230
510
|
static GetClusterNodeLabelList(req: GetClusterNodeLabelListReq, initReq?: fm.InitReq): Promise<GetClusterNodeLabelListResp> {
|
|
231
|
-
return fm.fetchReq<GetClusterNodeLabelListReq, GetClusterNodeLabelListResp>(`/apis/mcamel.io/postgresql/
|
|
511
|
+
return fm.fetchReq<GetClusterNodeLabelListReq, GetClusterNodeLabelListResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["cluster"]}/nodelabels?${fm.renderURLSearchParams(req, ["cluster"])}`, {...initReq, method: "GET"})
|
|
512
|
+
}
|
|
513
|
+
static GetClusterPodLabelList(req: GetClusterPodLabelListReq, initReq?: fm.InitReq): Promise<GetClusterPodLabelListResp> {
|
|
514
|
+
return fm.fetchReq<GetClusterPodLabelListReq, GetClusterPodLabelListResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["cluster"]}/podlabels?${fm.renderURLSearchParams(req, ["cluster"])}`, {...initReq, method: "GET"})
|
|
232
515
|
}
|
|
233
516
|
static GetWorkspaceList(req: GetWorkspaceListReq, initReq?: fm.InitReq): Promise<GetWorkspaceListResp> {
|
|
234
|
-
return fm.fetchReq<GetWorkspaceListReq, GetWorkspaceListResp>(`/apis/mcamel.io/postgresql/
|
|
517
|
+
return fm.fetchReq<GetWorkspaceListReq, GetWorkspaceListResp>(`/apis/mcamel.io/postgresql/v1alpha2/workspaces?${fm.renderURLSearchParams(req, [])}`, {...initReq, method: "GET"})
|
|
235
518
|
}
|
|
236
519
|
static GetInsightAgentStatus(req: GetInsightAgentStatusReq, initReq?: fm.InitReq): Promise<GetInsightAgentStatusResp> {
|
|
237
|
-
return fm.fetchReq<GetInsightAgentStatusReq, GetInsightAgentStatusResp>(`/apis/mcamel.io/postgresql/
|
|
520
|
+
return fm.fetchReq<GetInsightAgentStatusReq, GetInsightAgentStatusResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["cluster"]}/insight/status?${fm.renderURLSearchParams(req, ["cluster"])}`, {...initReq, method: "GET"})
|
|
238
521
|
}
|
|
239
522
|
static GetEventList(req: GetEventListReq, initReq?: fm.InitReq): Promise<GetEventListResp> {
|
|
240
|
-
return fm.fetchReq<GetEventListReq, GetEventListResp>(`/apis/mcamel.io/postgresql/
|
|
523
|
+
return fm.fetchReq<GetEventListReq, GetEventListResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["cluster"]}/${req["namespace"]}/events?${fm.renderURLSearchParams(req, ["cluster", "namespace"])}`, {...initReq, method: "GET"})
|
|
241
524
|
}
|
|
242
525
|
static GetAllEventList(req: GetAllEventListReq, initReq?: fm.InitReq): Promise<GetAllEventListResp> {
|
|
243
|
-
return fm.fetchReq<GetAllEventListReq, GetAllEventListResp>(`/apis/mcamel.io/postgresql/
|
|
526
|
+
return fm.fetchReq<GetAllEventListReq, GetAllEventListResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["workspaceId"]}/${req["cluster"]}/${req["namespace"]}/${req["name"]}/all-events?${fm.renderURLSearchParams(req, ["workspaceId", "cluster", "namespace", "name"])}`, {...initReq, method: "GET"})
|
|
244
527
|
}
|
|
245
528
|
static GetAllEventKindsList(req: GetAllEventKindsListReq, initReq?: fm.InitReq): Promise<GetAllEventKindsListResp> {
|
|
246
|
-
return fm.fetchReq<GetAllEventKindsListReq, GetAllEventKindsListResp>(`/apis/mcamel.io/postgresql/
|
|
529
|
+
return fm.fetchReq<GetAllEventKindsListReq, GetAllEventKindsListResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["cluster"]}/all-events-kinds?${fm.renderURLSearchParams(req, ["cluster"])}`, {...initReq, method: "GET"})
|
|
247
530
|
}
|
|
248
531
|
static GetMetallbIPAddressPoolsList(req: GetMetallbIPAddressPoolsListReq, initReq?: fm.InitReq): Promise<GetMetallbIPAddressPoolsListResp> {
|
|
249
|
-
return fm.fetchReq<GetMetallbIPAddressPoolsListReq, GetMetallbIPAddressPoolsListResp>(`/apis/mcamel.io/postgresql/
|
|
532
|
+
return fm.fetchReq<GetMetallbIPAddressPoolsListReq, GetMetallbIPAddressPoolsListResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["cluster"]}/lbaddress/pools?${fm.renderURLSearchParams(req, ["cluster"])}`, {...initReq, method: "GET"})
|
|
533
|
+
}
|
|
534
|
+
static GetPermissionsList(req: GetPermissionsListReq, initReq?: fm.InitReq): Promise<GetPermissionsListResp> {
|
|
535
|
+
return fm.fetchReq<GetPermissionsListReq, GetPermissionsListResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["workspaceId"]}/permissions?${fm.renderURLSearchParams(req, ["workspaceId"])}`, {...initReq, method: "GET"})
|
|
536
|
+
}
|
|
537
|
+
static RestartInstance(req: RestartInstanceReq, initReq?: fm.InitReq): Promise<RestartInstanceResp> {
|
|
538
|
+
return fm.fetchReq<RestartInstanceReq, RestartInstanceResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["workspaceId"]}/restart`, {...initReq, method: "POST", body: JSON.stringify(req)})
|
|
539
|
+
}
|
|
540
|
+
static InstallFile(req: InstallFileReq, initReq?: fm.InitReq): Promise<InstallFileResp> {
|
|
541
|
+
return fm.fetchReq<InstallFileReq, InstallFileResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["cluster"]}/install-file`, {...initReq, method: "POST", body: JSON.stringify(req)})
|
|
542
|
+
}
|
|
543
|
+
static GetInstallVersion(req: GetInstallVersionReq, initReq?: fm.InitReq): Promise<GetInstallVersionResp> {
|
|
544
|
+
return fm.fetchReq<GetInstallVersionReq, GetInstallVersionResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["cluster"]}/install-version?${fm.renderURLSearchParams(req, ["cluster"])}`, {...initReq, method: "GET"})
|
|
545
|
+
}
|
|
546
|
+
static GetResourceQuota(req: GetResourceQuotaReq, initReq?: fm.InitReq): Promise<GetResourceQuotaResp> {
|
|
547
|
+
return fm.fetchReq<GetResourceQuotaReq, GetResourceQuotaResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["cluster"]}/${req["namespace"]}/resourcequota?${fm.renderURLSearchParams(req, ["cluster", "namespace"])}`, {...initReq, method: "GET"})
|
|
548
|
+
}
|
|
549
|
+
static GetClusterNodeTaintList(req: GetClusterNodeTaintListReq, initReq?: fm.InitReq): Promise<GetClusterNodeTaintListResp> {
|
|
550
|
+
return fm.fetchReq<GetClusterNodeTaintListReq, GetClusterNodeTaintListResp>(`/apis/mcamel.io/postgresql/v1alpha2/clusters/${req["cluster"]}/nodes/taints?${fm.renderURLSearchParams(req, ["cluster"])}`, {...initReq, method: "GET"})
|
|
551
|
+
}
|
|
552
|
+
static GetClusterNodeList(req: GetClusterNodeListReq, initReq?: fm.InitReq): Promise<GetClusterNodeListResp> {
|
|
553
|
+
return fm.fetchReq<GetClusterNodeListReq, GetClusterNodeListResp>(`/apis/mcamel.io/postgresql/v1alpha2/clusters/${req["cluster"]}/nodes?${fm.renderURLSearchParams(req, ["cluster"])}`, {...initReq, method: "GET"})
|
|
250
554
|
}
|
|
251
555
|
}
|
package/common.pb.ts
CHANGED
|
@@ -4,6 +4,27 @@
|
|
|
4
4
|
* This file is a generated Typescript file for GRPC Gateway, DO NOT MODIFY
|
|
5
5
|
*/
|
|
6
6
|
|
|
7
|
+
export enum TolerationOperator {
|
|
8
|
+
TOLERATION_OPERATOR_UNSPECIFIED = "TOLERATION_OPERATOR_UNSPECIFIED",
|
|
9
|
+
Exists = "Exists",
|
|
10
|
+
Equal = "Equal",
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
export enum TaintEffect {
|
|
14
|
+
TAINT_EFFECT_UNSPECIFIED = "TAINT_EFFECT_UNSPECIFIED",
|
|
15
|
+
NoSchedule = "NoSchedule",
|
|
16
|
+
NoExecute = "NoExecute",
|
|
17
|
+
PreferNoSchedule = "PreferNoSchedule",
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
export enum FilterPodStatus {
|
|
21
|
+
FILTER_POD_STATUS_UNSPECIFIED = "FILTER_POD_STATUS_UNSPECIFIED",
|
|
22
|
+
FILTER_POD_STATUS_RUNNING = "FILTER_POD_STATUS_RUNNING",
|
|
23
|
+
FILTER_POD_STATUS_ERROR = "FILTER_POD_STATUS_ERROR",
|
|
24
|
+
FILTER_POD_STATUS_COMPLETED = "FILTER_POD_STATUS_COMPLETED",
|
|
25
|
+
FILTER_POD_STATUS_WAITING = "FILTER_POD_STATUS_WAITING",
|
|
26
|
+
}
|
|
27
|
+
|
|
7
28
|
export enum ExternalTrafficPolicy {
|
|
8
29
|
Cluster = "Cluster",
|
|
9
30
|
Local = "Local",
|
|
@@ -20,6 +41,16 @@ export enum ServiceType {
|
|
|
20
41
|
LoadBalancer = "LoadBalancer",
|
|
21
42
|
}
|
|
22
43
|
|
|
44
|
+
export enum ClusterStatus {
|
|
45
|
+
UNSPECIFIED = "UNSPECIFIED",
|
|
46
|
+
Unknown = "Unknown",
|
|
47
|
+
Creating = "Creating",
|
|
48
|
+
Running = "Running",
|
|
49
|
+
Updating = "Updating",
|
|
50
|
+
Deleting = "Deleting",
|
|
51
|
+
Failed = "Failed",
|
|
52
|
+
}
|
|
53
|
+
|
|
23
54
|
export enum PageInfoReqSortDir {
|
|
24
55
|
ASC = "ASC",
|
|
25
56
|
DESC = "DESC",
|
|
@@ -106,9 +137,9 @@ export type LabelSelectorRequirement = {
|
|
|
106
137
|
|
|
107
138
|
export type Toleration = {
|
|
108
139
|
key?: string
|
|
109
|
-
operator?:
|
|
140
|
+
operator?: TolerationOperator
|
|
110
141
|
value?: string
|
|
111
|
-
effect?:
|
|
142
|
+
effect?: TaintEffect
|
|
112
143
|
tolerationSeconds?: string
|
|
113
144
|
}
|
|
114
145
|
|
|
@@ -151,6 +182,11 @@ export type PodCommon = {
|
|
|
151
182
|
containersName?: string[]
|
|
152
183
|
ownerReference?: OwnerReference[]
|
|
153
184
|
initContainersName?: string[]
|
|
185
|
+
initContainersStatuses?: ContainerStatus[]
|
|
186
|
+
containersStatuses?: ContainerStatus[]
|
|
187
|
+
podStatus?: string
|
|
188
|
+
annotations?: {[key: string]: string}
|
|
189
|
+
filterPodStatus?: FilterPodStatus
|
|
154
190
|
}
|
|
155
191
|
|
|
156
192
|
export type OwnerReference = {
|
|
@@ -164,4 +200,53 @@ export type CommonItemStatus = {
|
|
|
164
200
|
serviceAddresses?: string[]
|
|
165
201
|
webManagerAddress?: string
|
|
166
202
|
webLogAddress?: string
|
|
203
|
+
avgPvAllocatedInGb?: number
|
|
204
|
+
avgPvUsedInGb?: number
|
|
205
|
+
cpuUtilization?: number
|
|
206
|
+
memoryUtilization?: number
|
|
207
|
+
clusterStatus?: ClusterStatus
|
|
208
|
+
}
|
|
209
|
+
|
|
210
|
+
export type AccessWhitelistInternal = {
|
|
211
|
+
namespace?: string
|
|
212
|
+
podSelector?: {[key: string]: string}
|
|
213
|
+
}
|
|
214
|
+
|
|
215
|
+
export type AccessWhitelistExternal = {
|
|
216
|
+
cidr?: string
|
|
217
|
+
ip?: string
|
|
218
|
+
}
|
|
219
|
+
|
|
220
|
+
export type AccessWhitelist = {
|
|
221
|
+
internals?: AccessWhitelistInternal[]
|
|
222
|
+
externals?: AccessWhitelistExternal[]
|
|
223
|
+
}
|
|
224
|
+
|
|
225
|
+
export type ContainerStatus = {
|
|
226
|
+
name?: string
|
|
227
|
+
state?: ContainerState
|
|
228
|
+
}
|
|
229
|
+
|
|
230
|
+
export type ContainerState = {
|
|
231
|
+
waiting?: ContainerStateWaiting
|
|
232
|
+
running?: ContainerStateRunning
|
|
233
|
+
terminated?: ContainerStateTerminated
|
|
234
|
+
}
|
|
235
|
+
|
|
236
|
+
export type ContainerStateWaiting = {
|
|
237
|
+
reason?: string
|
|
238
|
+
message?: string
|
|
239
|
+
}
|
|
240
|
+
|
|
241
|
+
export type ContainerStateRunning = {
|
|
242
|
+
startedAt?: string
|
|
243
|
+
}
|
|
244
|
+
|
|
245
|
+
export type ContainerStateTerminated = {
|
|
246
|
+
exitCode?: number
|
|
247
|
+
signal?: number
|
|
248
|
+
reason?: string
|
|
249
|
+
message?: string
|
|
250
|
+
startedAt?: string
|
|
251
|
+
finishedAt?: string
|
|
167
252
|
}
|
package/metric.pb.ts
CHANGED
|
@@ -7,10 +7,22 @@
|
|
|
7
7
|
import * as CommonCommon from "./common.pb"
|
|
8
8
|
import * as fm from "./fetch.pb"
|
|
9
9
|
import * as InsightIoApiInsightV1alpha1Insight from "./insight.pb"
|
|
10
|
+
|
|
11
|
+
export enum GetAlertsListReqSortDir {
|
|
12
|
+
ASC = "ASC",
|
|
13
|
+
DESC = "DESC",
|
|
14
|
+
}
|
|
15
|
+
|
|
10
16
|
export type GetAlertsListReq = {
|
|
17
|
+
page?: number
|
|
18
|
+
pageSize?: number
|
|
19
|
+
sortDir?: GetAlertsListReqSortDir
|
|
20
|
+
sortBy?: string
|
|
21
|
+
searchKey?: string
|
|
11
22
|
cluster?: string
|
|
12
23
|
namespace?: string
|
|
13
24
|
name?: string
|
|
25
|
+
workspaceId?: number
|
|
14
26
|
}
|
|
15
27
|
|
|
16
28
|
export type GetAlertsListResp = {
|
|
@@ -20,6 +32,6 @@ export type GetAlertsListResp = {
|
|
|
20
32
|
|
|
21
33
|
export class Metric {
|
|
22
34
|
static GetAlertsList(req: GetAlertsListReq, initReq?: fm.InitReq): Promise<GetAlertsListResp> {
|
|
23
|
-
return fm.fetchReq<GetAlertsListReq, GetAlertsListResp>(`/apis/mcamel.io/postgresql/
|
|
35
|
+
return fm.fetchReq<GetAlertsListReq, GetAlertsListResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["workspaceId"]}/${req["cluster"]}/${req["namespace"]}/${req["name"]}/alerts?${fm.renderURLSearchParams(req, ["workspaceId", "cluster", "namespace", "name"])}`, {...initReq, method: "GET"})
|
|
24
36
|
}
|
|
25
37
|
}
|