@daocloud-proto/mcamel-postgresql 0.0.2-7 → 0.0.2-700-g709fb4ff
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 +364 -9
- package/common.pb.ts +89 -2
- package/insight.pb.ts +8 -12
- package/metric.pb.ts +13 -1
- package/package.json +1 -1
- package/postgresql.pb.ts +373 -25
- package/storage_config.pb.ts +188 -0
- package/template.pb.ts +200 -0
- package/version.pb.ts +8 -1
package/postgresql.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> =
|
|
@@ -20,6 +21,81 @@ export enum Status {
|
|
|
20
21
|
Failed = "Failed",
|
|
21
22
|
Running = "Running",
|
|
22
23
|
Creating = "Creating",
|
|
24
|
+
Unknown = "Unknown",
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
export enum GetPostgresqlTopologyRespNodePodStatus {
|
|
28
|
+
Pending = "Pending",
|
|
29
|
+
Running = "Running",
|
|
30
|
+
Succeeded = "Succeeded",
|
|
31
|
+
Failed = "Failed",
|
|
32
|
+
Unknown = "Unknown",
|
|
33
|
+
Terminating = "Terminating",
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
export enum GetPostgresqlTopologyRespNodeRole {
|
|
37
|
+
RoleUnknown = "RoleUnknown",
|
|
38
|
+
Primary = "Primary",
|
|
39
|
+
Standby = "Standby",
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
export enum GetPostgresqlTopologyRespNodeSyncState {
|
|
43
|
+
SyncStateUnknown = "SyncStateUnknown",
|
|
44
|
+
Sync = "Sync",
|
|
45
|
+
Async = "Async",
|
|
46
|
+
Potential = "Potential",
|
|
47
|
+
Quorum = "Quorum",
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
export enum GetPostgresqlTopologyRespNodeState {
|
|
51
|
+
StateUnknown = "StateUnknown",
|
|
52
|
+
Startup = "Startup",
|
|
53
|
+
Catchup = "Catchup",
|
|
54
|
+
Streaming = "Streaming",
|
|
55
|
+
Backup = "Backup",
|
|
56
|
+
Stopping = "Stopping",
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
export enum GetPostgresqlS3ConfigListReqSortDir {
|
|
60
|
+
ASC = "ASC",
|
|
61
|
+
DESC = "DESC",
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
export enum GetPostgresqlBackupListReqSortDir {
|
|
65
|
+
ASC = "ASC",
|
|
66
|
+
DESC = "DESC",
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
export enum GetPostgresqlBackupListRespPostgresqlBackupItemStatusStatus {
|
|
70
|
+
Running = "Running",
|
|
71
|
+
Failed = "Failed",
|
|
72
|
+
Succeeded = "Succeeded",
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
export enum GetPostgresqlBackupListRespPostgresqlBackupItemStatusBackupType {
|
|
76
|
+
Full = "Full",
|
|
77
|
+
Incremental = "Incremental",
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
export enum GetPostgresqlBackupListRespPostgresqlBackupItemStatusBackupMethod {
|
|
81
|
+
Manual = "Manual",
|
|
82
|
+
Auto = "Auto",
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
export enum PostgresqlBackupItemStatusStatus {
|
|
86
|
+
Running = "Running",
|
|
87
|
+
Failed = "Failed",
|
|
88
|
+
Succeeded = "Succeeded",
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
export enum PostgresqlBackupItemStatusBackupType {
|
|
92
|
+
Full = "Full",
|
|
93
|
+
Incremental = "Incremental",
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
export enum PostgresqlBackupItemStatusBackupMethod {
|
|
97
|
+
Manual = "Manual",
|
|
98
|
+
Auto = "Auto",
|
|
23
99
|
}
|
|
24
100
|
|
|
25
101
|
export enum GetPostgresqlListReqSortDir {
|
|
@@ -52,8 +128,8 @@ export enum GetPostgresqlPodListRespPodStatus {
|
|
|
52
128
|
}
|
|
53
129
|
|
|
54
130
|
export enum GetPostgresqlPodListRespPodType {
|
|
55
|
-
|
|
56
|
-
|
|
131
|
+
Primary = "Primary",
|
|
132
|
+
Standby = "Standby",
|
|
57
133
|
PgAdmin = "PgAdmin",
|
|
58
134
|
}
|
|
59
135
|
|
|
@@ -67,10 +143,222 @@ export enum GetPostgresqlConfRespItemsParamType {
|
|
|
67
143
|
conf = "conf",
|
|
68
144
|
}
|
|
69
145
|
|
|
146
|
+
export enum PostgresqlItemStatusRestoreInitialStatus {
|
|
147
|
+
Unknown = "Unknown",
|
|
148
|
+
Running = "Running",
|
|
149
|
+
Failed = "Failed",
|
|
150
|
+
Succeeded = "Succeeded",
|
|
151
|
+
}
|
|
152
|
+
|
|
153
|
+
export type GetPostgresqlTopologyReq = {
|
|
154
|
+
cluster?: string
|
|
155
|
+
namespace?: string
|
|
156
|
+
name?: string
|
|
157
|
+
workspaceId?: number
|
|
158
|
+
}
|
|
159
|
+
|
|
160
|
+
export type GetPostgresqlTopologyRespNode = {
|
|
161
|
+
cluster?: string
|
|
162
|
+
namespace?: string
|
|
163
|
+
podName?: string
|
|
164
|
+
ip?: string
|
|
165
|
+
podStatus?: GetPostgresqlTopologyRespNodePodStatus
|
|
166
|
+
totalContainer?: number
|
|
167
|
+
totalContainerReady?: number
|
|
168
|
+
podCpuRequest?: string
|
|
169
|
+
podMemoryRequest?: string
|
|
170
|
+
podCpuLimit?: string
|
|
171
|
+
podMemoryLimit?: string
|
|
172
|
+
role?: GetPostgresqlTopologyRespNodeRole
|
|
173
|
+
syncState?: GetPostgresqlTopologyRespNodeSyncState
|
|
174
|
+
state?: GetPostgresqlTopologyRespNodeState
|
|
175
|
+
sentLsn?: string
|
|
176
|
+
writeLsn?: string
|
|
177
|
+
flushLsn?: string
|
|
178
|
+
replayLsn?: string
|
|
179
|
+
}
|
|
180
|
+
|
|
181
|
+
export type GetPostgresqlTopologyRespEdges = {
|
|
182
|
+
source?: string
|
|
183
|
+
target?: string
|
|
184
|
+
properties?: {[key: string]: string}
|
|
185
|
+
}
|
|
186
|
+
|
|
187
|
+
export type GetPostgresqlTopologyResp = {
|
|
188
|
+
nodes?: GetPostgresqlTopologyRespNode[]
|
|
189
|
+
edges?: GetPostgresqlTopologyRespEdges[]
|
|
190
|
+
}
|
|
191
|
+
|
|
192
|
+
export type CreatePostgresqlRestoreReq = {
|
|
193
|
+
cluster?: string
|
|
194
|
+
namespace?: string
|
|
195
|
+
name?: string
|
|
196
|
+
backupName?: string
|
|
197
|
+
targetPostgresqlName?: string
|
|
198
|
+
targetPostgresqlNamespace?: string
|
|
199
|
+
targetPostgresqlCluster?: string
|
|
200
|
+
workspaceId?: number
|
|
201
|
+
}
|
|
202
|
+
|
|
203
|
+
export type CreatePostgresqlRestoreResp = {
|
|
204
|
+
message?: string
|
|
205
|
+
}
|
|
206
|
+
|
|
207
|
+
export type DeletePostgresqlBackupReq = {
|
|
208
|
+
cluster?: string
|
|
209
|
+
namespace?: string
|
|
210
|
+
name?: string
|
|
211
|
+
backupName?: string
|
|
212
|
+
removeRemoteBackup?: boolean
|
|
213
|
+
workspaceId?: number
|
|
214
|
+
}
|
|
215
|
+
|
|
216
|
+
export type DeletePostgresqlBackupResp = {
|
|
217
|
+
message?: string
|
|
218
|
+
}
|
|
219
|
+
|
|
220
|
+
export type CreateBucketExistCheckingReq = {
|
|
221
|
+
endpoint?: string
|
|
222
|
+
accessKey?: string
|
|
223
|
+
secretKey?: string
|
|
224
|
+
bucket?: string
|
|
225
|
+
}
|
|
226
|
+
|
|
227
|
+
export type CreateBucketExistCheckingResp = {
|
|
228
|
+
message?: string
|
|
229
|
+
}
|
|
230
|
+
|
|
231
|
+
export type UpdatePostgresqlS3ConfigReq = {
|
|
232
|
+
cluster?: string
|
|
233
|
+
namespace?: string
|
|
234
|
+
name?: string
|
|
235
|
+
description?: string
|
|
236
|
+
endpoint?: string
|
|
237
|
+
accessKey?: string
|
|
238
|
+
secretKey?: string
|
|
239
|
+
bucket?: string
|
|
240
|
+
retentionTime?: string
|
|
241
|
+
provider?: string
|
|
242
|
+
workspaceId?: number
|
|
243
|
+
}
|
|
244
|
+
|
|
245
|
+
export type UpdatePostgresqlS3ConfigResp = {
|
|
246
|
+
message?: string
|
|
247
|
+
}
|
|
248
|
+
|
|
249
|
+
export type GetPostgresqlS3ConfigListReq = {
|
|
250
|
+
page?: number
|
|
251
|
+
pageSize?: number
|
|
252
|
+
sortDir?: GetPostgresqlS3ConfigListReqSortDir
|
|
253
|
+
sortBy?: string
|
|
254
|
+
searchKey?: string
|
|
255
|
+
workspaceId?: number
|
|
256
|
+
}
|
|
257
|
+
|
|
258
|
+
export type GetPostgresqlS3ConfigListRespGetPostgresqlS3ConfigItemsStatus = {
|
|
259
|
+
createTimestamp?: string
|
|
260
|
+
updateTimestamp?: string
|
|
261
|
+
backupPath?: string
|
|
262
|
+
}
|
|
263
|
+
|
|
264
|
+
export type GetPostgresqlS3ConfigListRespGetPostgresqlS3ConfigItems = {
|
|
265
|
+
spec?: UpdatePostgresqlS3ConfigReq
|
|
266
|
+
status?: GetPostgresqlS3ConfigListRespGetPostgresqlS3ConfigItemsStatus
|
|
267
|
+
}
|
|
268
|
+
|
|
269
|
+
export type GetPostgresqlS3ConfigListResp = {
|
|
270
|
+
items?: GetPostgresqlS3ConfigListRespGetPostgresqlS3ConfigItems[]
|
|
271
|
+
pagination?: CommonCommon.Pagination
|
|
272
|
+
}
|
|
273
|
+
|
|
274
|
+
export type UpdatePostgresqlBackupConfigReq = {
|
|
275
|
+
cluster?: string
|
|
276
|
+
namespace?: string
|
|
277
|
+
name?: string
|
|
278
|
+
isOpenAutoBackup?: boolean
|
|
279
|
+
backupSchedule?: string
|
|
280
|
+
workspaceId?: number
|
|
281
|
+
}
|
|
282
|
+
|
|
283
|
+
export type UpdatePostgresqlBackupConfigResp = {
|
|
284
|
+
message?: string
|
|
285
|
+
}
|
|
286
|
+
|
|
287
|
+
export type GetPostgresqlBackupListReq = {
|
|
288
|
+
page?: number
|
|
289
|
+
pageSize?: number
|
|
290
|
+
sortDir?: GetPostgresqlBackupListReqSortDir
|
|
291
|
+
sortBy?: string
|
|
292
|
+
searchKey?: string
|
|
293
|
+
cluster?: string
|
|
294
|
+
namespace?: string
|
|
295
|
+
name?: string
|
|
296
|
+
workspaceId?: number
|
|
297
|
+
}
|
|
298
|
+
|
|
299
|
+
export type GetPostgresqlBackupListRespPostgresqlBackupItemMetadata = {
|
|
300
|
+
creationTimestamp?: string
|
|
301
|
+
name?: string
|
|
302
|
+
namespace?: string
|
|
303
|
+
}
|
|
304
|
+
|
|
305
|
+
export type GetPostgresqlBackupListRespPostgresqlBackupItemStatusJobCondition = {
|
|
306
|
+
type?: string
|
|
307
|
+
status?: string
|
|
308
|
+
reason?: string
|
|
309
|
+
message?: string
|
|
310
|
+
}
|
|
311
|
+
|
|
312
|
+
export type GetPostgresqlBackupListRespPostgresqlBackupItemStatus = {
|
|
313
|
+
completionTimestamp?: string
|
|
314
|
+
startTime?: string
|
|
315
|
+
active?: number
|
|
316
|
+
succeeded?: number
|
|
317
|
+
failed?: number
|
|
318
|
+
conditions?: GetPostgresqlBackupListRespPostgresqlBackupItemStatusJobCondition[]
|
|
319
|
+
status?: GetPostgresqlBackupListRespPostgresqlBackupItemStatusStatus
|
|
320
|
+
backupType?: GetPostgresqlBackupListRespPostgresqlBackupItemStatusBackupType
|
|
321
|
+
backupMethod?: GetPostgresqlBackupListRespPostgresqlBackupItemStatusBackupMethod
|
|
322
|
+
storePath?: string
|
|
323
|
+
}
|
|
324
|
+
|
|
325
|
+
export type GetPostgresqlBackupListRespPostgresqlBackupItem = {
|
|
326
|
+
metadata?: GetPostgresqlBackupListRespPostgresqlBackupItemMetadata
|
|
327
|
+
spec?: CreatePostgresqlBackupReq
|
|
328
|
+
status?: GetPostgresqlBackupListRespPostgresqlBackupItemStatus
|
|
329
|
+
}
|
|
330
|
+
|
|
331
|
+
export type GetPostgresqlBackupListResp = {
|
|
332
|
+
items?: GetPostgresqlBackupListRespPostgresqlBackupItem[]
|
|
333
|
+
pagination?: CommonCommon.Pagination
|
|
334
|
+
}
|
|
335
|
+
|
|
336
|
+
export type CreatePostgresqlBackupReq = {
|
|
337
|
+
cluster?: string
|
|
338
|
+
namespace?: string
|
|
339
|
+
name?: string
|
|
340
|
+
backupName?: string
|
|
341
|
+
workspaceId?: number
|
|
342
|
+
}
|
|
343
|
+
|
|
344
|
+
export type CreatePostgresqlBackupResp = {
|
|
345
|
+
message?: string
|
|
346
|
+
}
|
|
347
|
+
|
|
348
|
+
export type PostgresqlBackupItemStatus = {
|
|
349
|
+
status?: PostgresqlBackupItemStatusStatus
|
|
350
|
+
message?: string
|
|
351
|
+
backupUrl?: string
|
|
352
|
+
backupType?: PostgresqlBackupItemStatusBackupType
|
|
353
|
+
backupMethod?: PostgresqlBackupItemStatusBackupMethod
|
|
354
|
+
completionTimestamp?: string
|
|
355
|
+
}
|
|
356
|
+
|
|
70
357
|
export type GetPostgresqlUsersReq = {
|
|
71
358
|
cluster?: string
|
|
72
359
|
namespace?: string
|
|
73
360
|
name?: string
|
|
361
|
+
workspaceId?: number
|
|
74
362
|
}
|
|
75
363
|
|
|
76
364
|
export type GetPostgresqlUsersRespUserItem = {
|
|
@@ -89,6 +377,23 @@ export type GetPostgresqlListReq = {
|
|
|
89
377
|
sortBy?: string
|
|
90
378
|
searchKey?: string
|
|
91
379
|
workspaceId?: number
|
|
380
|
+
filterCluster?: string
|
|
381
|
+
filterNamespace?: string
|
|
382
|
+
filterNamespaces?: string[]
|
|
383
|
+
}
|
|
384
|
+
|
|
385
|
+
export type GetAllVisibleWorkspacePostgresqlListReq = {
|
|
386
|
+
page?: number
|
|
387
|
+
pageSize?: number
|
|
388
|
+
searchKey?: string
|
|
389
|
+
filterCluster?: string
|
|
390
|
+
filterNamespace?: string
|
|
391
|
+
filterNamespaces?: string[]
|
|
392
|
+
}
|
|
393
|
+
|
|
394
|
+
export type GetAllVisibleWorkspacePostgresqlListResp = {
|
|
395
|
+
items?: PostgresqlItem[]
|
|
396
|
+
pagination?: CommonCommon.Pagination
|
|
92
397
|
}
|
|
93
398
|
|
|
94
399
|
export type GetPostgresqlConfReq = {
|
|
@@ -100,10 +405,12 @@ export type GetPostgresqlConfReq = {
|
|
|
100
405
|
cluster?: string
|
|
101
406
|
namespace?: string
|
|
102
407
|
name?: string
|
|
408
|
+
workspaceId?: number
|
|
103
409
|
}
|
|
104
410
|
|
|
105
411
|
export type GetPostgresqlParamReq = {
|
|
106
412
|
cluster?: string
|
|
413
|
+
workspaceId?: number
|
|
107
414
|
}
|
|
108
415
|
|
|
109
416
|
export type CreatePostgresqlReqPorts = {
|
|
@@ -136,6 +443,7 @@ export type CreatePostgresqlReq = {
|
|
|
136
443
|
memoryRequest?: string
|
|
137
444
|
memoryLimit?: string
|
|
138
445
|
conf?: string
|
|
446
|
+
confTemplateName?: string
|
|
139
447
|
isOpenPgAdmin?: boolean
|
|
140
448
|
pgAdminServiceType?: CommonCommon.ServiceType
|
|
141
449
|
pgAdminNodePort?: number
|
|
@@ -147,6 +455,8 @@ export type CreatePostgresqlReq = {
|
|
|
147
455
|
pgAdminDefaultEmail?: string
|
|
148
456
|
pgAdminDefaultPassword?: string
|
|
149
457
|
affinity?: CommonCommon.Affinity
|
|
458
|
+
backupConfig?: UpdatePostgresqlBackupConfigReq
|
|
459
|
+
accessWhitelist?: CommonCommon.AccessWhitelist
|
|
150
460
|
externalTrafficPolicy?: CommonCommon.ExternalTrafficPolicy
|
|
151
461
|
lbTyp?: CommonCommon.LBTyp
|
|
152
462
|
lbPoolName?: string
|
|
@@ -155,6 +465,9 @@ export type CreatePostgresqlReq = {
|
|
|
155
465
|
pgAdminLbTyp?: CommonCommon.LBTyp
|
|
156
466
|
pgAdminLbPoolName?: string
|
|
157
467
|
pgAdminLbAddress?: string
|
|
468
|
+
initSourcePostgresqlClusterName?: string
|
|
469
|
+
initSourceBackupName?: string
|
|
470
|
+
tolerations?: CommonCommon.Toleration[]
|
|
158
471
|
}
|
|
159
472
|
|
|
160
473
|
export type UpdatePostgresqlConfReq = {
|
|
@@ -162,6 +475,9 @@ export type UpdatePostgresqlConfReq = {
|
|
|
162
475
|
namespace?: string
|
|
163
476
|
name?: string
|
|
164
477
|
conf?: string
|
|
478
|
+
confItems?: TemplateTemplate.TemplateConfigItem[]
|
|
479
|
+
reloadFromConfTemplateName?: string
|
|
480
|
+
workspaceId?: number
|
|
165
481
|
}
|
|
166
482
|
|
|
167
483
|
export type UpdatePostgresqlParamsResp = {
|
|
@@ -176,13 +492,6 @@ export type GetPostgresqlParamRespSelectDataStringValue = {
|
|
|
176
492
|
value?: string
|
|
177
493
|
}
|
|
178
494
|
|
|
179
|
-
export type GetPostgresqlParamRespSelectDataResourceValue = {
|
|
180
|
-
cpuRequest?: string
|
|
181
|
-
cpuLimit?: string
|
|
182
|
-
memoryRequest?: string
|
|
183
|
-
memoryLimit?: string
|
|
184
|
-
}
|
|
185
|
-
|
|
186
495
|
export type GetPostgresqlParamRespSelectDataIntValue = {
|
|
187
496
|
value?: number
|
|
188
497
|
}
|
|
@@ -197,7 +506,7 @@ type BaseGetPostgresqlParamRespSelectData = {
|
|
|
197
506
|
}
|
|
198
507
|
|
|
199
508
|
export type GetPostgresqlParamRespSelectData = BaseGetPostgresqlParamRespSelectData
|
|
200
|
-
& OneOf<{ sValue: GetPostgresqlParamRespSelectDataStringValue;
|
|
509
|
+
& OneOf<{ sValue: GetPostgresqlParamRespSelectDataStringValue; iValue: GetPostgresqlParamRespSelectDataIntValue; scValue: GetPostgresqlParamRespSelectDataStorageClassValue }>
|
|
201
510
|
|
|
202
511
|
export type GetPostgresqlParamRespSelect = {
|
|
203
512
|
selectType?: GetPostgresqlParamRespSelectSelectType
|
|
@@ -208,7 +517,6 @@ export type GetPostgresqlParamResp = {
|
|
|
208
517
|
version?: GetPostgresqlParamRespSelect
|
|
209
518
|
conf?: GetPostgresqlParamRespSelect
|
|
210
519
|
replicas?: GetPostgresqlParamRespSelect
|
|
211
|
-
resource?: GetPostgresqlParamRespSelect
|
|
212
520
|
storage?: GetPostgresqlParamRespSelect
|
|
213
521
|
}
|
|
214
522
|
|
|
@@ -238,10 +546,12 @@ export type DeletePostgresqlReq = {
|
|
|
238
546
|
cluster?: string
|
|
239
547
|
namespace?: string
|
|
240
548
|
name?: string
|
|
549
|
+
workspaceId?: number
|
|
241
550
|
}
|
|
242
551
|
|
|
243
552
|
export type DeletePostgresqlsReq = {
|
|
244
553
|
data?: DeletePostgresqlReq[]
|
|
554
|
+
workspaceId?: number
|
|
245
555
|
}
|
|
246
556
|
|
|
247
557
|
export type DeletePostgresqlResp = {
|
|
@@ -261,6 +571,7 @@ export type GetPostgresqlPodListReq = {
|
|
|
261
571
|
sortDir?: GetPostgresqlPodListReqSortDir
|
|
262
572
|
sortBy?: string
|
|
263
573
|
searchKey?: string
|
|
574
|
+
workspaceId?: number
|
|
264
575
|
}
|
|
265
576
|
|
|
266
577
|
export type GetPostgresqlPodListRespData = {
|
|
@@ -288,6 +599,9 @@ export type GetPostgresqlGrafanaAddrReq = {
|
|
|
288
599
|
cluster?: string
|
|
289
600
|
namespace?: string
|
|
290
601
|
name?: string
|
|
602
|
+
from?: string
|
|
603
|
+
to?: string
|
|
604
|
+
workspaceId?: number
|
|
291
605
|
}
|
|
292
606
|
|
|
293
607
|
export type GetPostgresqlGrafanaAddrResp = {
|
|
@@ -298,6 +612,7 @@ export type GetPostgresqlReq = {
|
|
|
298
612
|
cluster?: string
|
|
299
613
|
namespace?: string
|
|
300
614
|
name?: string
|
|
615
|
+
workspaceId?: number
|
|
301
616
|
}
|
|
302
617
|
|
|
303
618
|
export type GetPostgresqlResp = {
|
|
@@ -327,6 +642,8 @@ export type PostgresqlItemStatus = {
|
|
|
327
642
|
clusterIPs?: string[]
|
|
328
643
|
avgReplicationLagInBytes?: string
|
|
329
644
|
common?: CommonCommon.CommonItemStatus
|
|
645
|
+
isControl?: boolean
|
|
646
|
+
restoreInitialStatus?: PostgresqlItemStatusRestoreInitialStatus
|
|
330
647
|
}
|
|
331
648
|
|
|
332
649
|
export type PostgresqlItemMetadata = {
|
|
@@ -334,6 +651,7 @@ export type PostgresqlItemMetadata = {
|
|
|
334
651
|
creationTimestamp?: string
|
|
335
652
|
name?: string
|
|
336
653
|
namespace?: string
|
|
654
|
+
uid?: string
|
|
337
655
|
}
|
|
338
656
|
|
|
339
657
|
export type PostgresqlItem = {
|
|
@@ -344,44 +662,74 @@ export type PostgresqlItem = {
|
|
|
344
662
|
status?: PostgresqlItemStatus
|
|
345
663
|
}
|
|
346
664
|
|
|
347
|
-
export class
|
|
665
|
+
export class PostgresqlV2 {
|
|
348
666
|
static GetPostgresqlList(req: GetPostgresqlListReq, initReq?: fm.InitReq): Promise<GetPostgresqlListResp> {
|
|
349
|
-
return fm.fetchReq<GetPostgresqlListReq, GetPostgresqlListResp>(`/apis/mcamel.io/postgresql/
|
|
667
|
+
return fm.fetchReq<GetPostgresqlListReq, GetPostgresqlListResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["workspaceId"]}/postgresqls?${fm.renderURLSearchParams(req, ["workspaceId"])}`, {...initReq, method: "GET"})
|
|
668
|
+
}
|
|
669
|
+
static GetAllVisibleWorkspacePostgresqlList(req: GetAllVisibleWorkspacePostgresqlListReq, initReq?: fm.InitReq): Promise<GetAllVisibleWorkspacePostgresqlListResp> {
|
|
670
|
+
return fm.fetchReq<GetAllVisibleWorkspacePostgresqlListReq, GetAllVisibleWorkspacePostgresqlListResp>(`/apis/mcamel.io/postgresql/v1alpha2/postgresqls?${fm.renderURLSearchParams(req, [])}`, {...initReq, method: "GET"})
|
|
350
671
|
}
|
|
351
672
|
static GetPostgresqlOperatorVersionList(req: GetPostgresqlOperatorVersionListReq, initReq?: fm.InitReq): Promise<GetPostgresqlOperatorVersionListResp> {
|
|
352
|
-
return fm.fetchReq<GetPostgresqlOperatorVersionListReq, GetPostgresqlOperatorVersionListResp>(`/apis/mcamel.io/postgresql/
|
|
673
|
+
return fm.fetchReq<GetPostgresqlOperatorVersionListReq, GetPostgresqlOperatorVersionListResp>(`/apis/mcamel.io/postgresql/v1alpha2/postgres-operator/versions?${fm.renderURLSearchParams(req, [])}`, {...initReq, method: "GET"})
|
|
353
674
|
}
|
|
354
675
|
static GetPostgresql(req: GetPostgresqlReq, initReq?: fm.InitReq): Promise<GetPostgresqlResp> {
|
|
355
|
-
return fm.fetchReq<GetPostgresqlReq, GetPostgresqlResp>(`/apis/mcamel.io/postgresql/
|
|
676
|
+
return fm.fetchReq<GetPostgresqlReq, GetPostgresqlResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["workspaceId"]}/postgresql/${req["cluster"]}/${req["namespace"]}/${req["name"]}?${fm.renderURLSearchParams(req, ["workspaceId", "cluster", "namespace", "name"])}`, {...initReq, method: "GET"})
|
|
356
677
|
}
|
|
357
678
|
static GetPostgresqlParam(req: GetPostgresqlParamReq, initReq?: fm.InitReq): Promise<GetPostgresqlParamResp> {
|
|
358
|
-
return fm.fetchReq<GetPostgresqlParamReq, GetPostgresqlParamResp>(`/apis/mcamel.io/postgresql/
|
|
679
|
+
return fm.fetchReq<GetPostgresqlParamReq, GetPostgresqlParamResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["workspaceId"]}/postgresql-params/${req["cluster"]}?${fm.renderURLSearchParams(req, ["workspaceId", "cluster"])}`, {...initReq, method: "GET"})
|
|
359
680
|
}
|
|
360
681
|
static GetPostgresqlPodList(req: GetPostgresqlPodListReq, initReq?: fm.InitReq): Promise<GetPostgresqlPodListResp> {
|
|
361
|
-
return fm.fetchReq<GetPostgresqlPodListReq, GetPostgresqlPodListResp>(`/apis/mcamel.io/postgresql/
|
|
682
|
+
return fm.fetchReq<GetPostgresqlPodListReq, GetPostgresqlPodListResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["workspaceId"]}/postgresql/${req["cluster"]}/${req["namespace"]}/${req["name"]}/pods?${fm.renderURLSearchParams(req, ["workspaceId", "cluster", "namespace", "name"])}`, {...initReq, method: "GET"})
|
|
362
683
|
}
|
|
363
684
|
static GetPostgresqlGrafanaAddr(req: GetPostgresqlGrafanaAddrReq, initReq?: fm.InitReq): Promise<GetPostgresqlGrafanaAddrResp> {
|
|
364
|
-
return fm.fetchReq<GetPostgresqlGrafanaAddrReq, GetPostgresqlGrafanaAddrResp>(`/apis/mcamel.io/postgresql/
|
|
685
|
+
return fm.fetchReq<GetPostgresqlGrafanaAddrReq, GetPostgresqlGrafanaAddrResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["workspaceId"]}/postgresql/${req["cluster"]}/${req["namespace"]}/${req["name"]}/grafana?${fm.renderURLSearchParams(req, ["workspaceId", "cluster", "namespace", "name"])}`, {...initReq, method: "GET"})
|
|
365
686
|
}
|
|
366
687
|
static CreatePostgresql(req: CreatePostgresqlReq, initReq?: fm.InitReq): Promise<CreatePostgresqlResp> {
|
|
367
|
-
return fm.fetchReq<CreatePostgresqlReq, CreatePostgresqlResp>(`/apis/mcamel.io/postgresql/
|
|
688
|
+
return fm.fetchReq<CreatePostgresqlReq, CreatePostgresqlResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["workspaceId"]}/postgresql`, {...initReq, method: "POST", body: JSON.stringify(req)})
|
|
368
689
|
}
|
|
369
690
|
static GetPostgresqlConfs(req: GetPostgresqlConfReq, initReq?: fm.InitReq): Promise<GetPostgresqlConfResp> {
|
|
370
|
-
return fm.fetchReq<GetPostgresqlConfReq, GetPostgresqlConfResp>(`/apis/mcamel.io/postgresql/
|
|
691
|
+
return fm.fetchReq<GetPostgresqlConfReq, GetPostgresqlConfResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["workspaceId"]}/postgresql/${req["cluster"]}/${req["namespace"]}/${req["name"]}/confs?${fm.renderURLSearchParams(req, ["workspaceId", "cluster", "namespace", "name"])}`, {...initReq, method: "GET"})
|
|
371
692
|
}
|
|
372
693
|
static UpdatePostgresqlConf(req: UpdatePostgresqlConfReq, initReq?: fm.InitReq): Promise<UpdatePostgresqlConfResp> {
|
|
373
|
-
return fm.fetchReq<UpdatePostgresqlConfReq, UpdatePostgresqlConfResp>(`/apis/mcamel.io/postgresql/
|
|
694
|
+
return fm.fetchReq<UpdatePostgresqlConfReq, UpdatePostgresqlConfResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["workspaceId"]}/postgresql/${req["cluster"]}/${req["namespace"]}/${req["name"]}/conf`, {...initReq, method: "PUT", body: JSON.stringify(req)})
|
|
374
695
|
}
|
|
375
696
|
static UpdatePostgresqlParams(req: CreatePostgresqlReq, initReq?: fm.InitReq): Promise<UpdatePostgresqlParamsResp> {
|
|
376
|
-
return fm.fetchReq<CreatePostgresqlReq, UpdatePostgresqlParamsResp>(`/apis/mcamel.io/postgresql/
|
|
697
|
+
return fm.fetchReq<CreatePostgresqlReq, UpdatePostgresqlParamsResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["workspaceId"]}/postgresql/${req["cluster"]}/${req["namespace"]}/${req["name"]}/params`, {...initReq, method: "PUT", body: JSON.stringify(req)})
|
|
377
698
|
}
|
|
378
699
|
static DeletePostgresql(req: DeletePostgresqlReq, initReq?: fm.InitReq): Promise<DeletePostgresqlResp> {
|
|
379
|
-
return fm.fetchReq<DeletePostgresqlReq, DeletePostgresqlResp>(`/apis/mcamel.io/postgresql/
|
|
700
|
+
return fm.fetchReq<DeletePostgresqlReq, DeletePostgresqlResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["workspaceId"]}/postgresql/${req["cluster"]}/${req["namespace"]}/${req["name"]}`, {...initReq, method: "DELETE"})
|
|
380
701
|
}
|
|
381
702
|
static DeletePostgresqls(req: DeletePostgresqlsReq, initReq?: fm.InitReq): Promise<DeletePostgresqlsResp> {
|
|
382
|
-
return fm.fetchReq<DeletePostgresqlsReq, DeletePostgresqlsResp>(`/apis/mcamel.io/postgresql/
|
|
703
|
+
return fm.fetchReq<DeletePostgresqlsReq, DeletePostgresqlsResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["workspaceId"]}/postgresqls`, {...initReq, method: "POST", body: JSON.stringify(req)})
|
|
383
704
|
}
|
|
384
705
|
static GetPostgresqlUsers(req: GetPostgresqlUsersReq, initReq?: fm.InitReq): Promise<GetPostgresqlUsersResp> {
|
|
385
|
-
return fm.fetchReq<GetPostgresqlUsersReq, GetPostgresqlUsersResp>(`/apis/mcamel.io/postgresql/
|
|
706
|
+
return fm.fetchReq<GetPostgresqlUsersReq, GetPostgresqlUsersResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["workspaceId"]}/postgresql/${req["cluster"]}/${req["namespace"]}/${req["name"]}/users?${fm.renderURLSearchParams(req, ["workspaceId", "cluster", "namespace", "name"])}`, {...initReq, method: "GET"})
|
|
707
|
+
}
|
|
708
|
+
static GetPostgresqlBackupList(req: GetPostgresqlBackupListReq, initReq?: fm.InitReq): Promise<GetPostgresqlBackupListResp> {
|
|
709
|
+
return fm.fetchReq<GetPostgresqlBackupListReq, GetPostgresqlBackupListResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["workspaceId"]}/postgresql/${req["cluster"]}/${req["namespace"]}/${req["name"]}/backups?${fm.renderURLSearchParams(req, ["workspaceId", "cluster", "namespace", "name"])}`, {...initReq, method: "GET"})
|
|
710
|
+
}
|
|
711
|
+
static CreatePostgresqlBackup(req: CreatePostgresqlBackupReq, initReq?: fm.InitReq): Promise<CreatePostgresqlBackupResp> {
|
|
712
|
+
return fm.fetchReq<CreatePostgresqlBackupReq, CreatePostgresqlBackupResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["workspaceId"]}/postgresql/${req["cluster"]}/${req["namespace"]}/${req["name"]}/backup`, {...initReq, method: "POST", body: JSON.stringify(req)})
|
|
713
|
+
}
|
|
714
|
+
static CreatePostgresqlRestore(req: CreatePostgresqlRestoreReq, initReq?: fm.InitReq): Promise<CreatePostgresqlRestoreResp> {
|
|
715
|
+
return fm.fetchReq<CreatePostgresqlRestoreReq, CreatePostgresqlRestoreResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["workspaceId"]}/postgresql/${req["cluster"]}/${req["namespace"]}/${req["name"]}/restore`, {...initReq, method: "POST", body: JSON.stringify(req)})
|
|
716
|
+
}
|
|
717
|
+
static DeletePostgresqlBackup(req: DeletePostgresqlBackupReq, initReq?: fm.InitReq): Promise<DeletePostgresqlBackupResp> {
|
|
718
|
+
return fm.fetchReq<DeletePostgresqlBackupReq, DeletePostgresqlBackupResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["workspaceId"]}/postgresql/backups/${req["cluster"]}/${req["namespace"]}/${req["name"]}/backup/${req["backupName"]}`, {...initReq, method: "DELETE", body: JSON.stringify(req)})
|
|
719
|
+
}
|
|
720
|
+
static UpdatePostgresqlBackupConfig(req: UpdatePostgresqlBackupConfigReq, initReq?: fm.InitReq): Promise<UpdatePostgresqlBackupConfigResp> {
|
|
721
|
+
return fm.fetchReq<UpdatePostgresqlBackupConfigReq, UpdatePostgresqlBackupConfigResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["workspaceId"]}/postgresql/${req["cluster"]}/${req["namespace"]}/${req["name"]}/backup/config`, {...initReq, method: "PUT", body: JSON.stringify(req)})
|
|
722
|
+
}
|
|
723
|
+
static GetPostgresqlS3ConfigList(req: GetPostgresqlS3ConfigListReq, initReq?: fm.InitReq): Promise<GetPostgresqlS3ConfigListResp> {
|
|
724
|
+
return fm.fetchReq<GetPostgresqlS3ConfigListReq, GetPostgresqlS3ConfigListResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["workspaceId"]}/s3/configs?${fm.renderURLSearchParams(req, ["workspaceId"])}`, {...initReq, method: "GET"})
|
|
725
|
+
}
|
|
726
|
+
static UpdatePostgresqlS3Config(req: UpdatePostgresqlS3ConfigReq, initReq?: fm.InitReq): Promise<UpdatePostgresqlS3ConfigResp> {
|
|
727
|
+
return fm.fetchReq<UpdatePostgresqlS3ConfigReq, UpdatePostgresqlS3ConfigResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["workspaceId"]}/postgresql/${req["cluster"]}/${req["namespace"]}/${req["name"]}/s3/config`, {...initReq, method: "PUT", body: JSON.stringify(req)})
|
|
728
|
+
}
|
|
729
|
+
static CreateBucketExistChecking(req: CreateBucketExistCheckingReq, initReq?: fm.InitReq): Promise<CreateBucketExistCheckingResp> {
|
|
730
|
+
return fm.fetchReq<CreateBucketExistCheckingReq, CreateBucketExistCheckingResp>(`/apis/mcamel.io/postgresql/v1alpha2/postgresql/s3/config/checking`, {...initReq, method: "PUT", body: JSON.stringify(req)})
|
|
731
|
+
}
|
|
732
|
+
static GetPostgresqlTopology(req: GetPostgresqlTopologyReq, initReq?: fm.InitReq): Promise<GetPostgresqlTopologyResp> {
|
|
733
|
+
return fm.fetchReq<GetPostgresqlTopologyReq, GetPostgresqlTopologyResp>(`/apis/mcamel.io/postgresql/v1alpha2/${req["workspaceId"]}/postgresql/${req["cluster"]}/${req["namespace"]}/${req["name"]}/topology?${fm.renderURLSearchParams(req, ["workspaceId", "cluster", "namespace", "name"])}`, {...initReq, method: "GET"})
|
|
386
734
|
}
|
|
387
735
|
}
|