@daocloud-proto/mcamel-rabbitmq 0.6.0 → 0.6.1-10

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
@@ -7,6 +7,17 @@
7
7
  import * as CommonCommon from "./common.pb"
8
8
  import * as fm from "./fetch.pb"
9
9
 
10
+ export enum EventType {
11
+ EVENT_TYPE_UNSPECIFIED = "EVENT_TYPE_UNSPECIFIED",
12
+ Normal = "Normal",
13
+ Warning = "Warning",
14
+ }
15
+
16
+ export enum GetEventListReqKind {
17
+ KIND_UNSPECIFIED = "KIND_UNSPECIFIED",
18
+ Pod = "Pod",
19
+ }
20
+
10
21
  export enum GetWorkspaceListReqSortDir {
11
22
  ASC = "ASC",
12
23
  DESC = "DESC",
@@ -17,6 +28,40 @@ export enum GetInsightAgentStatusRespInsightAgentStatus {
17
28
  Install = "Install",
18
29
  }
19
30
 
31
+ export type EventSource = {
32
+ component?: string
33
+ host?: string
34
+ }
35
+
36
+ export type GetEventListReq = {
37
+ cluster?: string
38
+ namespace?: string
39
+ kind?: GetEventListReqKind
40
+ kindName?: string
41
+ page?: number
42
+ pageSize?: number
43
+ type?: EventType[]
44
+ }
45
+
46
+ export type ObjectReference = {
47
+ kind?: string
48
+ name?: string
49
+ }
50
+
51
+ export type GetEventListRespItem = {
52
+ involvedObject?: ObjectReference
53
+ reason?: string
54
+ message?: string
55
+ source?: EventSource
56
+ lastTimestamp?: string
57
+ type?: EventType
58
+ }
59
+
60
+ export type GetEventListResp = {
61
+ items?: GetEventListRespItem[]
62
+ pagination?: CommonCommon.Pagination
63
+ }
64
+
20
65
  export type GetWorkspaceListReq = {
21
66
  page?: number
22
67
  pageSize?: number
@@ -56,7 +101,6 @@ export type GetClusterNamespaceListResp = {
56
101
 
57
102
  export type GetInsightAgentStatusReq = {
58
103
  cluster?: string
59
- mcamelType?: string
60
104
  }
61
105
 
62
106
  export type GetInsightAgentStatusResp = {
@@ -76,4 +120,7 @@ export class Cluster {
76
120
  static GetInsightAgentStatus(req: GetInsightAgentStatusReq, initReq?: fm.InitReq): Promise<GetInsightAgentStatusResp> {
77
121
  return fm.fetchReq<GetInsightAgentStatusReq, GetInsightAgentStatusResp>(`/apis/mcamel.io/rabbitmq/v1alpha1/${req["cluster"]}/insight/status?${fm.renderURLSearchParams(req, ["cluster"])}`, {...initReq, method: "GET"})
78
122
  }
123
+ static GetEventList(req: GetEventListReq, initReq?: fm.InitReq): Promise<GetEventListResp> {
124
+ return fm.fetchReq<GetEventListReq, GetEventListResp>(`/apis/mcamel.io/rabbitmq/v1alpha1/${req["cluster"]}/${req["namespace"]}/events?${fm.renderURLSearchParams(req, ["cluster", "namespace"])}`, {...initReq, method: "GET"})
125
+ }
79
126
  }
package/common.pb.ts CHANGED
@@ -9,6 +9,21 @@ export enum PageInfoReqSortDir {
9
9
  DESC = "DESC",
10
10
  }
11
11
 
12
+ export enum PodCommonPodPhase {
13
+ PHASE_UNSPECIFIED = "PHASE_UNSPECIFIED",
14
+ Unknown = "Unknown",
15
+ Pending = "Pending",
16
+ Running = "Running",
17
+ Succeeded = "Succeeded",
18
+ Failed = "Failed",
19
+ }
20
+
21
+ export enum PodCommonConditionStatus {
22
+ PodConditionStatusUnknown = "PodConditionStatusUnknown",
23
+ PodConditionStatusTrue = "PodConditionStatusTrue",
24
+ PodConditionStatusFalse = "PodConditionStatusFalse",
25
+ }
26
+
12
27
  export type Pagination = {
13
28
  total?: number
14
29
  page?: number
@@ -21,4 +36,26 @@ export type PageInfoReq = {
21
36
  pageSize?: number
22
37
  sortDir?: PageInfoReqSortDir
23
38
  sortBy?: string
39
+ }
40
+
41
+ export type PodCommonCondition = {
42
+ lastTransitionTime?: string
43
+ lastUpdateTime?: string
44
+ message?: string
45
+ reason?: string
46
+ status?: PodCommonConditionStatus
47
+ type?: string
48
+ }
49
+
50
+ export type PodCommon = {
51
+ name?: string
52
+ phase?: PodCommonPodPhase
53
+ ip?: string
54
+ restartCount?: number
55
+ createTimestamp?: string
56
+ cpuUsage?: number
57
+ cpuLimit?: number
58
+ memoryUsage?: number
59
+ memoryLimit?: number
60
+ conditions?: PodCommonCondition[]
24
61
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name":"@daocloud-proto/mcamel-rabbitmq",
3
- "version":"0.6.0",
3
+ "version":"0.6.1-10",
4
4
  "description": "",
5
5
  "main": "index.js",
6
6
  "scripts": {
package/rabbitmq.pb.ts CHANGED
@@ -62,6 +62,21 @@ export enum GetRabbitMqConfRespItemsParamType {
62
62
  defaultPass = "defaultPass",
63
63
  }
64
64
 
65
+ export type GetUsersReq = {
66
+ cluster?: string
67
+ namespace?: string
68
+ name?: string
69
+ }
70
+
71
+ export type GetUsersRespUserItem = {
72
+ username?: string
73
+ password?: string
74
+ }
75
+
76
+ export type GetUsersResp = {
77
+ users?: GetUsersRespUserItem[]
78
+ }
79
+
65
80
  export type GetRabbitMqListReq = {
66
81
  page?: number
67
82
  pageSize?: number
@@ -238,6 +253,7 @@ export type GetRabbitMqNodeListRespData = {
238
253
  memoryUsage?: number
239
254
  memoryLimit?: number
240
255
  createTimestamp?: string
256
+ common?: CommonCommon.PodCommon
241
257
  }
242
258
 
243
259
  export type GetRabbitMqNodeListResp = {
@@ -342,4 +358,7 @@ export class RabbitMq {
342
358
  static DeleteRabbitMqs(req: DeleteRabbitMqsReq, initReq?: fm.InitReq): Promise<DeleteRabbitMqsResp> {
343
359
  return fm.fetchReq<DeleteRabbitMqsReq, DeleteRabbitMqsResp>(`/apis/mcamel.io/rabbitmq/v1alpha1/rabbitmqs`, {...initReq, method: "POST", body: JSON.stringify(req)})
344
360
  }
361
+ static GetRabbitMqUsers(req: GetUsersReq, initReq?: fm.InitReq): Promise<GetUsersResp> {
362
+ return fm.fetchReq<GetUsersReq, GetUsersResp>(`/apis/mcamel.io/rabbitmq/v1alpha1/rabbitmq/${req["cluster"]}/${req["namespace"]}/${req["name"]}/users?${fm.renderURLSearchParams(req, ["cluster", "namespace", "name"])}`, {...initReq, method: "GET"})
363
+ }
345
364
  }