@daocloud-proto/mcamel-postgresql 0.0.2-69 → 0.0.2-690-gfc7fe105
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 +353 -10
- package/common.pb.ts +87 -2
- package/metric.pb.ts +13 -1
- package/package.json +1 -1
- package/postgresql.pb.ts +371 -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,173 @@ 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 GetAllVisibleWorkspaceClusterListReq = {
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
export type GetAllVisibleWorkspaceClusterListResp = {
|
|
103
|
+
clusters?: ClusterItem[]
|
|
104
|
+
pagination?: CommonCommon.Pagination
|
|
105
|
+
}
|
|
106
|
+
|
|
107
|
+
export type GetAllVisibleWorkspaceClusterNamespaceListReq = {
|
|
108
|
+
cluster?: string
|
|
109
|
+
}
|
|
110
|
+
|
|
111
|
+
export type GetAllVisibleWorkspaceClusterNamespaceListResp = {
|
|
112
|
+
items?: WorkspaceClusterNamespace[]
|
|
113
|
+
pagination?: CommonCommon.Pagination
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
export type WorkspaceClusterNamespace = {
|
|
117
|
+
namespace?: string
|
|
118
|
+
cluster?: string
|
|
119
|
+
workspaceId?: string
|
|
120
|
+
workspaceName?: string
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
export type GetClusterNodeTaintListReq = {
|
|
124
|
+
cluster?: string
|
|
125
|
+
nodeName?: string
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
export type GetClusterNodeTaintListRespTaint = {
|
|
129
|
+
key?: string
|
|
130
|
+
value?: string
|
|
131
|
+
effect?: GetClusterNodeTaintListRespTaintEffect
|
|
132
|
+
nodeName?: string
|
|
133
|
+
}
|
|
134
|
+
|
|
135
|
+
export type GetClusterNodeTaintListResp = {
|
|
136
|
+
items?: GetClusterNodeTaintListRespTaint[]
|
|
137
|
+
}
|
|
138
|
+
|
|
139
|
+
export type GetClusterNodeListReq = {
|
|
140
|
+
cluster?: string
|
|
141
|
+
}
|
|
142
|
+
|
|
143
|
+
export type GetClusterNodeListRespNode = {
|
|
144
|
+
name?: string
|
|
145
|
+
}
|
|
146
|
+
|
|
147
|
+
export type GetClusterNodeListResp = {
|
|
148
|
+
items?: GetClusterNodeListRespNode[]
|
|
149
|
+
}
|
|
150
|
+
|
|
151
|
+
export type GetClusterReq = {
|
|
152
|
+
workspaceId?: number
|
|
153
|
+
name?: string
|
|
154
|
+
}
|
|
155
|
+
|
|
156
|
+
export type GetClusterResp = {
|
|
157
|
+
cluster?: ClusterItem
|
|
158
|
+
}
|
|
159
|
+
|
|
160
|
+
export type InstallFileReq = {
|
|
161
|
+
cluster?: string
|
|
162
|
+
path?: string
|
|
163
|
+
gvr?: InstallFileReqGVR
|
|
164
|
+
}
|
|
165
|
+
|
|
166
|
+
export type InstallFileResp = {
|
|
167
|
+
message?: string
|
|
168
|
+
}
|
|
169
|
+
|
|
170
|
+
export type GetInstallVersionReq = {
|
|
171
|
+
cluster?: string
|
|
172
|
+
}
|
|
173
|
+
|
|
174
|
+
export type GetInstallVersionRespSupportVersion = {
|
|
175
|
+
minVersion?: string
|
|
176
|
+
maxVersion?: string
|
|
177
|
+
}
|
|
178
|
+
|
|
179
|
+
export type GetInstallVersionRespStatus = {
|
|
180
|
+
inRange?: boolean
|
|
181
|
+
}
|
|
182
|
+
|
|
183
|
+
export type GetInstallVersionResp = {
|
|
184
|
+
clusterVersion?: string
|
|
185
|
+
supportVersion?: GetInstallVersionRespSupportVersion
|
|
186
|
+
status?: GetInstallVersionRespStatus
|
|
187
|
+
}
|
|
188
|
+
|
|
189
|
+
export type RestartInstanceReq = {
|
|
190
|
+
workspaceId?: number
|
|
191
|
+
cluster?: string
|
|
192
|
+
namespace?: string
|
|
193
|
+
name?: string
|
|
194
|
+
extra?: string
|
|
195
|
+
}
|
|
196
|
+
|
|
197
|
+
export type RestartInstanceResp = {
|
|
198
|
+
message?: string
|
|
199
|
+
}
|
|
200
|
+
|
|
201
|
+
export type GetPermissionsListReq = {
|
|
202
|
+
workspaceId?: number
|
|
203
|
+
}
|
|
204
|
+
|
|
205
|
+
export type GetPermissionsListRespPermissions = {
|
|
206
|
+
getInstance?: boolean
|
|
207
|
+
createInstance?: boolean
|
|
208
|
+
updateInstance?: boolean
|
|
209
|
+
deleteInstance?: boolean
|
|
210
|
+
getMetric?: boolean
|
|
211
|
+
getInstanceLog?: boolean
|
|
212
|
+
getConfig?: boolean
|
|
213
|
+
updateConfig?: boolean
|
|
214
|
+
getBackup?: boolean
|
|
215
|
+
createBackup?: boolean
|
|
216
|
+
updateBackup?: boolean
|
|
217
|
+
deleteBackup?: boolean
|
|
218
|
+
getBackupConf?: boolean
|
|
219
|
+
createBackupConf?: boolean
|
|
220
|
+
updateBackupConf?: boolean
|
|
221
|
+
deleteBackupConf?: boolean
|
|
222
|
+
getTemplate?: boolean
|
|
223
|
+
createTemplate?: boolean
|
|
224
|
+
updateTemplate?: boolean
|
|
225
|
+
deleteTemplate?: boolean
|
|
226
|
+
getUserPassword?: boolean
|
|
227
|
+
exportTemplate?: boolean
|
|
228
|
+
importTemplate?: boolean
|
|
229
|
+
}
|
|
230
|
+
|
|
231
|
+
export type GetPermissionsListResp = {
|
|
232
|
+
permissionsBool?: GetPermissionsListRespPermissions
|
|
233
|
+
permissions?: PermissionsType[]
|
|
234
|
+
}
|
|
235
|
+
|
|
36
236
|
export type GetAllEventKindsListResp = {
|
|
37
237
|
data?: string[]
|
|
38
238
|
}
|
|
@@ -52,6 +252,7 @@ export type GetAllEventListReq = {
|
|
|
52
252
|
name?: string
|
|
53
253
|
eventType?: EventType
|
|
54
254
|
kindName?: string
|
|
255
|
+
workspaceId?: number
|
|
55
256
|
}
|
|
56
257
|
|
|
57
258
|
export type GetAllEventListRespItemsSource = {
|
|
@@ -106,8 +307,32 @@ export type GetClusterNodeLabelListRespLabel = {
|
|
|
106
307
|
value?: string[]
|
|
107
308
|
}
|
|
108
309
|
|
|
310
|
+
export type GetClusterNodeLabelListRespNode2Label = {
|
|
311
|
+
nodeName?: string
|
|
312
|
+
label?: GetClusterNodeLabelListRespLabel[]
|
|
313
|
+
}
|
|
314
|
+
|
|
109
315
|
export type GetClusterNodeLabelListResp = {
|
|
110
316
|
items?: GetClusterNodeLabelListRespLabel[]
|
|
317
|
+
items1?: GetClusterNodeLabelListRespNode2Label[]
|
|
318
|
+
pagination?: CommonCommon.Pagination
|
|
319
|
+
}
|
|
320
|
+
|
|
321
|
+
export type GetClusterPodLabelListReq = {
|
|
322
|
+
page?: number
|
|
323
|
+
pageSize?: number
|
|
324
|
+
searchKey?: string
|
|
325
|
+
filterNamespace?: string
|
|
326
|
+
cluster?: string
|
|
327
|
+
}
|
|
328
|
+
|
|
329
|
+
export type GetClusterPodLabelListRespLabel = {
|
|
330
|
+
key?: string
|
|
331
|
+
value?: string[]
|
|
332
|
+
}
|
|
333
|
+
|
|
334
|
+
export type GetClusterPodLabelListResp = {
|
|
335
|
+
items?: GetClusterPodLabelListRespLabel[]
|
|
111
336
|
pagination?: CommonCommon.Pagination
|
|
112
337
|
}
|
|
113
338
|
|
|
@@ -183,6 +408,7 @@ export type GetWorkspaceListReq = {
|
|
|
183
408
|
export type GetWorkspaceListRespItem = {
|
|
184
409
|
workspaceId?: number
|
|
185
410
|
alias?: string
|
|
411
|
+
visible?: boolean
|
|
186
412
|
}
|
|
187
413
|
|
|
188
414
|
export type GetWorkspaceListResp = {
|
|
@@ -190,15 +416,61 @@ export type GetWorkspaceListResp = {
|
|
|
190
416
|
pagination?: CommonCommon.Pagination
|
|
191
417
|
}
|
|
192
418
|
|
|
419
|
+
export type GetClusterHostnetworkPortsReq = {
|
|
420
|
+
workspaceId?: number
|
|
421
|
+
cluster?: string
|
|
422
|
+
}
|
|
423
|
+
|
|
193
424
|
export type GetClusterListReq = {
|
|
194
425
|
workspaceId?: number
|
|
426
|
+
searchKey?: string
|
|
427
|
+
}
|
|
428
|
+
|
|
429
|
+
export type GetClusterHostnetworkPortsResp = {
|
|
430
|
+
items?: number[]
|
|
195
431
|
}
|
|
196
432
|
|
|
197
433
|
export type GetClusterListResp = {
|
|
198
434
|
items?: string[]
|
|
435
|
+
clusters?: ClusterItem[]
|
|
199
436
|
pagination?: CommonCommon.Pagination
|
|
200
437
|
}
|
|
201
438
|
|
|
439
|
+
export type ClusterItemMetadata = {
|
|
440
|
+
name?: string
|
|
441
|
+
}
|
|
442
|
+
|
|
443
|
+
export type ClusterItemStatus = {
|
|
444
|
+
networkMode?: ClusterItemNetworkMode[]
|
|
445
|
+
setting?: ClusterSetting
|
|
446
|
+
clusterStatus?: CommonCommon.ClusterStatus
|
|
447
|
+
workspace?: Workspace
|
|
448
|
+
}
|
|
449
|
+
|
|
450
|
+
export type ClusterItem = {
|
|
451
|
+
metadata?: ClusterItemMetadata
|
|
452
|
+
status?: ClusterItemStatus
|
|
453
|
+
}
|
|
454
|
+
|
|
455
|
+
export type Workspace = {
|
|
456
|
+
id?: number
|
|
457
|
+
name?: string
|
|
458
|
+
}
|
|
459
|
+
|
|
460
|
+
export type ClusterSettingPlugin = {
|
|
461
|
+
name?: ClusterSettingPluginPluginName
|
|
462
|
+
enabled?: boolean
|
|
463
|
+
intelligentDetection?: boolean
|
|
464
|
+
externalAddress?: string
|
|
465
|
+
setting?: string
|
|
466
|
+
healthy?: boolean
|
|
467
|
+
}
|
|
468
|
+
|
|
469
|
+
export type ClusterSetting = {
|
|
470
|
+
plugins?: ClusterSettingPlugin[]
|
|
471
|
+
network?: ClusterSettingPlugin[]
|
|
472
|
+
}
|
|
473
|
+
|
|
202
474
|
export type GetClusterNamespaceListReq = {
|
|
203
475
|
workspaceId?: number
|
|
204
476
|
cluster?: string
|
|
@@ -206,6 +478,7 @@ export type GetClusterNamespaceListReq = {
|
|
|
206
478
|
|
|
207
479
|
export type GetClusterNamespaceListResp = {
|
|
208
480
|
items?: string[]
|
|
481
|
+
disableItems?: string[]
|
|
209
482
|
pagination?: CommonCommon.Pagination
|
|
210
483
|
}
|
|
211
484
|
|
|
@@ -215,37 +488,107 @@ export type GetInsightAgentStatusReq = {
|
|
|
215
488
|
|
|
216
489
|
export type GetInsightAgentStatusResp = {
|
|
217
490
|
status?: GetInsightAgentStatusRespInsightAgentStatus
|
|
491
|
+
clusterStatus?: CommonCommon.ClusterStatus
|
|
492
|
+
}
|
|
493
|
+
|
|
494
|
+
export type GetResourceQuotaReq = {
|
|
495
|
+
cluster?: string
|
|
496
|
+
namespace?: string
|
|
497
|
+
}
|
|
498
|
+
|
|
499
|
+
export type GetResourceQuotaRespMetadata = {
|
|
500
|
+
uid?: string
|
|
501
|
+
name?: string
|
|
502
|
+
namespace?: string
|
|
503
|
+
annotations?: {[key: string]: string}
|
|
504
|
+
resourceVersion?: string
|
|
505
|
+
creationTimestamp?: string
|
|
506
|
+
}
|
|
507
|
+
|
|
508
|
+
export type GetResourceQuotaRespSpec = {
|
|
509
|
+
hard?: {[key: string]: string}
|
|
510
|
+
}
|
|
511
|
+
|
|
512
|
+
export type GetResourceQuotaRespStatus = {
|
|
513
|
+
hard?: {[key: string]: string}
|
|
514
|
+
used?: {[key: string]: string}
|
|
515
|
+
available?: {[key: string]: string}
|
|
516
|
+
}
|
|
517
|
+
|
|
518
|
+
export type GetResourceQuotaResp = {
|
|
519
|
+
metadata?: GetResourceQuotaRespMetadata
|
|
520
|
+
spec?: GetResourceQuotaRespSpec
|
|
521
|
+
status?: GetResourceQuotaRespStatus
|
|
218
522
|
}
|
|
219
523
|
|
|
220
524
|
export class Cluster {
|
|
221
525
|
static GetClusterList(req: GetClusterListReq, initReq?: fm.InitReq): Promise<GetClusterListResp> {
|
|
222
|
-
return fm.fetchReq<GetClusterListReq, GetClusterListResp>(`/apis/mcamel.io/postgresql/
|
|
526
|
+
return fm.fetchReq<GetClusterListReq, GetClusterListResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["workspaceId"]}/clusters?${fm.renderURLSearchParams(req, ["workspaceId"])}`, {...initReq, method: "GET"})
|
|
527
|
+
}
|
|
528
|
+
static GetAllVisibleWorkspaceClusterList(req: GetAllVisibleWorkspaceClusterListReq, initReq?: fm.InitReq): Promise<GetAllVisibleWorkspaceClusterListResp> {
|
|
529
|
+
return fm.fetchReq<GetAllVisibleWorkspaceClusterListReq, GetAllVisibleWorkspaceClusterListResp>(`/apis/mcamel.io/postgresql/v1alpha2/clusters?${fm.renderURLSearchParams(req, [])}`, {...initReq, method: "GET"})
|
|
530
|
+
}
|
|
531
|
+
static GetCluster(req: GetClusterReq, initReq?: fm.InitReq): Promise<GetClusterResp> {
|
|
532
|
+
return fm.fetchReq<GetClusterReq, GetClusterResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["workspaceId"]}/clusters/${req["name"]}?${fm.renderURLSearchParams(req, ["workspaceId", "name"])}`, {...initReq, method: "GET"})
|
|
533
|
+
}
|
|
534
|
+
static GetClusterHostnetworkPorts(req: GetClusterHostnetworkPortsReq, initReq?: fm.InitReq): Promise<GetClusterHostnetworkPortsResp> {
|
|
535
|
+
return fm.fetchReq<GetClusterHostnetworkPortsReq, GetClusterHostnetworkPortsResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["workspaceId"]}/hostnetwork-ports?${fm.renderURLSearchParams(req, ["workspaceId"])}`, {...initReq, method: "GET"})
|
|
223
536
|
}
|
|
224
537
|
static GetClusterNamespaceList(req: GetClusterNamespaceListReq, initReq?: fm.InitReq): Promise<GetClusterNamespaceListResp> {
|
|
225
|
-
return fm.fetchReq<GetClusterNamespaceListReq, GetClusterNamespaceListResp>(`/apis/mcamel.io/postgresql/
|
|
538
|
+
return fm.fetchReq<GetClusterNamespaceListReq, GetClusterNamespaceListResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["workspaceId"]}/${req["cluster"]}/namespaces?${fm.renderURLSearchParams(req, ["workspaceId", "cluster"])}`, {...initReq, method: "GET"})
|
|
539
|
+
}
|
|
540
|
+
static GetAllVisibleWorkspaceClusterNamespaceList(req: GetAllVisibleWorkspaceClusterNamespaceListReq, initReq?: fm.InitReq): Promise<GetAllVisibleWorkspaceClusterNamespaceListResp> {
|
|
541
|
+
return fm.fetchReq<GetAllVisibleWorkspaceClusterNamespaceListReq, GetAllVisibleWorkspaceClusterNamespaceListResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["cluster"]}/namespaces?${fm.renderURLSearchParams(req, ["cluster"])}`, {...initReq, method: "GET"})
|
|
226
542
|
}
|
|
227
543
|
static GetClusterNodePortList(req: GetClusterNodePortListReq, initReq?: fm.InitReq): Promise<GetClusterNodePortListResp> {
|
|
228
|
-
return fm.fetchReq<GetClusterNodePortListReq, GetClusterNodePortListResp>(`/apis/mcamel.io/postgresql/
|
|
544
|
+
return fm.fetchReq<GetClusterNodePortListReq, GetClusterNodePortListResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["cluster"]}/nodeports?${fm.renderURLSearchParams(req, ["cluster"])}`, {...initReq, method: "GET"})
|
|
229
545
|
}
|
|
230
546
|
static GetClusterNodeLabelList(req: GetClusterNodeLabelListReq, initReq?: fm.InitReq): Promise<GetClusterNodeLabelListResp> {
|
|
231
|
-
return fm.fetchReq<GetClusterNodeLabelListReq, GetClusterNodeLabelListResp>(`/apis/mcamel.io/postgresql/
|
|
547
|
+
return fm.fetchReq<GetClusterNodeLabelListReq, GetClusterNodeLabelListResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["cluster"]}/nodelabels?${fm.renderURLSearchParams(req, ["cluster"])}`, {...initReq, method: "GET"})
|
|
548
|
+
}
|
|
549
|
+
static GetClusterPodLabelList(req: GetClusterPodLabelListReq, initReq?: fm.InitReq): Promise<GetClusterPodLabelListResp> {
|
|
550
|
+
return fm.fetchReq<GetClusterPodLabelListReq, GetClusterPodLabelListResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["cluster"]}/podlabels?${fm.renderURLSearchParams(req, ["cluster"])}`, {...initReq, method: "GET"})
|
|
232
551
|
}
|
|
233
552
|
static GetWorkspaceList(req: GetWorkspaceListReq, initReq?: fm.InitReq): Promise<GetWorkspaceListResp> {
|
|
234
|
-
return fm.fetchReq<GetWorkspaceListReq, GetWorkspaceListResp>(`/apis/mcamel.io/postgresql/
|
|
553
|
+
return fm.fetchReq<GetWorkspaceListReq, GetWorkspaceListResp>(`/apis/mcamel.io/postgresql/v1alpha2/workspaces?${fm.renderURLSearchParams(req, [])}`, {...initReq, method: "GET"})
|
|
235
554
|
}
|
|
236
555
|
static GetInsightAgentStatus(req: GetInsightAgentStatusReq, initReq?: fm.InitReq): Promise<GetInsightAgentStatusResp> {
|
|
237
|
-
return fm.fetchReq<GetInsightAgentStatusReq, GetInsightAgentStatusResp>(`/apis/mcamel.io/postgresql/
|
|
556
|
+
return fm.fetchReq<GetInsightAgentStatusReq, GetInsightAgentStatusResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["cluster"]}/insight/status?${fm.renderURLSearchParams(req, ["cluster"])}`, {...initReq, method: "GET"})
|
|
238
557
|
}
|
|
239
558
|
static GetEventList(req: GetEventListReq, initReq?: fm.InitReq): Promise<GetEventListResp> {
|
|
240
|
-
return fm.fetchReq<GetEventListReq, GetEventListResp>(`/apis/mcamel.io/postgresql/
|
|
559
|
+
return fm.fetchReq<GetEventListReq, GetEventListResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["cluster"]}/${req["namespace"]}/events?${fm.renderURLSearchParams(req, ["cluster", "namespace"])}`, {...initReq, method: "GET"})
|
|
241
560
|
}
|
|
242
561
|
static GetAllEventList(req: GetAllEventListReq, initReq?: fm.InitReq): Promise<GetAllEventListResp> {
|
|
243
|
-
return fm.fetchReq<GetAllEventListReq, GetAllEventListResp>(`/apis/mcamel.io/postgresql/
|
|
562
|
+
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
563
|
}
|
|
245
564
|
static GetAllEventKindsList(req: GetAllEventKindsListReq, initReq?: fm.InitReq): Promise<GetAllEventKindsListResp> {
|
|
246
|
-
return fm.fetchReq<GetAllEventKindsListReq, GetAllEventKindsListResp>(`/apis/mcamel.io/postgresql/
|
|
565
|
+
return fm.fetchReq<GetAllEventKindsListReq, GetAllEventKindsListResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["cluster"]}/all-events-kinds?${fm.renderURLSearchParams(req, ["cluster"])}`, {...initReq, method: "GET"})
|
|
247
566
|
}
|
|
248
567
|
static GetMetallbIPAddressPoolsList(req: GetMetallbIPAddressPoolsListReq, initReq?: fm.InitReq): Promise<GetMetallbIPAddressPoolsListResp> {
|
|
249
|
-
return fm.fetchReq<GetMetallbIPAddressPoolsListReq, GetMetallbIPAddressPoolsListResp>(`/apis/mcamel.io/postgresql/
|
|
568
|
+
return fm.fetchReq<GetMetallbIPAddressPoolsListReq, GetMetallbIPAddressPoolsListResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["cluster"]}/lbaddress/pools?${fm.renderURLSearchParams(req, ["cluster"])}`, {...initReq, method: "GET"})
|
|
569
|
+
}
|
|
570
|
+
static GetPermissionsList(req: GetPermissionsListReq, initReq?: fm.InitReq): Promise<GetPermissionsListResp> {
|
|
571
|
+
return fm.fetchReq<GetPermissionsListReq, GetPermissionsListResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["workspaceId"]}/permissions?${fm.renderURLSearchParams(req, ["workspaceId"])}`, {...initReq, method: "GET"})
|
|
572
|
+
}
|
|
573
|
+
static GetAllVisibleWorkspacePermissionsList(req: GetPermissionsListReq, initReq?: fm.InitReq): Promise<GetPermissionsListResp> {
|
|
574
|
+
return fm.fetchReq<GetPermissionsListReq, GetPermissionsListResp>(`/apis/mcamel.io/postgresql/v1alpha2/permissions?${fm.renderURLSearchParams(req, [])}`, {...initReq, method: "GET"})
|
|
575
|
+
}
|
|
576
|
+
static RestartInstance(req: RestartInstanceReq, initReq?: fm.InitReq): Promise<RestartInstanceResp> {
|
|
577
|
+
return fm.fetchReq<RestartInstanceReq, RestartInstanceResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["workspaceId"]}/restart`, {...initReq, method: "POST", body: JSON.stringify(req)})
|
|
578
|
+
}
|
|
579
|
+
static InstallFile(req: InstallFileReq, initReq?: fm.InitReq): Promise<InstallFileResp> {
|
|
580
|
+
return fm.fetchReq<InstallFileReq, InstallFileResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["cluster"]}/install-file`, {...initReq, method: "POST", body: JSON.stringify(req)})
|
|
581
|
+
}
|
|
582
|
+
static GetInstallVersion(req: GetInstallVersionReq, initReq?: fm.InitReq): Promise<GetInstallVersionResp> {
|
|
583
|
+
return fm.fetchReq<GetInstallVersionReq, GetInstallVersionResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["cluster"]}/install-version?${fm.renderURLSearchParams(req, ["cluster"])}`, {...initReq, method: "GET"})
|
|
584
|
+
}
|
|
585
|
+
static GetResourceQuota(req: GetResourceQuotaReq, initReq?: fm.InitReq): Promise<GetResourceQuotaResp> {
|
|
586
|
+
return fm.fetchReq<GetResourceQuotaReq, GetResourceQuotaResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["cluster"]}/${req["namespace"]}/resourcequota?${fm.renderURLSearchParams(req, ["cluster", "namespace"])}`, {...initReq, method: "GET"})
|
|
587
|
+
}
|
|
588
|
+
static GetClusterNodeTaintList(req: GetClusterNodeTaintListReq, initReq?: fm.InitReq): Promise<GetClusterNodeTaintListResp> {
|
|
589
|
+
return fm.fetchReq<GetClusterNodeTaintListReq, GetClusterNodeTaintListResp>(`/apis/mcamel.io/postgresql/v1alpha2/clusters/${req["cluster"]}/nodes/taints?${fm.renderURLSearchParams(req, ["cluster"])}`, {...initReq, method: "GET"})
|
|
590
|
+
}
|
|
591
|
+
static GetClusterNodeList(req: GetClusterNodeListReq, initReq?: fm.InitReq): Promise<GetClusterNodeListResp> {
|
|
592
|
+
return fm.fetchReq<GetClusterNodeListReq, GetClusterNodeListResp>(`/apis/mcamel.io/postgresql/v1alpha2/clusters/${req["cluster"]}/nodes?${fm.renderURLSearchParams(req, ["cluster"])}`, {...initReq, method: "GET"})
|
|
250
593
|
}
|
|
251
594
|
}
|
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
|
}
|