@daocloud-proto/mcamel-rabbitmq 0.12.1-21 → 0.12.1-210

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 CHANGED
@@ -29,6 +29,9 @@ export enum PermissionsType {
29
29
  CreateTemplate = "CreateTemplate",
30
30
  UpdateTemplate = "UpdateTemplate",
31
31
  DeleteTemplate = "DeleteTemplate",
32
+ GetUserPassword = "GetUserPassword",
33
+ ExportTemplate = "ExportTemplate",
34
+ ImportTemplate = "ImportTemplate",
32
35
  }
33
36
 
34
37
  export enum EventType {
@@ -37,10 +40,9 @@ export enum EventType {
37
40
  Warning = "Warning",
38
41
  }
39
42
 
40
- export enum GetClusterRespNetworkMode {
41
- Unknown = "Unknown",
42
- Flannel = "Flannel",
43
- Calico = "Calico",
43
+ export enum InstallFileReqGVR {
44
+ None = "None",
45
+ CustomResourceDefinition = "CustomResourceDefinition",
44
46
  }
45
47
 
46
48
  export enum GetAllEventListReqSortDir {
@@ -58,26 +60,56 @@ export enum GetWorkspaceListReqSortDir {
58
60
  DESC = "DESC",
59
61
  }
60
62
 
63
+ export enum ClusterItemNetworkMode {
64
+ Unknown = "Unknown",
65
+ Flannel = "Flannel",
66
+ Calico = "Calico",
67
+ }
68
+
61
69
  export enum GetInsightAgentStatusRespInsightAgentStatus {
62
70
  NotInstall = "NotInstall",
63
71
  Install = "Install",
64
72
  }
65
73
 
66
- export type GetClusterReq = {
74
+ export type InstallFileReq = {
67
75
  cluster?: string
76
+ path?: string
77
+ gvr?: InstallFileReqGVR
68
78
  }
69
79
 
70
- export type GetClusterRespMetadata = {
71
- name?: string
80
+ export type InstallFileResp = {
81
+ message?: string
82
+ }
83
+
84
+ export type GetInstallVersionReq = {
85
+ cluster?: string
86
+ }
87
+
88
+ export type GetInstallVersionRespSupportVersion = {
89
+ minVersion?: string
90
+ maxVersion?: string
72
91
  }
73
92
 
74
- export type GetClusterRespStatus = {
75
- networkMode?: GetClusterRespNetworkMode[]
93
+ export type GetInstallVersionRespStatus = {
94
+ inRange?: boolean
76
95
  }
77
96
 
78
- export type GetClusterResp = {
79
- metadata?: GetClusterRespMetadata
80
- status?: GetClusterRespStatus
97
+ export type GetInstallVersionResp = {
98
+ clusterVersion?: string
99
+ supportVersion?: GetInstallVersionRespSupportVersion
100
+ status?: GetInstallVersionRespStatus
101
+ }
102
+
103
+ export type RestartInstanceReq = {
104
+ workspaceId?: number
105
+ cluster?: string
106
+ namespace?: string
107
+ name?: string
108
+ extra?: string
109
+ }
110
+
111
+ export type RestartInstanceResp = {
112
+ message?: string
81
113
  }
82
114
 
83
115
  export type GetPermissionsListReq = {
@@ -105,6 +137,9 @@ export type GetPermissionsListRespPermissions = {
105
137
  createTemplate?: boolean
106
138
  updateTemplate?: boolean
107
139
  deleteTemplate?: boolean
140
+ getUserPassword?: boolean
141
+ exportTemplate?: boolean
142
+ importTemplate?: boolean
108
143
  }
109
144
 
110
145
  export type GetPermissionsListResp = {
@@ -185,8 +220,14 @@ export type GetClusterNodeLabelListRespLabel = {
185
220
  value?: string[]
186
221
  }
187
222
 
223
+ export type GetClusterNodeLabelListRespNode2Label = {
224
+ nodeName?: string
225
+ label?: GetClusterNodeLabelListRespLabel[]
226
+ }
227
+
188
228
  export type GetClusterNodeLabelListResp = {
189
229
  items?: GetClusterNodeLabelListRespLabel[]
230
+ items1?: GetClusterNodeLabelListRespNode2Label[]
190
231
  pagination?: CommonCommon.Pagination
191
232
  }
192
233
 
@@ -288,15 +329,39 @@ export type GetWorkspaceListResp = {
288
329
  pagination?: CommonCommon.Pagination
289
330
  }
290
331
 
332
+ export type GetClusterHostnetworkPortsReq = {
333
+ workspaceId?: number
334
+ cluster?: string
335
+ }
336
+
291
337
  export type GetClusterListReq = {
292
338
  workspaceId?: number
339
+ searchKey?: string
340
+ }
341
+
342
+ export type GetClusterHostnetworkPortsResp = {
343
+ items?: number[]
293
344
  }
294
345
 
295
346
  export type GetClusterListResp = {
296
347
  items?: string[]
348
+ clusters?: ClusterItem[]
297
349
  pagination?: CommonCommon.Pagination
298
350
  }
299
351
 
352
+ export type ClusterItemMetadata = {
353
+ name?: string
354
+ }
355
+
356
+ export type ClusterItemStatus = {
357
+ networkMode?: ClusterItemNetworkMode[]
358
+ }
359
+
360
+ export type ClusterItem = {
361
+ metadata?: ClusterItemMetadata
362
+ status?: ClusterItemStatus
363
+ }
364
+
300
365
  export type GetClusterNamespaceListReq = {
301
366
  workspaceId?: number
302
367
  cluster?: string
@@ -304,6 +369,7 @@ export type GetClusterNamespaceListReq = {
304
369
 
305
370
  export type GetClusterNamespaceListResp = {
306
371
  items?: string[]
372
+ disableItems?: string[]
307
373
  pagination?: CommonCommon.Pagination
308
374
  }
309
375
 
@@ -313,14 +379,45 @@ export type GetInsightAgentStatusReq = {
313
379
 
314
380
  export type GetInsightAgentStatusResp = {
315
381
  status?: GetInsightAgentStatusRespInsightAgentStatus
382
+ clusterStatus?: CommonCommon.ClusterStatus
383
+ }
384
+
385
+ export type GetResourceQuotaReq = {
386
+ cluster?: string
387
+ namespace?: string
388
+ }
389
+
390
+ export type GetResourceQuotaRespMetadata = {
391
+ uid?: string
392
+ name?: string
393
+ namespace?: string
394
+ annotations?: {[key: string]: string}
395
+ resourceVersion?: string
396
+ creationTimestamp?: string
397
+ }
398
+
399
+ export type GetResourceQuotaRespSpec = {
400
+ hard?: {[key: string]: string}
401
+ }
402
+
403
+ export type GetResourceQuotaRespStatus = {
404
+ hard?: {[key: string]: string}
405
+ used?: {[key: string]: string}
406
+ available?: {[key: string]: string}
407
+ }
408
+
409
+ export type GetResourceQuotaResp = {
410
+ metadata?: GetResourceQuotaRespMetadata
411
+ spec?: GetResourceQuotaRespSpec
412
+ status?: GetResourceQuotaRespStatus
316
413
  }
317
414
 
318
415
  export class Cluster {
319
416
  static GetClusterList(req: GetClusterListReq, initReq?: fm.InitReq): Promise<GetClusterListResp> {
320
417
  return fm.fetchReq<GetClusterListReq, GetClusterListResp>(`/apis/mcamel.io/rabbitmq/v1alpha1/${req["workspaceId"]}/clusters?${fm.renderURLSearchParams(req, ["workspaceId"])}`, {...initReq, method: "GET"})
321
418
  }
322
- static GetCluster(req: GetClusterReq, initReq?: fm.InitReq): Promise<GetClusterResp> {
323
- return fm.fetchReq<GetClusterReq, GetClusterResp>(`/apis/mcamel.io/rabbitmq/v1alpha1/${req["cluster"]}?${fm.renderURLSearchParams(req, ["cluster"])}`, {...initReq, method: "GET"})
419
+ static GetClusterHostnetworkPorts(req: GetClusterHostnetworkPortsReq, initReq?: fm.InitReq): Promise<GetClusterHostnetworkPortsResp> {
420
+ return fm.fetchReq<GetClusterHostnetworkPortsReq, GetClusterHostnetworkPortsResp>(`/apis/mcamel.io/rabbitmq/v1alpha1/${req["workspaceId"]}/hostnetwork-ports?${fm.renderURLSearchParams(req, ["workspaceId"])}`, {...initReq, method: "GET"})
324
421
  }
325
422
  static GetClusterNamespaceList(req: GetClusterNamespaceListReq, initReq?: fm.InitReq): Promise<GetClusterNamespaceListResp> {
326
423
  return fm.fetchReq<GetClusterNamespaceListReq, GetClusterNamespaceListResp>(`/apis/mcamel.io/rabbitmq/v1alpha1/${req["workspaceId"]}/${req["cluster"]}/namespaces?${fm.renderURLSearchParams(req, ["workspaceId", "cluster"])}`, {...initReq, method: "GET"})
@@ -355,4 +452,16 @@ export class Cluster {
355
452
  static GetPermissionsList(req: GetPermissionsListReq, initReq?: fm.InitReq): Promise<GetPermissionsListResp> {
356
453
  return fm.fetchReq<GetPermissionsListReq, GetPermissionsListResp>(`/apis/mcamel.io/rabbitmq/v1alpha1/${req["workspaceId"]}/permissions?${fm.renderURLSearchParams(req, ["workspaceId"])}`, {...initReq, method: "GET"})
357
454
  }
455
+ static RestartInstance(req: RestartInstanceReq, initReq?: fm.InitReq): Promise<RestartInstanceResp> {
456
+ return fm.fetchReq<RestartInstanceReq, RestartInstanceResp>(`/apis/mcamel.io/rabbitmq/v1alpha1/${req["workspaceId"]}/restart`, {...initReq, method: "POST", body: JSON.stringify(req)})
457
+ }
458
+ static InstallFile(req: InstallFileReq, initReq?: fm.InitReq): Promise<InstallFileResp> {
459
+ return fm.fetchReq<InstallFileReq, InstallFileResp>(`/apis/mcamel.io/rabbitmq/v1alpha1/${req["cluster"]}/install-file`, {...initReq, method: "POST", body: JSON.stringify(req)})
460
+ }
461
+ static GetInstallVersion(req: GetInstallVersionReq, initReq?: fm.InitReq): Promise<GetInstallVersionResp> {
462
+ return fm.fetchReq<GetInstallVersionReq, GetInstallVersionResp>(`/apis/mcamel.io/rabbitmq/v1alpha1/${req["cluster"]}/install-version?${fm.renderURLSearchParams(req, ["cluster"])}`, {...initReq, method: "GET"})
463
+ }
464
+ static GetResourceQuota(req: GetResourceQuotaReq, initReq?: fm.InitReq): Promise<GetResourceQuotaResp> {
465
+ return fm.fetchReq<GetResourceQuotaReq, GetResourceQuotaResp>(`/apis/mcamel.io/rabbitmq/v1alpha1/${req["cluster"]}/${req["namespace"]}/resourcequota?${fm.renderURLSearchParams(req, ["cluster", "namespace"])}`, {...initReq, method: "GET"})
466
+ }
358
467
  }
package/common.pb.ts CHANGED
@@ -20,6 +20,16 @@ export enum ServiceType {
20
20
  LoadBalancer = "LoadBalancer",
21
21
  }
22
22
 
23
+ export enum ClusterStatus {
24
+ UNSPECIFIED = "UNSPECIFIED",
25
+ Unknown = "Unknown",
26
+ Creating = "Creating",
27
+ Running = "Running",
28
+ Updating = "Updating",
29
+ Deleting = "Deleting",
30
+ Failed = "Failed",
31
+ }
32
+
23
33
  export enum PageInfoReqSortDir {
24
34
  ASC = "ASC",
25
35
  DESC = "DESC",
@@ -40,6 +50,14 @@ export enum PodCommonConditionStatus {
40
50
  PodConditionStatusFalse = "PodConditionStatusFalse",
41
51
  }
42
52
 
53
+ export enum PodCommonFilterPodStatus {
54
+ UNSPECIFIED = "UNSPECIFIED",
55
+ RUNNING = "RUNNING",
56
+ ERROR = "ERROR",
57
+ COMPLETED = "COMPLETED",
58
+ WAITING = "WAITING",
59
+ }
60
+
43
61
  export type Affinity = {
44
62
  nodeAffinity?: NodeAffinity
45
63
  podAffinity?: PodAffinity
@@ -153,6 +171,7 @@ export type PodCommon = {
153
171
  initContainersName?: string[]
154
172
  initContainersStatuses?: ContainerStatus[]
155
173
  containersStatuses?: ContainerStatus[]
174
+ podStatus?: string
156
175
  }
157
176
 
158
177
  export type OwnerReference = {
@@ -170,6 +189,7 @@ export type CommonItemStatus = {
170
189
  avgPvUsedInGb?: number
171
190
  cpuUtilization?: number
172
191
  memoryUtilization?: number
192
+ clusterStatus?: ClusterStatus
173
193
  }
174
194
 
175
195
  export type AccessWhitelistInternal = {
package/metric.pb.ts CHANGED
@@ -7,7 +7,18 @@
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
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name":"@daocloud-proto/mcamel-rabbitmq",
3
- "version":"0.12.1-21",
3
+ "version":"0.12.1-210",
4
4
  "description": "",
5
5
  "main": "index.js",
6
6
  "scripts": {
package/rabbitmq.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> =
@@ -132,14 +133,17 @@ export type CreateRabbitMqReq = {
132
133
  managementLbTyp?: CommonCommon.LBTyp
133
134
  managementLbPoolName?: string
134
135
  managementLbAddress?: string
136
+ conf?: string
137
+ confTemplateName?: string
135
138
  }
136
139
 
137
140
  export type UpdateRabbitMqConfReq = {
138
141
  cluster?: string
139
142
  namespace?: string
140
143
  name?: string
141
- defaultUser?: string
142
- defaultPass?: string
144
+ conf?: string
145
+ confItems?: TemplateTemplate.TemplateConfigItem[]
146
+ reloadFromConfTemplateName?: string
143
147
  }
144
148
 
145
149
  export type UpdateRabbitMqParamsReq = {
@@ -171,13 +175,6 @@ export type GetRabbitMqParamRespSelectDataStringValue = {
171
175
  value?: string
172
176
  }
173
177
 
174
- export type GetRabbitMqParamRespSelectDataResourceValue = {
175
- cpuRequest?: string
176
- cpuLimit?: string
177
- memoryRequest?: string
178
- memoryLimit?: string
179
- }
180
-
181
178
  export type GetRabbitMqParamRespSelectDataIntValue = {
182
179
  value?: number
183
180
  }
@@ -192,7 +189,7 @@ type BaseGetRabbitMqParamRespSelectData = {
192
189
  }
193
190
 
194
191
  export type GetRabbitMqParamRespSelectData = BaseGetRabbitMqParamRespSelectData
195
- & OneOf<{ sValue: GetRabbitMqParamRespSelectDataStringValue; rValue: GetRabbitMqParamRespSelectDataResourceValue; iValue: GetRabbitMqParamRespSelectDataIntValue; scValue: GetRabbitMqParamRespSelectDataStorageClassValue }>
192
+ & OneOf<{ sValue: GetRabbitMqParamRespSelectDataStringValue; iValue: GetRabbitMqParamRespSelectDataIntValue; scValue: GetRabbitMqParamRespSelectDataStorageClassValue }>
196
193
 
197
194
  export type GetRabbitMqParamRespSelect = {
198
195
  selectType?: GetRabbitMqParamRespSelectSelectType
@@ -202,7 +199,6 @@ export type GetRabbitMqParamRespSelect = {
202
199
  export type GetRabbitMqParamResp = {
203
200
  version?: GetRabbitMqParamRespSelect
204
201
  replicas?: GetRabbitMqParamRespSelect
205
- resource?: GetRabbitMqParamRespSelect
206
202
  storage?: GetRabbitMqParamRespSelect
207
203
  }
208
204
 
@@ -0,0 +1,188 @@
1
+ /* eslint-disable */
2
+ // @ts-nocheck
3
+ /*
4
+ * This file is a generated Typescript file for GRPC Gateway, DO NOT MODIFY
5
+ */
6
+
7
+ import * as CommonCommon from "./common.pb"
8
+ import * as fm from "./fetch.pb"
9
+
10
+ type Absent<T, K extends keyof T> = { [k in Exclude<keyof T, K>]?: undefined };
11
+ type OneOf<T> =
12
+ | { [k in keyof T]?: undefined }
13
+ | (
14
+ keyof T extends infer K ?
15
+ (K extends string & keyof T ? { [k in K]: T[K] } & Absent<T, K>
16
+ : never)
17
+ : never);
18
+
19
+ export enum GetStorageConfigParamRespSelectSelectType {
20
+ Single = "Single",
21
+ Multiple = "Multiple",
22
+ }
23
+
24
+ export enum GetStorageConfigConsumersRespStorageConfigConsumerType {
25
+ STORAGE_CONFIG_CONSUMER_TYPE_UNSPECIFIED = "STORAGE_CONFIG_CONSUMER_TYPE_UNSPECIFIED",
26
+ STORAGE_CONFIG_CONSUMER_TYPE_MYSQL = "STORAGE_CONFIG_CONSUMER_TYPE_MYSQL",
27
+ STORAGE_CONFIG_CONSUMER_TYPE_REDIS = "STORAGE_CONFIG_CONSUMER_TYPE_REDIS",
28
+ }
29
+
30
+ export enum GetStorageConfigListReqSortDir {
31
+ ASC = "ASC",
32
+ DESC = "DESC",
33
+ }
34
+
35
+ export type GetStorageConfigParamReq = {
36
+ }
37
+
38
+ export type GetStorageConfigParamRespSelectDataStringValue = {
39
+ value?: string
40
+ }
41
+
42
+ export type GetStorageConfigParamRespSelectDataIntValue = {
43
+ value?: number
44
+ }
45
+
46
+
47
+ type BaseGetStorageConfigParamRespSelectData = {
48
+ }
49
+
50
+ export type GetStorageConfigParamRespSelectData = BaseGetStorageConfigParamRespSelectData
51
+ & OneOf<{ sValue: GetStorageConfigParamRespSelectDataStringValue; iValue: GetStorageConfigParamRespSelectDataIntValue }>
52
+
53
+ export type GetStorageConfigParamRespSelect = {
54
+ selectType?: GetStorageConfigParamRespSelectSelectType
55
+ data?: GetStorageConfigParamRespSelectData[]
56
+ }
57
+
58
+ export type GetStorageConfigParamResp = {
59
+ storageType?: GetStorageConfigParamRespSelect
60
+ }
61
+
62
+ export type CreateStorageConfigBucketCheckJobReq = {
63
+ storageType?: string
64
+ endpoint?: string
65
+ accessKey?: string
66
+ secretKey?: string
67
+ bucket?: string
68
+ cluster?: string
69
+ namespace?: string
70
+ name?: string
71
+ }
72
+
73
+ export type CreateStorageConfigBucketCheckJobResp = {
74
+ message?: string
75
+ }
76
+
77
+ export type CreateStorageConfigReq = {
78
+ workspaceId?: number
79
+ cluster?: string
80
+ namespace?: string
81
+ name?: string
82
+ storageType?: string
83
+ accessKey?: string
84
+ secretKey?: string
85
+ bucket?: string
86
+ endpoint?: string
87
+ minioCluster?: string
88
+ minioNamespace?: string
89
+ minioName?: string
90
+ description?: string
91
+ }
92
+
93
+ export type CreateStorageConfigResp = {
94
+ message?: string
95
+ }
96
+
97
+ export type GetStorageConfigConsumersReq = {
98
+ workspaceId?: number
99
+ name?: string
100
+ }
101
+
102
+ export type GetStorageConfigConsumersRespConsumer = {
103
+ type?: GetStorageConfigConsumersRespStorageConfigConsumerType
104
+ cluster?: string
105
+ namespace?: string
106
+ name?: string
107
+ }
108
+
109
+ export type GetStorageConfigConsumersResp = {
110
+ consumers?: GetStorageConfigConsumersRespConsumer[]
111
+ }
112
+
113
+ export type DeleteStorageConfigReq = {
114
+ workspaceId?: number
115
+ name?: string
116
+ cluster?: string
117
+ namespace?: string
118
+ }
119
+
120
+ export type DeleteStorageConfigResp = {
121
+ message?: string
122
+ }
123
+
124
+ export type UpdateStorageConfigResp = {
125
+ message?: string
126
+ }
127
+
128
+ export type StorageConfigItemStorageConfigStatus = {
129
+ lastUpdateTimestamp?: string
130
+ createTimestamp?: string
131
+ }
132
+
133
+ export type StorageConfigItem = {
134
+ spec?: CreateStorageConfigReq
135
+ status?: StorageConfigItemStorageConfigStatus
136
+ }
137
+
138
+ export type GetStorageConfigReq = {
139
+ workspaceId?: number
140
+ name?: string
141
+ namespace?: string
142
+ cluster?: string
143
+ }
144
+
145
+ export type GetStorageConfigResp = {
146
+ item?: StorageConfigItem
147
+ }
148
+
149
+ export type GetStorageConfigListReq = {
150
+ page?: number
151
+ pageSize?: number
152
+ sortDir?: GetStorageConfigListReqSortDir
153
+ sortBy?: string
154
+ searchKey?: string
155
+ workspaceId?: number
156
+ }
157
+
158
+ export type GetStorageConfigListResp = {
159
+ items?: StorageConfigItem[]
160
+ pagination?: CommonCommon.Pagination
161
+ }
162
+
163
+ export class StorageConfig {
164
+ static GetStorageConfigParam(req: GetStorageConfigParamReq, initReq?: fm.InitReq): Promise<GetStorageConfigParamResp> {
165
+ return fm.fetchReq<GetStorageConfigParamReq, GetStorageConfigParamResp>(`/apis/mcamel.io/rabbitmq/v1alpha1/storage-config/param?${fm.renderURLSearchParams(req, [])}`, {...initReq, method: "GET"})
166
+ }
167
+ static CreateStorageConfigBucketCheckJob(req: CreateStorageConfigBucketCheckJobReq, initReq?: fm.InitReq): Promise<CreateStorageConfigBucketCheckJobResp> {
168
+ return fm.fetchReq<CreateStorageConfigBucketCheckJobReq, CreateStorageConfigBucketCheckJobResp>(`/apis/mcamel.io/rabbitmq/v1alpha1/storage-config/bucket/check-job`, {...initReq, method: "POST", body: JSON.stringify(req)})
169
+ }
170
+ static CreateStorageConfig(req: CreateStorageConfigReq, initReq?: fm.InitReq): Promise<CreateStorageConfigResp> {
171
+ return fm.fetchReq<CreateStorageConfigReq, CreateStorageConfigResp>(`/apis/mcamel.io/rabbitmq/v1alpha1/${req["workspaceId"]}/storage-config`, {...initReq, method: "POST", body: JSON.stringify(req)})
172
+ }
173
+ static GetStorageConfigConsumers(req: GetStorageConfigConsumersReq, initReq?: fm.InitReq): Promise<GetStorageConfigConsumersResp> {
174
+ return fm.fetchReq<GetStorageConfigConsumersReq, GetStorageConfigConsumersResp>(`/apis/mcamel.io/rabbitmq/v1alpha1/${req["workspaceId"]}/storage-config/${req["name"]}/consumers?${fm.renderURLSearchParams(req, ["workspaceId", "name"])}`, {...initReq, method: "GET"})
175
+ }
176
+ static DeleteStorageConfig(req: DeleteStorageConfigReq, initReq?: fm.InitReq): Promise<DeleteStorageConfigResp> {
177
+ return fm.fetchReq<DeleteStorageConfigReq, DeleteStorageConfigResp>(`/apis/mcamel.io/rabbitmq/v1alpha1/${req["workspaceId"]}/storage-config/${req["cluster"]}/${req["namespace"]}/${req["name"]}`, {...initReq, method: "DELETE"})
178
+ }
179
+ static UpdateStorageConfig(req: CreateStorageConfigReq, initReq?: fm.InitReq): Promise<UpdateStorageConfigResp> {
180
+ return fm.fetchReq<CreateStorageConfigReq, UpdateStorageConfigResp>(`/apis/mcamel.io/rabbitmq/v1alpha1/${req["workspaceId"]}/storage-config/${req["name"]}`, {...initReq, method: "PUT", body: JSON.stringify(req)})
181
+ }
182
+ static GetStorageConfig(req: GetStorageConfigReq, initReq?: fm.InitReq): Promise<GetStorageConfigResp> {
183
+ return fm.fetchReq<GetStorageConfigReq, GetStorageConfigResp>(`/apis/mcamel.io/rabbitmq/v1alpha1/${req["workspaceId"]}/storage-config/${req["name"]}?${fm.renderURLSearchParams(req, ["workspaceId", "name"])}`, {...initReq, method: "GET"})
184
+ }
185
+ static GetStorageConfigList(req: GetStorageConfigListReq, initReq?: fm.InitReq): Promise<GetStorageConfigListResp> {
186
+ return fm.fetchReq<GetStorageConfigListReq, GetStorageConfigListResp>(`/apis/mcamel.io/rabbitmq/v1alpha1/${req["workspaceId"]}/storage-configs?${fm.renderURLSearchParams(req, ["workspaceId"])}`, {...initReq, method: "GET"})
187
+ }
188
+ }
package/template.pb.ts ADDED
@@ -0,0 +1,194 @@
1
+ /* eslint-disable */
2
+ // @ts-nocheck
3
+ /*
4
+ * This file is a generated Typescript file for GRPC Gateway, DO NOT MODIFY
5
+ */
6
+
7
+ import * as CommonCommon from "./common.pb"
8
+ import * as fm from "./fetch.pb"
9
+
10
+ export enum TemplateInstanceType {
11
+ MysqlMasterReplica = "MysqlMasterReplica",
12
+ RedisStandalone = "RedisStandalone",
13
+ RedisFailover = "RedisFailover",
14
+ RedisCluster = "RedisCluster",
15
+ KafkaConfig = "KafkaConfig",
16
+ MysqlMgrConfig = "MysqlMgrConfig",
17
+ MongodbConfig = "MongodbConfig",
18
+ PostgresqlConfig = "PostgresqlConfig",
19
+ RabbitmqConfig = "RabbitmqConfig",
20
+ }
21
+
22
+ export enum GetTemplateConfigReqSortDir {
23
+ ASC = "ASC",
24
+ DESC = "DESC",
25
+ }
26
+
27
+ export enum GetTemplateConfigListReqSortDir {
28
+ ASC = "ASC",
29
+ DESC = "DESC",
30
+ }
31
+
32
+ export enum TemplateConfigItemValueType {
33
+ String = "String",
34
+ SingleSelection = "SingleSelection",
35
+ MultiString = "MultiString",
36
+ }
37
+
38
+ export type UpdateTemplateConfigToItemReq = {
39
+ workspaceId?: number
40
+ conf?: string
41
+ version?: string
42
+ templateInstanceType?: TemplateInstanceType
43
+ }
44
+
45
+ export type UpdateTemplateConfigToItemResp = {
46
+ items?: TemplateConfigItem[]
47
+ }
48
+
49
+ export type GetTemplateConfigVersionsReq = {
50
+ workspaceId?: number
51
+ }
52
+
53
+ export type GetTemplateConfigVersionsResp = {
54
+ versions?: string[]
55
+ }
56
+
57
+ export type GetTemplateConfigStringResp = {
58
+ conf?: string
59
+ fileName?: string
60
+ }
61
+
62
+ export type DeleteTemplateReq = {
63
+ workspaceId?: number
64
+ name?: string
65
+ version?: string
66
+ }
67
+
68
+ export type DeleteTemplateConfigResp = {
69
+ message?: string
70
+ }
71
+
72
+ export type CreateOrUpdateTemplateConfigResp = {
73
+ message?: string
74
+ }
75
+
76
+ export type GetTemplateConfigReq = {
77
+ page?: number
78
+ pageSize?: number
79
+ sortDir?: GetTemplateConfigReqSortDir
80
+ sortBy?: string
81
+ searchKey?: string
82
+ workspaceId?: number
83
+ name?: string
84
+ version?: string
85
+ templateType?: string
86
+ type?: string
87
+ createTimestamp?: string
88
+ templateInstanceType?: TemplateInstanceType
89
+ }
90
+
91
+ export type GetTemplateConfigStringReq = {
92
+ workspaceId?: number
93
+ name?: string
94
+ }
95
+
96
+ export type CreateTemplateConfigResp = {
97
+ message?: string
98
+ }
99
+
100
+ export type UpdateTemplateConfigResp = {
101
+ message?: string
102
+ }
103
+
104
+ export type CreateTemplateConfigReq = {
105
+ workspaceId?: number
106
+ targetName?: string
107
+ targetVersion?: string
108
+ targetType?: string
109
+ targetTemplateType?: string
110
+ targetConf?: string
111
+ fromTemplateName?: string
112
+ targetTemplateInstanceType?: TemplateInstanceType
113
+ }
114
+
115
+ export type UpdateTemplateConfigReq = {
116
+ workspaceId?: number
117
+ name?: string
118
+ version?: string
119
+ type?: string
120
+ templateType?: string
121
+ items?: TemplateConfigItem[]
122
+ conf?: string
123
+ }
124
+
125
+ export type GetTemplateConfigResp = {
126
+ data?: UpdateTemplateConfigReq
127
+ pagination?: CommonCommon.Pagination
128
+ }
129
+
130
+ export type GetTemplateConfigListReq = {
131
+ page?: number
132
+ pageSize?: number
133
+ sortDir?: GetTemplateConfigListReqSortDir
134
+ sortBy?: string
135
+ searchKey?: string
136
+ workspaceId?: number
137
+ version?: string
138
+ templateInstanceType?: TemplateInstanceType
139
+ }
140
+
141
+ export type TemplateConfigItem = {
142
+ name?: string
143
+ default?: string
144
+ current?: string
145
+ value?: string
146
+ isNeedRestart?: boolean
147
+ valueType?: TemplateConfigItemValueType
148
+ valueRemarksZh?: string
149
+ valueRemarksEn?: string
150
+ updateTimestamp?: string
151
+ }
152
+
153
+ export type GetTemplateConfigListResp = {
154
+ items?: GetTemplateConfigReq[]
155
+ pagination?: CommonCommon.Pagination
156
+ }
157
+
158
+ export type GetTemplateInstanceTypeListReq = {
159
+ workspaceId?: number
160
+ }
161
+
162
+ export type GetTemplateInstanceTypeListResp = {
163
+ type?: TemplateInstanceType[]
164
+ }
165
+
166
+ export class Template {
167
+ static GetTemplateConfigList(req: GetTemplateConfigListReq, initReq?: fm.InitReq): Promise<GetTemplateConfigListResp> {
168
+ return fm.fetchReq<GetTemplateConfigListReq, GetTemplateConfigListResp>(`/apis/mcamel.io/rabbitmq/v1alpha1/${req["workspaceId"]}/template_config?${fm.renderURLSearchParams(req, ["workspaceId"])}`, {...initReq, method: "GET"})
169
+ }
170
+ static GetTemplateInstanceTypeList(req: GetTemplateInstanceTypeListReq, initReq?: fm.InitReq): Promise<GetTemplateInstanceTypeListResp> {
171
+ return fm.fetchReq<GetTemplateInstanceTypeListReq, GetTemplateInstanceTypeListResp>(`/apis/mcamel.io/rabbitmq/v1alpha1/${req["workspaceId"]}/template_instance_type?${fm.renderURLSearchParams(req, ["workspaceId"])}`, {...initReq, method: "GET"})
172
+ }
173
+ static GetTemplateConfig(req: GetTemplateConfigReq, initReq?: fm.InitReq): Promise<GetTemplateConfigResp> {
174
+ return fm.fetchReq<GetTemplateConfigReq, GetTemplateConfigResp>(`/apis/mcamel.io/rabbitmq/v1alpha1/${req["workspaceId"]}/template_config/${req["name"]}?${fm.renderURLSearchParams(req, ["workspaceId", "name"])}`, {...initReq, method: "GET"})
175
+ }
176
+ static DeleteTemplateConfig(req: DeleteTemplateReq, initReq?: fm.InitReq): Promise<DeleteTemplateConfigResp> {
177
+ return fm.fetchReq<DeleteTemplateReq, DeleteTemplateConfigResp>(`/apis/mcamel.io/rabbitmq/v1alpha1/${req["workspaceId"]}/template_config/${req["name"]}/${req["version"]}`, {...initReq, method: "DELETE"})
178
+ }
179
+ static CreateTemplateConfig(req: CreateTemplateConfigReq, initReq?: fm.InitReq): Promise<CreateTemplateConfigResp> {
180
+ return fm.fetchReq<CreateTemplateConfigReq, CreateTemplateConfigResp>(`/apis/mcamel.io/rabbitmq/v1alpha1/${req["workspaceId"]}/template_config`, {...initReq, method: "POST", body: JSON.stringify(req)})
181
+ }
182
+ static UpdateTemplateConfig(req: UpdateTemplateConfigReq, initReq?: fm.InitReq): Promise<UpdateTemplateConfigResp> {
183
+ return fm.fetchReq<UpdateTemplateConfigReq, UpdateTemplateConfigResp>(`/apis/mcamel.io/rabbitmq/v1alpha1/${req["workspaceId"]}/template_config`, {...initReq, method: "PUT", body: JSON.stringify(req)})
184
+ }
185
+ static GetTemplateConfigString(req: GetTemplateConfigStringReq, initReq?: fm.InitReq): Promise<GetTemplateConfigStringResp> {
186
+ return fm.fetchReq<GetTemplateConfigStringReq, GetTemplateConfigStringResp>(`/apis/mcamel.io/rabbitmq/v1alpha1/${req["workspaceId"]}/template_config/${req["name"]}/to_string?${fm.renderURLSearchParams(req, ["workspaceId", "name"])}`, {...initReq, method: "GET"})
187
+ }
188
+ static UpdateTemplateConfigToItem(req: UpdateTemplateConfigToItemReq, initReq?: fm.InitReq): Promise<UpdateTemplateConfigToItemResp> {
189
+ return fm.fetchReq<UpdateTemplateConfigToItemReq, UpdateTemplateConfigToItemResp>(`/apis/mcamel.io/rabbitmq/v1alpha1/${req["workspaceId"]}/template_config/to_template`, {...initReq, method: "PUT", body: JSON.stringify(req)})
190
+ }
191
+ static GetTemplateConfigVersions(req: GetTemplateConfigVersionsReq, initReq?: fm.InitReq): Promise<GetTemplateConfigVersionsResp> {
192
+ return fm.fetchReq<GetTemplateConfigVersionsReq, GetTemplateConfigVersionsResp>(`/apis/mcamel.io/rabbitmq/v1alpha1/${req["workspaceId"]}/template_config/versions?${fm.renderURLSearchParams(req, ["workspaceId"])}`, {...initReq, method: "GET"})
193
+ }
194
+ }
package/version.pb.ts CHANGED
@@ -17,6 +17,10 @@ export type GetVersionReply = {
17
17
  buildTime?: string
18
18
  }
19
19
 
20
+ export type HealthzReply = {
21
+ message?: string
22
+ }
23
+
20
24
  export type Empty = {
21
25
  }
22
26
 
@@ -24,4 +28,7 @@ export class Version {
24
28
  static Get(req: Empty, initReq?: fm.InitReq): Promise<GetVersionReply> {
25
29
  return fm.fetchReq<Empty, GetVersionReply>(`/apis/mcamel.io/rabbitmq/v1alpha1/rabbitmq/version?${fm.renderURLSearchParams(req, [])}`, {...initReq, method: "GET"})
26
30
  }
31
+ static Healthz(req: Empty, initReq?: fm.InitReq): Promise<HealthzReply> {
32
+ return fm.fetchReq<Empty, HealthzReply>(`/healthz?${fm.renderURLSearchParams(req, [])}`, {...initReq, method: "GET"})
33
+ }
27
34
  }