@daocloud-proto/mcamel-mysql 0.5.1-4 → 0.5.1-7
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 +347 -8
- package/common.pb.ts +76 -1
- package/insight.pb.ts +8 -12
- package/metric.pb.ts +13 -1
- package/mysql.pb.ts +332 -34
- package/package.json +1 -1
- package/storage_config.pb.ts +9 -8
- package/template.pb.ts +195 -0
- package/version.pb.ts +8 -1
package/mysql.pb.ts
CHANGED
|
@@ -6,6 +6,7 @@
|
|
|
6
6
|
|
|
7
7
|
import * as CommonCommon from "./common.pb"
|
|
8
8
|
import * as fm from "./fetch.pb"
|
|
9
|
+
import * as TemplateTemplate from "./template.pb"
|
|
9
10
|
|
|
10
11
|
type Absent<T, K extends keyof T> = { [k in Exclude<keyof T, K>]?: undefined };
|
|
11
12
|
type OneOf<T> =
|
|
@@ -16,10 +17,58 @@ type OneOf<T> =
|
|
|
16
17
|
: never)
|
|
17
18
|
: never);
|
|
18
19
|
|
|
20
|
+
export enum RoleType {
|
|
21
|
+
Unknown = "Unknown",
|
|
22
|
+
Master = "Master",
|
|
23
|
+
Replica = "Replica",
|
|
24
|
+
PRIMARY = "PRIMARY",
|
|
25
|
+
SECONDARY = "SECONDARY",
|
|
26
|
+
Router = "Router",
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
export enum PodStatus {
|
|
30
|
+
PodStatus_UNSPECIFIED = "PodStatus_UNSPECIFIED",
|
|
31
|
+
PodStatus_Unknown = "PodStatus_Unknown",
|
|
32
|
+
PodStatus_Pending = "PodStatus_Pending",
|
|
33
|
+
PodStatus_Running = "PodStatus_Running",
|
|
34
|
+
PodStatus_Succeeded = "PodStatus_Succeeded",
|
|
35
|
+
PodStatus_Failed = "PodStatus_Failed",
|
|
36
|
+
PodStatus_Terminating = "PodStatus_Terminating",
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
export enum InstanceType {
|
|
40
|
+
UnKnown = "UnKnown",
|
|
41
|
+
SingleNode = "SingleNode",
|
|
42
|
+
MasterSlave = "MasterSlave",
|
|
43
|
+
Mgr = "Mgr",
|
|
44
|
+
}
|
|
45
|
+
|
|
19
46
|
export enum Status {
|
|
20
47
|
Failed = "Failed",
|
|
21
48
|
Running = "Running",
|
|
22
49
|
Creating = "Creating",
|
|
50
|
+
MgrOnline = "MgrOnline",
|
|
51
|
+
MgrRecovering = "MgrRecovering",
|
|
52
|
+
MgrError = "MgrError",
|
|
53
|
+
MgrOffline = "MgrOffline",
|
|
54
|
+
MgrNotManaged = "MgrNotManaged",
|
|
55
|
+
MgrUnmanaged = "MgrUnmanaged",
|
|
56
|
+
MgrUnreachable = "MgrUnreachable",
|
|
57
|
+
MgrUnknown = "MgrUnknown",
|
|
58
|
+
StatusUnknown = "StatusUnknown",
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
export enum GetSlowlogPodListRespItemNodeType {
|
|
62
|
+
Master = "Master",
|
|
63
|
+
Replica = "Replica",
|
|
64
|
+
PhpAdmin = "PhpAdmin",
|
|
65
|
+
PRIMARY = "PRIMARY",
|
|
66
|
+
SECONDARY = "SECONDARY",
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
export enum GetSlowlogListReqSortDir {
|
|
70
|
+
ASC = "ASC",
|
|
71
|
+
DESC = "DESC",
|
|
23
72
|
}
|
|
24
73
|
|
|
25
74
|
export enum GetMinioListReqSortDir {
|
|
@@ -107,12 +156,179 @@ export enum GetMysqlNodeListRespNodeType {
|
|
|
107
156
|
Master = "Master",
|
|
108
157
|
Replica = "Replica",
|
|
109
158
|
PhpAdmin = "PhpAdmin",
|
|
159
|
+
PRIMARY = "PRIMARY",
|
|
160
|
+
SECONDARY = "SECONDARY",
|
|
161
|
+
MgrRouter = "MgrRouter",
|
|
110
162
|
}
|
|
111
163
|
|
|
112
164
|
export enum GetMysqlConfRespItemsParamType {
|
|
113
165
|
conf = "conf",
|
|
114
166
|
}
|
|
115
167
|
|
|
168
|
+
export enum MysqlClusterItemStatusRestoreInitialStatus {
|
|
169
|
+
Unknown = "Unknown",
|
|
170
|
+
Running = "Running",
|
|
171
|
+
Failed = "Failed",
|
|
172
|
+
Succeeded = "Succeeded",
|
|
173
|
+
}
|
|
174
|
+
|
|
175
|
+
export type GetPodsAndRolesReq = {
|
|
176
|
+
cluster?: string
|
|
177
|
+
namespace?: string
|
|
178
|
+
name?: string
|
|
179
|
+
workspaceId?: number
|
|
180
|
+
instanceType?: InstanceType
|
|
181
|
+
}
|
|
182
|
+
|
|
183
|
+
export type PodsAndRoles = {
|
|
184
|
+
podName?: string
|
|
185
|
+
podStatus?: PodStatus
|
|
186
|
+
}
|
|
187
|
+
|
|
188
|
+
export type GetPodsAndRolesResp = {
|
|
189
|
+
isHealthy?: boolean
|
|
190
|
+
source?: PodsAndRoles[]
|
|
191
|
+
replica?: PodsAndRoles[]
|
|
192
|
+
}
|
|
193
|
+
|
|
194
|
+
export type GetSlowlogPodListReq = {
|
|
195
|
+
cluster?: string
|
|
196
|
+
namespace?: string
|
|
197
|
+
name?: string
|
|
198
|
+
workspaceId?: number
|
|
199
|
+
instanceType?: InstanceType
|
|
200
|
+
}
|
|
201
|
+
|
|
202
|
+
export type GetSlowlogPodListRespItem = {
|
|
203
|
+
podName?: string
|
|
204
|
+
slowLogCount?: number
|
|
205
|
+
nodeType?: GetSlowlogPodListRespItemNodeType
|
|
206
|
+
}
|
|
207
|
+
|
|
208
|
+
export type GetSlowlogPodListResp = {
|
|
209
|
+
items?: GetSlowlogPodListRespItem[]
|
|
210
|
+
}
|
|
211
|
+
|
|
212
|
+
export type UpdateSlowlogStatusReq = {
|
|
213
|
+
cluster?: string
|
|
214
|
+
namespace?: string
|
|
215
|
+
name?: string
|
|
216
|
+
instanceType?: InstanceType
|
|
217
|
+
enable?: boolean
|
|
218
|
+
workspaceId?: number
|
|
219
|
+
}
|
|
220
|
+
|
|
221
|
+
export type UpdateSlowlogStatusResp = {
|
|
222
|
+
message?: string
|
|
223
|
+
}
|
|
224
|
+
|
|
225
|
+
export type GetSlowlogConfReq = {
|
|
226
|
+
cluster?: string
|
|
227
|
+
namespace?: string
|
|
228
|
+
name?: string
|
|
229
|
+
instanceType?: InstanceType
|
|
230
|
+
workspaceId?: number
|
|
231
|
+
}
|
|
232
|
+
|
|
233
|
+
export type GetSlowlogConfResp = {
|
|
234
|
+
longQueryTime?: string
|
|
235
|
+
slowQueryLog?: boolean
|
|
236
|
+
}
|
|
237
|
+
|
|
238
|
+
export type DeleteSlowlogReq = {
|
|
239
|
+
cluster?: string
|
|
240
|
+
namespace?: string
|
|
241
|
+
name?: string
|
|
242
|
+
podName?: string[]
|
|
243
|
+
instanceType?: InstanceType
|
|
244
|
+
workspaceId?: number
|
|
245
|
+
}
|
|
246
|
+
|
|
247
|
+
export type DeleteSlowlogResp = {
|
|
248
|
+
message?: string
|
|
249
|
+
}
|
|
250
|
+
|
|
251
|
+
export type GetSlowlogListReq = {
|
|
252
|
+
page?: number
|
|
253
|
+
pageSize?: number
|
|
254
|
+
sortDir?: GetSlowlogListReqSortDir
|
|
255
|
+
sortBy?: string
|
|
256
|
+
searchKey?: string
|
|
257
|
+
cluster?: string
|
|
258
|
+
namespace?: string
|
|
259
|
+
name?: string
|
|
260
|
+
podName?: string
|
|
261
|
+
instanceType?: InstanceType
|
|
262
|
+
fromDate?: string
|
|
263
|
+
toDate?: string
|
|
264
|
+
workspaceId?: number
|
|
265
|
+
}
|
|
266
|
+
|
|
267
|
+
export type GetSlowlogListRespItem = {
|
|
268
|
+
startTime?: string
|
|
269
|
+
db?: string
|
|
270
|
+
sqlText?: string
|
|
271
|
+
queryTime?: string
|
|
272
|
+
lockTime?: string
|
|
273
|
+
rowsExamined?: string
|
|
274
|
+
rowsSent?: string
|
|
275
|
+
userHost?: string
|
|
276
|
+
}
|
|
277
|
+
|
|
278
|
+
export type GetSlowlogListResp = {
|
|
279
|
+
items?: GetSlowlogListRespItem[]
|
|
280
|
+
pagination?: CommonCommon.Pagination
|
|
281
|
+
}
|
|
282
|
+
|
|
283
|
+
export type GetTopologyRequest = {
|
|
284
|
+
cluster?: string
|
|
285
|
+
namespace?: string
|
|
286
|
+
name?: string
|
|
287
|
+
instanceType?: InstanceType
|
|
288
|
+
workspaceId?: number
|
|
289
|
+
}
|
|
290
|
+
|
|
291
|
+
export type GetTopologyResp = {
|
|
292
|
+
cluster?: string
|
|
293
|
+
namespace?: string
|
|
294
|
+
name?: string
|
|
295
|
+
instanceType?: InstanceType
|
|
296
|
+
version?: string
|
|
297
|
+
storageClassName?: string
|
|
298
|
+
storageCapacity?: string
|
|
299
|
+
nodes?: Node[]
|
|
300
|
+
edges?: Edge[]
|
|
301
|
+
}
|
|
302
|
+
|
|
303
|
+
export type Edge = {
|
|
304
|
+
source?: string
|
|
305
|
+
target?: string
|
|
306
|
+
properties?: Property
|
|
307
|
+
}
|
|
308
|
+
|
|
309
|
+
export type Property = {
|
|
310
|
+
}
|
|
311
|
+
|
|
312
|
+
export type Node = {
|
|
313
|
+
serverUuid?: string
|
|
314
|
+
upstreamServerUuid?: string
|
|
315
|
+
role?: RoleType
|
|
316
|
+
podName?: string
|
|
317
|
+
ip?: string
|
|
318
|
+
podStatus?: PodStatus
|
|
319
|
+
status?: Status
|
|
320
|
+
cpuLimit?: string
|
|
321
|
+
cpuRequest?: string
|
|
322
|
+
memoryLimit?: string
|
|
323
|
+
memoryRequest?: string
|
|
324
|
+
totalContainer?: number
|
|
325
|
+
totalContainerReady?: number
|
|
326
|
+
gtidPurged?: string
|
|
327
|
+
gtidExecuted?: string
|
|
328
|
+
lagBehindUpstream?: string
|
|
329
|
+
error?: string
|
|
330
|
+
}
|
|
331
|
+
|
|
116
332
|
export type GetMinioListReq = {
|
|
117
333
|
page?: number
|
|
118
334
|
pageSize?: number
|
|
@@ -148,6 +364,8 @@ export type GetMysqlUsersReq = {
|
|
|
148
364
|
cluster?: string
|
|
149
365
|
namespace?: string
|
|
150
366
|
name?: string
|
|
367
|
+
instanceType?: InstanceType
|
|
368
|
+
workspaceId?: number
|
|
151
369
|
}
|
|
152
370
|
|
|
153
371
|
export type GetMysqlUsersRespUserItem = {
|
|
@@ -172,6 +390,7 @@ export type UpdateMysqlBackupConfigReq = {
|
|
|
172
390
|
storageConfigName?: string
|
|
173
391
|
storageConfigNamespace?: string
|
|
174
392
|
storageConfigCluster?: string
|
|
393
|
+
instanceType?: InstanceType
|
|
175
394
|
}
|
|
176
395
|
|
|
177
396
|
export type UpdateMysqlBackupConfigResp = {
|
|
@@ -185,6 +404,9 @@ export type CreateMysqlRecoverReq = {
|
|
|
185
404
|
name?: string
|
|
186
405
|
backupName?: string
|
|
187
406
|
targetMysqlClusterName?: string
|
|
407
|
+
targetMysqlClusterNamespace?: string
|
|
408
|
+
targetMysqlClusterCluster?: string
|
|
409
|
+
instanceType?: InstanceType
|
|
188
410
|
}
|
|
189
411
|
|
|
190
412
|
export type CreateMysqlRecoverResp = {
|
|
@@ -200,6 +422,8 @@ export type GetMysqlBackupListReq = {
|
|
|
200
422
|
cluster?: string
|
|
201
423
|
namespace?: string
|
|
202
424
|
name?: string
|
|
425
|
+
instanceType?: InstanceType
|
|
426
|
+
workspaceId?: number
|
|
203
427
|
}
|
|
204
428
|
|
|
205
429
|
export type GetMysqlBackupJobListReq = {
|
|
@@ -212,6 +436,7 @@ export type GetMysqlBackupJobListReq = {
|
|
|
212
436
|
namespace?: string
|
|
213
437
|
name?: string
|
|
214
438
|
backupName?: string
|
|
439
|
+
workspaceId?: number
|
|
215
440
|
}
|
|
216
441
|
|
|
217
442
|
export type GetMysqlBackupSecretReq = {
|
|
@@ -310,6 +535,7 @@ export type CreateMysqlBackupReq = {
|
|
|
310
535
|
backupName?: string
|
|
311
536
|
backupBucket?: string
|
|
312
537
|
backupBucketSubPath?: string
|
|
538
|
+
instanceType?: InstanceType
|
|
313
539
|
}
|
|
314
540
|
|
|
315
541
|
export type CreateMysqlBackupResp = {
|
|
@@ -324,10 +550,13 @@ export type DeleteMysqlBackupReq = {
|
|
|
324
550
|
cluster?: string
|
|
325
551
|
namespace?: string
|
|
326
552
|
name?: string
|
|
553
|
+
instanceType?: InstanceType
|
|
554
|
+
workspaceId?: number
|
|
327
555
|
}
|
|
328
556
|
|
|
329
557
|
export type DeleteMysqlBackupResp = {
|
|
330
558
|
message?: string
|
|
559
|
+
instanceType?: InstanceType
|
|
331
560
|
}
|
|
332
561
|
|
|
333
562
|
export type GetMysqlListReq = {
|
|
@@ -337,6 +566,8 @@ export type GetMysqlListReq = {
|
|
|
337
566
|
sortBy?: string
|
|
338
567
|
searchKey?: string
|
|
339
568
|
workspaceId?: number
|
|
569
|
+
filterCluster?: string
|
|
570
|
+
filterNamespace?: string
|
|
340
571
|
}
|
|
341
572
|
|
|
342
573
|
export type GetMysqlConfReq = {
|
|
@@ -348,10 +579,13 @@ export type GetMysqlConfReq = {
|
|
|
348
579
|
cluster?: string
|
|
349
580
|
namespace?: string
|
|
350
581
|
name?: string
|
|
582
|
+
instanceType?: InstanceType
|
|
583
|
+
workspaceId?: number
|
|
351
584
|
}
|
|
352
585
|
|
|
353
586
|
export type GetMysqlParamReq = {
|
|
354
587
|
cluster?: string
|
|
588
|
+
workspaceId?: number
|
|
355
589
|
}
|
|
356
590
|
|
|
357
591
|
export type CreateMysqlReqPorts = {
|
|
@@ -381,6 +615,7 @@ export type CreateMysqlReq = {
|
|
|
381
615
|
memoryRequest?: string
|
|
382
616
|
memoryLimit?: string
|
|
383
617
|
conf?: string
|
|
618
|
+
confTemplateName?: string
|
|
384
619
|
backupSchedule?: string
|
|
385
620
|
backupSecretName?: string
|
|
386
621
|
backupBucket?: string
|
|
@@ -402,17 +637,36 @@ export type CreateMysqlReq = {
|
|
|
402
637
|
storageConfigNamespace?: string
|
|
403
638
|
storageConfigCluster?: string
|
|
404
639
|
affinity?: CommonCommon.Affinity
|
|
640
|
+
serviceMonitorInterval?: string
|
|
641
|
+
accessWhitelist?: CommonCommon.AccessWhitelist
|
|
405
642
|
externalTrafficPolicy?: CommonCommon.ExternalTrafficPolicy
|
|
406
643
|
lbTyp?: CommonCommon.LBTyp
|
|
407
644
|
lbPoolName?: string
|
|
408
645
|
lbAddress?: string
|
|
646
|
+
phpAdminExternalTrafficPolicy?: CommonCommon.ExternalTrafficPolicy
|
|
647
|
+
phpAdminLbTyp?: CommonCommon.LBTyp
|
|
648
|
+
phpAdminLbPoolName?: string
|
|
649
|
+
phpAdminLbAddress?: string
|
|
650
|
+
instanceType?: InstanceType
|
|
651
|
+
mgrRouterConfig?: MgrRouterConfig
|
|
652
|
+
}
|
|
653
|
+
|
|
654
|
+
export type MgrRouterConfig = {
|
|
655
|
+
replicas?: number
|
|
656
|
+
cpuRequest?: string
|
|
657
|
+
cpuLimit?: string
|
|
658
|
+
memoryRequest?: string
|
|
659
|
+
memoryLimit?: string
|
|
409
660
|
}
|
|
410
661
|
|
|
411
662
|
export type UpdateMysqlConfReq = {
|
|
412
663
|
cluster?: string
|
|
413
664
|
namespace?: string
|
|
414
665
|
name?: string
|
|
415
|
-
|
|
666
|
+
confItems?: TemplateTemplate.TemplateConfigItem[]
|
|
667
|
+
reloadFromConfTemplateName?: string
|
|
668
|
+
instanceType?: InstanceType
|
|
669
|
+
workspaceId?: number
|
|
416
670
|
}
|
|
417
671
|
|
|
418
672
|
export type UpdateMysqlParamsResp = {
|
|
@@ -427,13 +681,6 @@ export type GetMysqlParamRespSelectDataStringValue = {
|
|
|
427
681
|
value?: string
|
|
428
682
|
}
|
|
429
683
|
|
|
430
|
-
export type GetMysqlParamRespSelectDataResourceValue = {
|
|
431
|
-
cpuRequest?: string
|
|
432
|
-
cpuLimit?: string
|
|
433
|
-
memoryRequest?: string
|
|
434
|
-
memoryLimit?: string
|
|
435
|
-
}
|
|
436
|
-
|
|
437
684
|
export type GetMysqlParamRespSelectDataIntValue = {
|
|
438
685
|
value?: number
|
|
439
686
|
}
|
|
@@ -448,7 +695,7 @@ type BaseGetMysqlParamRespSelectData = {
|
|
|
448
695
|
}
|
|
449
696
|
|
|
450
697
|
export type GetMysqlParamRespSelectData = BaseGetMysqlParamRespSelectData
|
|
451
|
-
& OneOf<{ sValue: GetMysqlParamRespSelectDataStringValue;
|
|
698
|
+
& OneOf<{ sValue: GetMysqlParamRespSelectDataStringValue; iValue: GetMysqlParamRespSelectDataIntValue; scValue: GetMysqlParamRespSelectDataStorageClassValue }>
|
|
452
699
|
|
|
453
700
|
export type GetMysqlParamRespSelect = {
|
|
454
701
|
selectType?: GetMysqlParamRespSelectSelectType
|
|
@@ -458,10 +705,10 @@ export type GetMysqlParamRespSelect = {
|
|
|
458
705
|
export type GetMysqlParamResp = {
|
|
459
706
|
version?: GetMysqlParamRespSelect
|
|
460
707
|
replicas?: GetMysqlParamRespSelect
|
|
461
|
-
resource?: GetMysqlParamRespSelect
|
|
462
708
|
storage?: GetMysqlParamRespSelect
|
|
463
709
|
cnf?: GetMysqlParamRespSelect
|
|
464
710
|
eightXcnf?: GetMysqlParamRespSelect
|
|
711
|
+
mgrVersion?: GetMysqlParamRespSelect
|
|
465
712
|
}
|
|
466
713
|
|
|
467
714
|
export type GetMysqlBackupProviderListResp = {
|
|
@@ -473,12 +720,14 @@ export type CreateMysqlResp = {
|
|
|
473
720
|
}
|
|
474
721
|
|
|
475
722
|
export type GetMysqlOperatorVersionListReq = {
|
|
723
|
+
cluster?: string
|
|
476
724
|
}
|
|
477
725
|
|
|
478
726
|
export type GetMysqlOperatorVersionListRespGetMysqlOperatorVersionListData = {
|
|
479
727
|
cluster?: string
|
|
480
728
|
namespace?: string
|
|
481
729
|
version?: string
|
|
730
|
+
instanceType?: InstanceType[]
|
|
482
731
|
}
|
|
483
732
|
|
|
484
733
|
export type GetMysqlOperatorVersionListResp = {
|
|
@@ -490,10 +739,13 @@ export type DeleteMysqlReq = {
|
|
|
490
739
|
cluster?: string
|
|
491
740
|
namespace?: string
|
|
492
741
|
name?: string
|
|
742
|
+
instanceType?: InstanceType
|
|
743
|
+
workspaceId?: number
|
|
493
744
|
}
|
|
494
745
|
|
|
495
746
|
export type DeleteMysqlsReq = {
|
|
496
747
|
data?: DeleteMysqlReq[]
|
|
748
|
+
workspaceId?: number
|
|
497
749
|
}
|
|
498
750
|
|
|
499
751
|
export type DeleteMysqlResp = {
|
|
@@ -513,6 +765,8 @@ export type GetMysqlNodeListReq = {
|
|
|
513
765
|
sortDir?: GetMysqlNodeListReqSortDir
|
|
514
766
|
sortBy?: string
|
|
515
767
|
searchKey?: string
|
|
768
|
+
instanceType?: InstanceType
|
|
769
|
+
workspaceId?: number
|
|
516
770
|
}
|
|
517
771
|
|
|
518
772
|
export type GetMysqlNodeListRespData = {
|
|
@@ -539,6 +793,10 @@ export type GetMysqlGrafanaAddrReq = {
|
|
|
539
793
|
cluster?: string
|
|
540
794
|
namespace?: string
|
|
541
795
|
name?: string
|
|
796
|
+
from?: string
|
|
797
|
+
to?: string
|
|
798
|
+
instanceType?: InstanceType
|
|
799
|
+
workspaceId?: number
|
|
542
800
|
}
|
|
543
801
|
|
|
544
802
|
export type GetMysqlGrafanaAddrResp = {
|
|
@@ -549,6 +807,8 @@ export type GetMysqlReq = {
|
|
|
549
807
|
cluster?: string
|
|
550
808
|
namespace?: string
|
|
551
809
|
name?: string
|
|
810
|
+
instanceType?: InstanceType
|
|
811
|
+
workspaceId?: number
|
|
552
812
|
}
|
|
553
813
|
|
|
554
814
|
export type GetMysqlResp = {
|
|
@@ -584,6 +844,7 @@ export type MysqlClusterItemStatus = {
|
|
|
584
844
|
secondsBehindMaster?: number
|
|
585
845
|
cpuUtilization?: number
|
|
586
846
|
memoryUtilization?: number
|
|
847
|
+
restoreInitialStatus?: MysqlClusterItemStatusRestoreInitialStatus
|
|
587
848
|
}
|
|
588
849
|
|
|
589
850
|
export type MysqlClusterItemMetadata = {
|
|
@@ -601,74 +862,111 @@ export type MysqlClusterItem = {
|
|
|
601
862
|
status?: MysqlClusterItemStatus
|
|
602
863
|
}
|
|
603
864
|
|
|
604
|
-
export
|
|
865
|
+
export type SwitchMasterRequest = {
|
|
866
|
+
cluster?: string
|
|
867
|
+
namespace?: string
|
|
868
|
+
name?: string
|
|
869
|
+
workspaceId?: number
|
|
870
|
+
newMasterPodName?: string
|
|
871
|
+
instanceType?: InstanceType
|
|
872
|
+
}
|
|
873
|
+
|
|
874
|
+
export type SwitchMasterResp = {
|
|
875
|
+
data?: string
|
|
876
|
+
}
|
|
877
|
+
|
|
878
|
+
export class MysqlV3 {
|
|
605
879
|
static GetMysqlList(req: GetMysqlListReq, initReq?: fm.InitReq): Promise<GetMysqlListResp> {
|
|
606
|
-
return fm.fetchReq<GetMysqlListReq, GetMysqlListResp>(`/apis/mcamel.io/mysql/
|
|
880
|
+
return fm.fetchReq<GetMysqlListReq, GetMysqlListResp>(`/apis/mcamel.io/mysql/v1alpha3/${req["workspaceId"]}/mysqls?${fm.renderURLSearchParams(req, ["workspaceId"])}`, {...initReq, method: "GET"})
|
|
607
881
|
}
|
|
608
882
|
static GetMysqlOperatorVersionList(req: GetMysqlOperatorVersionListReq, initReq?: fm.InitReq): Promise<GetMysqlOperatorVersionListResp> {
|
|
609
|
-
return fm.fetchReq<GetMysqlOperatorVersionListReq, GetMysqlOperatorVersionListResp>(`/apis/mcamel.io/mysql/
|
|
883
|
+
return fm.fetchReq<GetMysqlOperatorVersionListReq, GetMysqlOperatorVersionListResp>(`/apis/mcamel.io/mysql/v1alpha3/${req["cluster"]}/mysql-operator/versions?${fm.renderURLSearchParams(req, ["cluster"])}`, {...initReq, method: "GET"})
|
|
610
884
|
}
|
|
611
885
|
static GetMysql(req: GetMysqlReq, initReq?: fm.InitReq): Promise<GetMysqlResp> {
|
|
612
|
-
return fm.fetchReq<GetMysqlReq, GetMysqlResp>(`/apis/mcamel.io/mysql/
|
|
886
|
+
return fm.fetchReq<GetMysqlReq, GetMysqlResp>(`/apis/mcamel.io/mysql/v1alpha3/${req["workspaceId"]}/mysql/${req["cluster"]}/${req["namespace"]}/${req["name"]}?${fm.renderURLSearchParams(req, ["workspaceId", "cluster", "namespace", "name"])}`, {...initReq, method: "GET"})
|
|
613
887
|
}
|
|
614
888
|
static GetMysqlParam(req: GetMysqlParamReq, initReq?: fm.InitReq): Promise<GetMysqlParamResp> {
|
|
615
|
-
return fm.fetchReq<GetMysqlParamReq, GetMysqlParamResp>(`/apis/mcamel.io/mysql/
|
|
889
|
+
return fm.fetchReq<GetMysqlParamReq, GetMysqlParamResp>(`/apis/mcamel.io/mysql/v1alpha3/${req["workspaceId"]}/mysql-params/${req["cluster"]}?${fm.renderURLSearchParams(req, ["workspaceId", "cluster"])}`, {...initReq, method: "GET"})
|
|
616
890
|
}
|
|
617
891
|
static GetMysqlNodeList(req: GetMysqlNodeListReq, initReq?: fm.InitReq): Promise<GetMysqlNodeListResp> {
|
|
618
|
-
return fm.fetchReq<GetMysqlNodeListReq, GetMysqlNodeListResp>(`/apis/mcamel.io/mysql/
|
|
892
|
+
return fm.fetchReq<GetMysqlNodeListReq, GetMysqlNodeListResp>(`/apis/mcamel.io/mysql/v1alpha3/${req["workspaceId"]}/mysql/${req["cluster"]}/${req["namespace"]}/${req["name"]}/nodes?${fm.renderURLSearchParams(req, ["workspaceId", "cluster", "namespace", "name"])}`, {...initReq, method: "GET"})
|
|
619
893
|
}
|
|
620
894
|
static GetMysqlGrafanaAddr(req: GetMysqlGrafanaAddrReq, initReq?: fm.InitReq): Promise<GetMysqlGrafanaAddrResp> {
|
|
621
|
-
return fm.fetchReq<GetMysqlGrafanaAddrReq, GetMysqlGrafanaAddrResp>(`/apis/mcamel.io/mysql/
|
|
895
|
+
return fm.fetchReq<GetMysqlGrafanaAddrReq, GetMysqlGrafanaAddrResp>(`/apis/mcamel.io/mysql/v1alpha3/${req["workspaceId"]}/mysql/${req["cluster"]}/${req["namespace"]}/${req["name"]}/grafana?${fm.renderURLSearchParams(req, ["workspaceId", "cluster", "namespace", "name"])}`, {...initReq, method: "GET"})
|
|
622
896
|
}
|
|
623
897
|
static CreateMysql(req: CreateMysqlReq, initReq?: fm.InitReq): Promise<CreateMysqlResp> {
|
|
624
|
-
return fm.fetchReq<CreateMysqlReq, CreateMysqlResp>(`/apis/mcamel.io/mysql/
|
|
898
|
+
return fm.fetchReq<CreateMysqlReq, CreateMysqlResp>(`/apis/mcamel.io/mysql/v1alpha3/${req["workspaceId"]}/mysql`, {...initReq, method: "POST", body: JSON.stringify(req)})
|
|
625
899
|
}
|
|
626
900
|
static GetMysqlConfs(req: GetMysqlConfReq, initReq?: fm.InitReq): Promise<GetMysqlConfResp> {
|
|
627
|
-
return fm.fetchReq<GetMysqlConfReq, GetMysqlConfResp>(`/apis/mcamel.io/mysql/
|
|
901
|
+
return fm.fetchReq<GetMysqlConfReq, GetMysqlConfResp>(`/apis/mcamel.io/mysql/v1alpha3/${req["workspaceId"]}/mysql/${req["cluster"]}/${req["namespace"]}/${req["name"]}/confs?${fm.renderURLSearchParams(req, ["workspaceId", "cluster", "namespace", "name"])}`, {...initReq, method: "GET"})
|
|
628
902
|
}
|
|
629
903
|
static UpdateMysqlConf(req: UpdateMysqlConfReq, initReq?: fm.InitReq): Promise<UpdateMysqlConfResp> {
|
|
630
|
-
return fm.fetchReq<UpdateMysqlConfReq, UpdateMysqlConfResp>(`/apis/mcamel.io/mysql/
|
|
904
|
+
return fm.fetchReq<UpdateMysqlConfReq, UpdateMysqlConfResp>(`/apis/mcamel.io/mysql/v1alpha3/${req["workspaceId"]}/mysql/${req["cluster"]}/${req["namespace"]}/${req["name"]}/conf`, {...initReq, method: "PUT", body: JSON.stringify(req)})
|
|
631
905
|
}
|
|
632
906
|
static UpdateMysqlParams(req: CreateMysqlReq, initReq?: fm.InitReq): Promise<UpdateMysqlParamsResp> {
|
|
633
|
-
return fm.fetchReq<CreateMysqlReq, UpdateMysqlParamsResp>(`/apis/mcamel.io/mysql/
|
|
907
|
+
return fm.fetchReq<CreateMysqlReq, UpdateMysqlParamsResp>(`/apis/mcamel.io/mysql/v1alpha3/${req["workspaceId"]}/mysql/${req["cluster"]}/${req["namespace"]}/${req["name"]}/params`, {...initReq, method: "PUT", body: JSON.stringify(req)})
|
|
634
908
|
}
|
|
635
909
|
static DeleteMysql(req: DeleteMysqlReq, initReq?: fm.InitReq): Promise<DeleteMysqlResp> {
|
|
636
|
-
return fm.fetchReq<DeleteMysqlReq, DeleteMysqlResp>(`/apis/mcamel.io/mysql/
|
|
910
|
+
return fm.fetchReq<DeleteMysqlReq, DeleteMysqlResp>(`/apis/mcamel.io/mysql/v1alpha3/${req["workspaceId"]}/mysql/${req["cluster"]}/${req["namespace"]}/${req["instanceType"]}/${req["name"]}`, {...initReq, method: "DELETE"})
|
|
637
911
|
}
|
|
638
912
|
static DeleteMysqls(req: DeleteMysqlsReq, initReq?: fm.InitReq): Promise<DeleteMysqlsResp> {
|
|
639
|
-
return fm.fetchReq<DeleteMysqlsReq, DeleteMysqlsResp>(`/apis/mcamel.io/mysql/
|
|
913
|
+
return fm.fetchReq<DeleteMysqlsReq, DeleteMysqlsResp>(`/apis/mcamel.io/mysql/v1alpha3/${req["workspaceId"]}/mysqls`, {...initReq, method: "POST", body: JSON.stringify(req)})
|
|
640
914
|
}
|
|
641
915
|
static GetMysqlBackupList(req: GetMysqlBackupListReq, initReq?: fm.InitReq): Promise<GetMysqlBackupListResp> {
|
|
642
|
-
return fm.fetchReq<GetMysqlBackupListReq, GetMysqlBackupListResp>(`/apis/mcamel.io/mysql/
|
|
916
|
+
return fm.fetchReq<GetMysqlBackupListReq, GetMysqlBackupListResp>(`/apis/mcamel.io/mysql/v1alpha3/${req["workspaceId"]}/mysql/${req["cluster"]}/${req["namespace"]}/${req["name"]}/backups?${fm.renderURLSearchParams(req, ["workspaceId", "cluster", "namespace", "name"])}`, {...initReq, method: "GET"})
|
|
643
917
|
}
|
|
644
918
|
static GetMysqlBackupJobList(req: GetMysqlBackupJobListReq, initReq?: fm.InitReq): Promise<GetMysqlBackupJobListResp> {
|
|
645
|
-
return fm.fetchReq<GetMysqlBackupJobListReq, GetMysqlBackupJobListResp>(`/apis/mcamel.io/mysql/
|
|
919
|
+
return fm.fetchReq<GetMysqlBackupJobListReq, GetMysqlBackupJobListResp>(`/apis/mcamel.io/mysql/v1alpha3/${req["workspaceId"]}/mysql/${req["cluster"]}/${req["namespace"]}/${req["name"]}/backup/jobs?${fm.renderURLSearchParams(req, ["workspaceId", "cluster", "namespace", "name"])}`, {...initReq, method: "GET"})
|
|
646
920
|
}
|
|
647
921
|
static CreateMysqlBackup(req: CreateMysqlBackupReq, initReq?: fm.InitReq): Promise<CreateMysqlBackupResp> {
|
|
648
|
-
return fm.fetchReq<CreateMysqlBackupReq, CreateMysqlBackupResp>(`/apis/mcamel.io/mysql/
|
|
922
|
+
return fm.fetchReq<CreateMysqlBackupReq, CreateMysqlBackupResp>(`/apis/mcamel.io/mysql/v1alpha3/${req["workspaceId"]}/mysql/${req["cluster"]}/${req["namespace"]}/${req["name"]}/backup`, {...initReq, method: "POST", body: JSON.stringify(req)})
|
|
649
923
|
}
|
|
650
924
|
static DeleteMysqlBackup(req: DeleteMysqlBackupReq, initReq?: fm.InitReq): Promise<DeleteMysqlBackupResp> {
|
|
651
|
-
return fm.fetchReq<DeleteMysqlBackupReq, DeleteMysqlBackupResp>(`/apis/mcamel.io/mysql/
|
|
925
|
+
return fm.fetchReq<DeleteMysqlBackupReq, DeleteMysqlBackupResp>(`/apis/mcamel.io/mysql/v1alpha3/${req["workspaceId"]}/mysql/${req["cluster"]}/${req["namespace"]}/${req["instanceType"]}/${req["name"]}/backup`, {...initReq, method: "DELETE"})
|
|
652
926
|
}
|
|
653
927
|
static GetMysqlBackupSecret(req: GetMysqlBackupSecretReq, initReq?: fm.InitReq): Promise<GetMysqlBackupSecretResp> {
|
|
654
|
-
return fm.fetchReq<GetMysqlBackupSecretReq, GetMysqlBackupSecretResp>(`/apis/mcamel.io/mysql/
|
|
928
|
+
return fm.fetchReq<GetMysqlBackupSecretReq, GetMysqlBackupSecretResp>(`/apis/mcamel.io/mysql/v1alpha3/${req["workspaceId"]}/mysql/secret?${fm.renderURLSearchParams(req, ["workspaceId"])}`, {...initReq, method: "GET"})
|
|
655
929
|
}
|
|
656
930
|
static GetMysqlBackupProviderList(req: GetMysqlBackupProviderListReq, initReq?: fm.InitReq): Promise<GetMysqlBackupProviderListResp> {
|
|
657
|
-
return fm.fetchReq<GetMysqlBackupProviderListReq, GetMysqlBackupProviderListResp>(`/apis/mcamel.io/mysql/
|
|
931
|
+
return fm.fetchReq<GetMysqlBackupProviderListReq, GetMysqlBackupProviderListResp>(`/apis/mcamel.io/mysql/v1alpha3/${req["workspaceId"]}/mysql/providers?${fm.renderURLSearchParams(req, ["workspaceId"])}`, {...initReq, method: "GET"})
|
|
658
932
|
}
|
|
659
933
|
static SetMysqlBackupSecret(req: SetMysqlBackupSecretReq, initReq?: fm.InitReq): Promise<SetMysqlBackupSecretResp> {
|
|
660
|
-
return fm.fetchReq<SetMysqlBackupSecretReq, SetMysqlBackupSecretResp>(`/apis/mcamel.io/mysql/
|
|
934
|
+
return fm.fetchReq<SetMysqlBackupSecretReq, SetMysqlBackupSecretResp>(`/apis/mcamel.io/mysql/v1alpha3/${req["workspaceId"]}/mysql/secret`, {...initReq, method: "PUT", body: JSON.stringify(req)})
|
|
661
935
|
}
|
|
662
936
|
static CreateMysqlRecover(req: CreateMysqlRecoverReq, initReq?: fm.InitReq): Promise<CreateMysqlRecoverResp> {
|
|
663
|
-
return fm.fetchReq<CreateMysqlRecoverReq, CreateMysqlRecoverResp>(`/apis/mcamel.io/mysql/
|
|
937
|
+
return fm.fetchReq<CreateMysqlRecoverReq, CreateMysqlRecoverResp>(`/apis/mcamel.io/mysql/v1alpha3/${req["workspaceId"]}/mysql/${req["cluster"]}/${req["namespace"]}/${req["name"]}/recover`, {...initReq, method: "POST", body: JSON.stringify(req)})
|
|
664
938
|
}
|
|
665
939
|
static UpdateMysqlBackupConfig(req: UpdateMysqlBackupConfigReq, initReq?: fm.InitReq): Promise<UpdateMysqlBackupConfigResp> {
|
|
666
|
-
return fm.fetchReq<UpdateMysqlBackupConfigReq, UpdateMysqlBackupConfigResp>(`/apis/mcamel.io/mysql/
|
|
940
|
+
return fm.fetchReq<UpdateMysqlBackupConfigReq, UpdateMysqlBackupConfigResp>(`/apis/mcamel.io/mysql/v1alpha3/${req["workspaceId"]}/mysql/${req["cluster"]}/${req["namespace"]}/${req["name"]}/backup/config`, {...initReq, method: "PUT", body: JSON.stringify(req)})
|
|
667
941
|
}
|
|
668
942
|
static GetMysqlUsers(req: GetMysqlUsersReq, initReq?: fm.InitReq): Promise<GetMysqlUsersResp> {
|
|
669
|
-
return fm.fetchReq<GetMysqlUsersReq, GetMysqlUsersResp>(`/apis/mcamel.io/mysql/
|
|
943
|
+
return fm.fetchReq<GetMysqlUsersReq, GetMysqlUsersResp>(`/apis/mcamel.io/mysql/v1alpha3/${req["workspaceId"]}/mysql/${req["cluster"]}/${req["namespace"]}/${req["name"]}/users?${fm.renderURLSearchParams(req, ["workspaceId", "cluster", "namespace", "name"])}`, {...initReq, method: "GET"})
|
|
670
944
|
}
|
|
671
945
|
static GetMinioList(req: GetMinioListReq, initReq?: fm.InitReq): Promise<GetMinioListResp> {
|
|
672
|
-
return fm.fetchReq<GetMinioListReq, GetMinioListResp>(`/apis/mcamel.io/mysql/
|
|
946
|
+
return fm.fetchReq<GetMinioListReq, GetMinioListResp>(`/apis/mcamel.io/mysql/v1alpha3/${req["workspaceId"]}/minios?${fm.renderURLSearchParams(req, ["workspaceId"])}`, {...initReq, method: "GET"})
|
|
947
|
+
}
|
|
948
|
+
static GetTopology(req: GetTopologyRequest, initReq?: fm.InitReq): Promise<GetTopologyResp> {
|
|
949
|
+
return fm.fetchReq<GetTopologyRequest, GetTopologyResp>(`/apis/mcamel.io/mysql/v1alpha3/${req["workspaceId"]}/${req["cluster"]}/${req["namespace"]}/${req["name"]}/${req["instanceType"]}/topology?${fm.renderURLSearchParams(req, ["workspaceId", "cluster", "namespace", "name", "instanceType"])}`, {...initReq, method: "GET"})
|
|
950
|
+
}
|
|
951
|
+
static GetSlowlogList(req: GetSlowlogListReq, initReq?: fm.InitReq): Promise<GetSlowlogListResp> {
|
|
952
|
+
return fm.fetchReq<GetSlowlogListReq, GetSlowlogListResp>(`/apis/mcamel.io/mysql/v1alpha3/${req["workspaceId"]}/${req["cluster"]}/${req["namespace"]}/${req["name"]}/${req["podName"]}/${req["instanceType"]}/slowlog?${fm.renderURLSearchParams(req, ["workspaceId", "cluster", "namespace", "name", "podName", "instanceType"])}`, {...initReq, method: "GET"})
|
|
953
|
+
}
|
|
954
|
+
static DeleteSlowlog(req: DeleteSlowlogReq, initReq?: fm.InitReq): Promise<DeleteSlowlogResp> {
|
|
955
|
+
return fm.fetchReq<DeleteSlowlogReq, DeleteSlowlogResp>(`/apis/mcamel.io/mysql/v1alpha3/${req["workspaceId"]}/mysql/${req["cluster"]}/${req["namespace"]}/${req["name"]}/${req["instanceType"]}/slowlog`, {...initReq, method: "DELETE", body: JSON.stringify(req)})
|
|
956
|
+
}
|
|
957
|
+
static GetSlowlogConf(req: GetSlowlogConfReq, initReq?: fm.InitReq): Promise<GetSlowlogConfResp> {
|
|
958
|
+
return fm.fetchReq<GetSlowlogConfReq, GetSlowlogConfResp>(`/apis/mcamel.io/mysql/v1alpha3/${req["workspaceId"]}/${req["cluster"]}/${req["namespace"]}/${req["name"]}/${req["instanceType"]}/slowlog/conf?${fm.renderURLSearchParams(req, ["workspaceId", "cluster", "namespace", "name", "instanceType"])}`, {...initReq, method: "GET"})
|
|
959
|
+
}
|
|
960
|
+
static UpdateSlowlogStatus(req: UpdateSlowlogStatusReq, initReq?: fm.InitReq): Promise<UpdateSlowlogStatusResp> {
|
|
961
|
+
return fm.fetchReq<UpdateSlowlogStatusReq, UpdateSlowlogStatusResp>(`/apis/mcamel.io/mysql/v1alpha3/${req["workspaceId"]}/${req["cluster"]}/${req["namespace"]}/${req["name"]}/${req["instanceType"]}/slowlog/toggle`, {...initReq, method: "PUT", body: JSON.stringify(req)})
|
|
962
|
+
}
|
|
963
|
+
static GetSlowlogPodList(req: GetSlowlogPodListReq, initReq?: fm.InitReq): Promise<GetSlowlogPodListResp> {
|
|
964
|
+
return fm.fetchReq<GetSlowlogPodListReq, GetSlowlogPodListResp>(`/apis/mcamel.io/mysql/v1alpha3/${req["workspaceId"]}/${req["cluster"]}/${req["namespace"]}/${req["name"]}/${req["instanceType"]}/slowlog/pods?${fm.renderURLSearchParams(req, ["workspaceId", "cluster", "namespace", "name", "instanceType"])}`, {...initReq, method: "GET"})
|
|
965
|
+
}
|
|
966
|
+
static SwitchMaster(req: SwitchMasterRequest, initReq?: fm.InitReq): Promise<SwitchMasterResp> {
|
|
967
|
+
return fm.fetchReq<SwitchMasterRequest, SwitchMasterResp>(`/apis/mcamel.io/mysql/v1alpha3/${req["workspaceId"]}/${req["cluster"]}/${req["namespace"]}/${req["name"]}/${req["instanceType"]}/switch/master`, {...initReq, method: "POST", body: JSON.stringify(req)})
|
|
968
|
+
}
|
|
969
|
+
static GetPodsAndRoles(req: GetPodsAndRolesReq, initReq?: fm.InitReq): Promise<GetPodsAndRolesResp> {
|
|
970
|
+
return fm.fetchReq<GetPodsAndRolesReq, GetPodsAndRolesResp>(`/apis/mcamel.io/mysql/v1alpha3/${req["workspaceId"]}/${req["cluster"]}/${req["namespace"]}/${req["name"]}/${req["instanceType"]}/pods_and_roles?${fm.renderURLSearchParams(req, ["workspaceId", "cluster", "namespace", "name", "instanceType"])}`, {...initReq, method: "GET"})
|
|
673
971
|
}
|
|
674
972
|
}
|