@daocloud-proto/mcamel-mysql 0.1.5 → 0.1.6-1
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/cluster.pb.ts +11 -0
- package/mysql.pb.ts +57 -36
- package/package.json +1 -1
package/cluster.pb.ts
CHANGED
|
@@ -6,7 +6,18 @@
|
|
|
6
6
|
|
|
7
7
|
import * as CommonCommon from "./common.pb"
|
|
8
8
|
import * as fm from "./fetch.pb"
|
|
9
|
+
|
|
10
|
+
export enum GetWorkspaceListReqSortDir {
|
|
11
|
+
ASC = "ASC",
|
|
12
|
+
DESC = "DESC",
|
|
13
|
+
}
|
|
14
|
+
|
|
9
15
|
export type GetWorkspaceListReq = {
|
|
16
|
+
page?: number
|
|
17
|
+
pageSize?: number
|
|
18
|
+
sortDir?: GetWorkspaceListReqSortDir
|
|
19
|
+
sortBy?: string
|
|
20
|
+
searchKey?: string
|
|
10
21
|
}
|
|
11
22
|
|
|
12
23
|
export type GetWorkspaceListRespItem = {
|
package/mysql.pb.ts
CHANGED
|
@@ -87,6 +87,35 @@ export enum GetMysqlConfRespItemsParamType {
|
|
|
87
87
|
conf = "conf",
|
|
88
88
|
}
|
|
89
89
|
|
|
90
|
+
export type UpdateMysqlBackupConfigReq = {
|
|
91
|
+
workspaceId?: number
|
|
92
|
+
cluster?: string
|
|
93
|
+
namespace?: string
|
|
94
|
+
name?: string
|
|
95
|
+
backupSchedule?: string
|
|
96
|
+
backupBucket?: string
|
|
97
|
+
backupHistoryLimit?: number
|
|
98
|
+
backupBucketSubPath?: string
|
|
99
|
+
isOpenAutoBackup?: boolean
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
export type UpdateMysqlBackupConfigResp = {
|
|
103
|
+
message?: string
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
export type CreateMysqlRecoverReq = {
|
|
107
|
+
workspaceId?: number
|
|
108
|
+
cluster?: string
|
|
109
|
+
namespace?: string
|
|
110
|
+
name?: string
|
|
111
|
+
backupPath?: string
|
|
112
|
+
targetMysqlClusterName?: string
|
|
113
|
+
}
|
|
114
|
+
|
|
115
|
+
export type CreateMysqlRecoverResp = {
|
|
116
|
+
message?: string
|
|
117
|
+
}
|
|
118
|
+
|
|
90
119
|
export type GetMysqlBackupListReq = {
|
|
91
120
|
page?: number
|
|
92
121
|
pageSize?: number
|
|
@@ -136,11 +165,11 @@ export type GetMysqlBackupListResp = {
|
|
|
136
165
|
export type GetMysqlBackupJobListRespGetMysqlBackupJobItemGetMysqlBackupJobItemSpec = {
|
|
137
166
|
name?: string
|
|
138
167
|
namespace?: string
|
|
139
|
-
creationTimestamp?:
|
|
168
|
+
creationTimestamp?: string
|
|
140
169
|
parallelism?: number
|
|
141
170
|
completions?: number
|
|
142
171
|
jobType?: GetMysqlBackupJobListRespGetMysqlBackupJobItemGetMysqlBackupJobItemSpecJobType
|
|
143
|
-
|
|
172
|
+
completionTimestamp?: string
|
|
144
173
|
backupType?: GetMysqlBackupJobListRespGetMysqlBackupJobItemGetMysqlBackupJobItemSpecBackupType
|
|
145
174
|
backupPath?: string
|
|
146
175
|
}
|
|
@@ -155,9 +184,18 @@ export type GetMysqlBackupJobListRespGetMysqlBackupJobItem = {
|
|
|
155
184
|
status?: GetMysqlBackupJobListRespGetMysqlBackupJobItemStatus
|
|
156
185
|
}
|
|
157
186
|
|
|
187
|
+
export type GetMysqlBackupJobListRespStatus = {
|
|
188
|
+
isConfigAutoBackup?: boolean
|
|
189
|
+
backupSchedule?: string
|
|
190
|
+
backupSecretName?: string
|
|
191
|
+
backupBucket?: string
|
|
192
|
+
backupBucketSubPath?: string
|
|
193
|
+
}
|
|
194
|
+
|
|
158
195
|
export type GetMysqlBackupJobListResp = {
|
|
159
196
|
items?: GetMysqlBackupJobListRespGetMysqlBackupJobItem[]
|
|
160
197
|
pagination?: CommonCommon.Pagination
|
|
198
|
+
status?: GetMysqlBackupJobListRespStatus
|
|
161
199
|
}
|
|
162
200
|
|
|
163
201
|
export type GetMysqlBackupSecretResp = {
|
|
@@ -181,7 +219,8 @@ export type CreateMysqlBackupReq = {
|
|
|
181
219
|
namespace?: string
|
|
182
220
|
name?: string
|
|
183
221
|
backupName?: string
|
|
184
|
-
|
|
222
|
+
backupBucket?: string
|
|
223
|
+
backupBucketSubPath?: string
|
|
185
224
|
}
|
|
186
225
|
|
|
187
226
|
export type CreateMysqlBackupResp = {
|
|
@@ -255,7 +294,7 @@ export type CreateMysqlReq = {
|
|
|
255
294
|
conf?: string
|
|
256
295
|
backupSchedule?: string
|
|
257
296
|
backupSecretName?: string
|
|
258
|
-
|
|
297
|
+
backupBucket?: string
|
|
259
298
|
isOpenPhpAdmin?: boolean
|
|
260
299
|
phpAdminServiceType?: CreateMysqlReqServiceType
|
|
261
300
|
phpAdminNodePort?: number
|
|
@@ -263,6 +302,11 @@ export type CreateMysqlReq = {
|
|
|
263
302
|
phpAdminCpuLimit?: string
|
|
264
303
|
phpAdminMemoryRequest?: string
|
|
265
304
|
phpAdminMemoryLimit?: string
|
|
305
|
+
backupHistoryLimit?: number
|
|
306
|
+
backupBucketSubPath?: string
|
|
307
|
+
initBackupPath?: string
|
|
308
|
+
initBackupSecretName?: string
|
|
309
|
+
isOpenAutoBackup?: boolean
|
|
266
310
|
}
|
|
267
311
|
|
|
268
312
|
export type UpdateMysqlConfReq = {
|
|
@@ -393,7 +437,7 @@ export type GetMysqlNodeListRespData = {
|
|
|
393
437
|
cpuLimit?: number
|
|
394
438
|
memoryUsage?: number
|
|
395
439
|
memoryLimit?: number
|
|
396
|
-
|
|
440
|
+
createTimestamp?: string
|
|
397
441
|
nodeType?: string
|
|
398
442
|
}
|
|
399
443
|
|
|
@@ -418,30 +462,6 @@ export type GetMysqlReq = {
|
|
|
418
462
|
name?: string
|
|
419
463
|
}
|
|
420
464
|
|
|
421
|
-
export type DeleteMysqlAutoBackupReq = {
|
|
422
|
-
workspaceId?: number
|
|
423
|
-
cluster?: string
|
|
424
|
-
namespace?: string
|
|
425
|
-
name?: string
|
|
426
|
-
}
|
|
427
|
-
|
|
428
|
-
export type CreateMysqlAutoBackupReq = {
|
|
429
|
-
workspaceId?: number
|
|
430
|
-
cluster?: string
|
|
431
|
-
namespace?: string
|
|
432
|
-
name?: string
|
|
433
|
-
backupSchedule?: string
|
|
434
|
-
backupUrl?: string
|
|
435
|
-
}
|
|
436
|
-
|
|
437
|
-
export type CreateMysqlAutoBackupResp = {
|
|
438
|
-
message?: string
|
|
439
|
-
}
|
|
440
|
-
|
|
441
|
-
export type DeleteMysqlAutoBackupResp = {
|
|
442
|
-
message?: string
|
|
443
|
-
}
|
|
444
|
-
|
|
445
465
|
export type GetMysqlResp = {
|
|
446
466
|
data?: MysqlClusterItem
|
|
447
467
|
}
|
|
@@ -468,11 +488,12 @@ export type MysqlClusterItemStatus = {
|
|
|
468
488
|
podsAreReadyNum?: number
|
|
469
489
|
webManagerAddr?: string
|
|
470
490
|
clusterIPs?: string[]
|
|
491
|
+
isAutoBackupEnabled?: boolean
|
|
471
492
|
}
|
|
472
493
|
|
|
473
494
|
export type MysqlClusterItemMetadata = {
|
|
474
495
|
annotations?: {[key: string]: string}
|
|
475
|
-
creationTimestamp?:
|
|
496
|
+
creationTimestamp?: string
|
|
476
497
|
name?: string
|
|
477
498
|
namespace?: string
|
|
478
499
|
}
|
|
@@ -507,12 +528,6 @@ export class Mysql {
|
|
|
507
528
|
static CreateMysql(req: CreateMysqlReq, initReq?: fm.InitReq): Promise<CreateMysqlResp> {
|
|
508
529
|
return fm.fetchReq<CreateMysqlReq, CreateMysqlResp>(`/apis/mcamel.io/mysql/v1alpha1/mysql`, {...initReq, method: "POST", body: JSON.stringify(req)})
|
|
509
530
|
}
|
|
510
|
-
static CreateMysqlAutoBackup(req: CreateMysqlAutoBackupReq, initReq?: fm.InitReq): Promise<CreateMysqlAutoBackupResp> {
|
|
511
|
-
return fm.fetchReq<CreateMysqlAutoBackupReq, CreateMysqlAutoBackupResp>(`/apis/mcamel.io/mysql/v1alpha1/mysql/${req["cluster"]}/${req["namespace"]}/${req["name"]}/autobackup`, {...initReq, method: "POST", body: JSON.stringify(req)})
|
|
512
|
-
}
|
|
513
|
-
static DeleteMysqlAutoBackup(req: DeleteMysqlAutoBackupReq, initReq?: fm.InitReq): Promise<DeleteMysqlAutoBackupResp> {
|
|
514
|
-
return fm.fetchReq<DeleteMysqlAutoBackupReq, DeleteMysqlAutoBackupResp>(`/apis/mcamel.io/mysql/v1alpha1/mysql/${req["workspaceId"]}/${req["cluster"]}/${req["namespace"]}/${req["name"]}/autobackup`, {...initReq, method: "DELETE"})
|
|
515
|
-
}
|
|
516
531
|
static GetMysqlConfs(req: GetMysqlConfReq, initReq?: fm.InitReq): Promise<GetMysqlConfResp> {
|
|
517
532
|
return fm.fetchReq<GetMysqlConfReq, GetMysqlConfResp>(`/apis/mcamel.io/mysql/v1alpha1/mysql/${req["cluster"]}/${req["namespace"]}/${req["name"]}/confs?${fm.renderURLSearchParams(req, ["cluster", "namespace", "name"])}`, {...initReq, method: "GET"})
|
|
518
533
|
}
|
|
@@ -549,4 +564,10 @@ export class Mysql {
|
|
|
549
564
|
static SetMysqlBackupSecret(req: SetMysqlBackupSecretReq, initReq?: fm.InitReq): Promise<SetMysqlBackupSecretResp> {
|
|
550
565
|
return fm.fetchReq<SetMysqlBackupSecretReq, SetMysqlBackupSecretResp>(`/apis/mcamel.io/mysql/v1alpha1/mysql/${req["workspaceId"]}/secret`, {...initReq, method: "PUT", body: JSON.stringify(req)})
|
|
551
566
|
}
|
|
567
|
+
static CreateMysqlRecover(req: CreateMysqlRecoverReq, initReq?: fm.InitReq): Promise<CreateMysqlRecoverResp> {
|
|
568
|
+
return fm.fetchReq<CreateMysqlRecoverReq, CreateMysqlRecoverResp>(`/apis/mcamel.io/mysql/v1alpha1/mysql/${req["cluster"]}/${req["namespace"]}/${req["name"]}/recover`, {...initReq, method: "POST", body: JSON.stringify(req)})
|
|
569
|
+
}
|
|
570
|
+
static UpdateMysqlBackupConfig(req: UpdateMysqlBackupConfigReq, initReq?: fm.InitReq): Promise<UpdateMysqlBackupConfigResp> {
|
|
571
|
+
return fm.fetchReq<UpdateMysqlBackupConfigReq, UpdateMysqlBackupConfigResp>(`/apis/mcamel.io/mysql/v1alpha1/mysql/${req["cluster"]}/${req["namespace"]}/${req["name"]}/backup/config`, {...initReq, method: "PUT", body: JSON.stringify(req)})
|
|
572
|
+
}
|
|
552
573
|
}
|