@daocloud-proto/skoala 0.3.3-99 → 0.4.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.
@@ -4,6 +4,21 @@
4
4
  * This file is a generated Typescript file for GRPC Gateway, DO NOT MODIFY
5
5
  */
6
6
 
7
+ export enum OrderBy {
8
+ desc = "desc",
9
+ asc = "asc",
10
+ }
11
+
12
+ export enum SortBy {
13
+ SORT_BY_UNSPECIFIED = "SORT_BY_UNSPECIFIED",
14
+ field_name = "field_name",
15
+ state = "state",
16
+ workspace = "workspace",
17
+ cluster = "cluster",
18
+ namespace = "namespace",
19
+ created_at = "created_at",
20
+ }
21
+
7
22
  export enum Status {
8
23
  STATUS_UNSPECIFIED = "STATUS_UNSPECIFIED",
9
24
  RUNNING = "RUNNING",
@@ -18,7 +33,7 @@ export type Cluster = {
18
33
  }
19
34
 
20
35
  export type Workspace = {
21
- id?: string
36
+ id?: number
22
37
  name?: string
23
38
  }
24
39
 
@@ -39,6 +54,14 @@ export type ListWorkspaceRes = {
39
54
  pagination?: Pagination
40
55
  }
41
56
 
57
+ export type GetWorkspaceReq = {
58
+ workspaceId?: number
59
+ }
60
+
61
+ export type GetWorkspaceRes = {
62
+ workspace?: Workspace
63
+ }
64
+
42
65
  export type ListClusterReq = {
43
66
  workspaceId?: string
44
67
  page?: number
@@ -0,0 +1,260 @@
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 SkoalaApiGeneralV1alpha1Skoala from "../../general/v1alpha1/skoala.pb"
8
+
9
+ type Absent<T, K extends keyof T> = { [k in Exclude<keyof T, K>]?: undefined };
10
+ type OneOf<T> =
11
+ | { [k in keyof T]?: undefined }
12
+ | (
13
+ keyof T extends infer K ?
14
+ (K extends string & keyof T ? { [k in K]: T[K] } & Absent<T, K>
15
+ : never)
16
+ : never);
17
+
18
+ export enum Protocol {
19
+ HTTP = "HTTP",
20
+ HTTPS = "HTTPS",
21
+ }
22
+
23
+ export enum ValueMatchType {
24
+ CONTAIN = "CONTAIN",
25
+ EXACT = "EXACT",
26
+ NOT_CONTAIN = "NOT_CONTAIN",
27
+ NOT_EXACT = "NOT_EXACT",
28
+ PRESENT = "PRESENT",
29
+ NOT_PRESENT = "NOT_PRESENT",
30
+ }
31
+
32
+ export enum HttpMethod {
33
+ GET = "GET",
34
+ POST = "POST",
35
+ DELETE = "DELETE",
36
+ PUT = "PUT",
37
+ PATCH = "PATCH",
38
+ OPTION = "OPTION",
39
+ ALL = "ALL",
40
+ }
41
+
42
+ export enum RedirectResponseCode {
43
+ MOVED_PERMANENTLY = "MOVED_PERMANENTLY",
44
+ FOUND = "FOUND",
45
+ SEE_OTHER = "SEE_OTHER",
46
+ TEMPORARY_REDIRECT = "TEMPORARY_REDIRECT",
47
+ PERMANENT_REDIRECT = "PERMANENT_REDIRECT",
48
+ }
49
+
50
+ export enum RouteType {
51
+ CLUSTRE_SERVER = "CLUSTRE_SERVER",
52
+ DIRECT = "DIRECT",
53
+ REDIRECT = "REDIRECT",
54
+ EXTERNAL = "EXTERNAL",
55
+ REGISTRY = "REGISTRY",
56
+ UNKNOW = "UNKNOW",
57
+ }
58
+
59
+ export enum APIStatus {
60
+ UP = "UP",
61
+ DOWN = "DOWN",
62
+ }
63
+
64
+ export type CreateAPIReq = {
65
+ workspaceId?: string
66
+ gatewayName?: string
67
+ clusterName?: string
68
+ apiConfig?: APIConfig
69
+ }
70
+
71
+ export type UpdateAPIReq = {
72
+ apiName?: string
73
+ workspaceId?: string
74
+ gatewayName?: string
75
+ clusterName?: string
76
+ apiConfig?: APIConfig
77
+ }
78
+
79
+ export type CreateAPIRes = {
80
+ }
81
+
82
+ export type UpdateAPIRes = {
83
+ }
84
+
85
+ export type DeleteAPIRes = {
86
+ }
87
+
88
+ export type GetAPIReq = {
89
+ workspaceId?: string
90
+ clusterName?: string
91
+ gatewayName?: string
92
+ apiName?: string
93
+ }
94
+
95
+ export type DeleteAPIReq = {
96
+ workspaceId?: string
97
+ clusterName?: string
98
+ gatewayName?: string
99
+ apiName?: string
100
+ }
101
+
102
+ export type GetAPIRes = {
103
+ apiName?: string
104
+ apiStatus?: APIStatus
105
+ fqdn?: string
106
+ matchRule?: MatchRule
107
+ targetService?: TargetService
108
+ }
109
+
110
+ export type TargetService = {
111
+ serviceList?: ServiceDetail[]
112
+ }
113
+
114
+ export type ServiceDetail = {
115
+ clusterName?: string
116
+ k8SNamespaceName?: string
117
+ serviceName?: string
118
+ registrationId?: string
119
+ address?: string
120
+ protocol?: Protocol
121
+ port?: number
122
+ weight?: string
123
+ nacosNamespaceId?: string
124
+ groupName?: string
125
+ routeType?: RouteType
126
+ path?: string
127
+ statusCode?: number
128
+ }
129
+
130
+
131
+ type BaseAPIConfig = {
132
+ apiName?: string
133
+ virtualhost?: Virtualhost
134
+ matchRule?: MatchRule
135
+ enabled?: boolean
136
+ }
137
+
138
+ export type APIConfig = BaseAPIConfig
139
+ & OneOf<{ route: RouteAction; redirect: RedirectAction; directResponse: DirectResponse }>
140
+
141
+ export type Virtualhost = {
142
+ fqdn?: string
143
+ protocol?: Protocol
144
+ }
145
+
146
+ export type Certificate = {
147
+ namespace?: string
148
+ }
149
+
150
+
151
+ type BaseMatchRule = {
152
+ httpMethod?: HttpMethod[]
153
+ headers?: HeaderRule[]
154
+ }
155
+
156
+ export type MatchRule = BaseMatchRule
157
+ & OneOf<{ path: string; prefix: string }>
158
+
159
+
160
+ type BaseHeaderRule = {
161
+ name?: string
162
+ }
163
+
164
+ export type HeaderRule = BaseHeaderRule
165
+ & OneOf<{ contains: string; exact: string; notContains: string; notExact: string; present: boolean; notPresent: boolean }>
166
+
167
+ export type RouteAction = {
168
+ routeService?: RouteService[]
169
+ }
170
+
171
+
172
+ type BaseRouteService = {
173
+ protocol?: Protocol
174
+ port?: number
175
+ weight?: number
176
+ }
177
+
178
+ export type RouteService = BaseRouteService
179
+ & OneOf<{ kubernetesService: KubernetesService; registryService: RegistryService; externalService: ExternalService }>
180
+
181
+ export type KubernetesService = {
182
+ clusterId?: string
183
+ clusterName?: string
184
+ namespaceName?: string
185
+ serviceName?: string
186
+ address?: string
187
+ }
188
+
189
+ export type ExternalService = {
190
+ serviceName?: string
191
+ address?: string
192
+ }
193
+
194
+
195
+ type BaseRegistryService = {
196
+ registrationId?: string
197
+ }
198
+
199
+ export type RegistryService = BaseRegistryService
200
+ & OneOf<{ eurekaService: EurekaService; nacosService: NacosService; zookeeperService: ZookeeperService; kubernetesService: KubernetesService }>
201
+
202
+ export type EurekaService = {
203
+ address?: string
204
+ serviceName?: string
205
+ }
206
+
207
+ export type NacosService = {
208
+ address?: string
209
+ serviceName?: string
210
+ namespaceId?: string
211
+ groupName?: string
212
+ }
213
+
214
+ export type ZookeeperService = {
215
+ address?: string
216
+ serviceName?: string
217
+ }
218
+
219
+ export type MeshService = {
220
+ instanceId?: string
221
+ }
222
+
223
+ export type ApplicationService = {
224
+ }
225
+
226
+ export type RedirectAction = {
227
+ hostname?: string
228
+ path?: string
229
+ port?: number
230
+ statusCode?: number
231
+ protocol?: Protocol
232
+ }
233
+
234
+ export type DirectResponse = {
235
+ statusCode?: number
236
+ body?: string
237
+ }
238
+
239
+ export type APIListReq = {
240
+ workspaceId?: string
241
+ clusterName?: string
242
+ gatewayName?: string
243
+ page?: number
244
+ pageSize?: number
245
+ }
246
+
247
+ export type APIListRes = {
248
+ api?: APIInfo[]
249
+ pagination?: SkoalaApiGeneralV1alpha1Skoala.Pagination
250
+ }
251
+
252
+ export type APIInfo = {
253
+ apiName?: string
254
+ fqdn?: string
255
+ method?: HttpMethod[]
256
+ requestPath?: string
257
+ routeType?: RouteType
258
+ apiStatus?: APIStatus
259
+ updatedAt?: string
260
+ }
@@ -57,14 +57,7 @@ export type ListClusterGatewayReq = {
57
57
  clusterName?: string
58
58
  page?: number
59
59
  pageSize?: number
60
- }
61
-
62
- export type ListNamespaceGatewayReq = {
63
- workspaceId?: number
64
- clusterName?: string
65
- namespaceName?: string
66
- page?: number
67
- pageSize?: number
60
+ filter?: string
68
61
  }
69
62
 
70
63
  export type ListGatewayRes = {
@@ -3,26 +3,102 @@
3
3
  /*
4
4
  * This file is a generated Typescript file for GRPC Gateway, DO NOT MODIFY
5
5
  */
6
+
7
+ import * as SkoalaApiGeneralV1alpha1Skoala from "../../general/v1alpha1/skoala.pb"
8
+
9
+ export enum NacosStatus {
10
+ STATUS_UNSPECIFIED = "STATUS_UNSPECIFIED",
11
+ Running = "Running",
12
+ Creating = "Creating",
13
+ Failed = "Failed",
14
+ Scaling = "Scaling",
15
+ }
16
+
17
+ export enum NacosConfigType {
18
+ TYPE_UNSPECIFIED = "TYPE_UNSPECIFIED",
19
+ standalone = "standalone",
20
+ cluster = "cluster",
21
+ }
22
+
23
+ export enum NacosConfigServiceType {
24
+ SERVICE_TYPE_UNSPECIFIED = "SERVICE_TYPE_UNSPECIFIED",
25
+ NodePort = "NodePort",
26
+ ClusterIP = "ClusterIP",
27
+ LoadBalancer = "LoadBalancer",
28
+ }
29
+
6
30
  export type ListNacosReq = {
7
31
  workspaceId?: string
32
+ clusterName?: string
33
+ namespaceName?: string
8
34
  page?: number
35
+ pageSize?: number
9
36
  }
10
37
 
11
38
  export type ListNacosRes = {
39
+ items?: Nacos[]
40
+ pagination?: SkoalaApiGeneralV1alpha1Skoala.Pagination
41
+ }
42
+
43
+ export type Nacos = {
44
+ workspaceId?: string
45
+ clusterName?: string
46
+ nacosName?: string
47
+ namespaceName?: string
48
+ type?: NacosConfigType
49
+ serviceType?: NacosConfigServiceType
50
+ nodePort?: number
51
+ status?: NacosStatus
52
+ replicas?: number
53
+ image?: string
54
+ version?: string
55
+ database?: NacosDatabase
56
+ resource?: NacosResource
57
+ condition?: NacosCondition[]
58
+ createAt?: string
59
+ }
60
+
61
+ export type NacosDatabase = {
62
+ type?: string
63
+ host?: string
64
+ port?: string
65
+ db?: string
66
+ user?: string
67
+ }
68
+
69
+ export type NacosResource = {
70
+ limits?: {[key: string]: string}
71
+ request?: {[key: string]: string}
72
+ }
73
+
74
+ export type NacosCondition = {
75
+ type?: string
76
+ status?: string
77
+ reason?: string
78
+ message?: string
79
+ instance?: string
80
+ hostIP?: string
81
+ podName?: string
82
+ nodeName?: string
12
83
  }
13
84
 
14
85
  export type GetNacosReq = {
15
86
  workspaceId?: string
87
+ clusterName?: string
16
88
  nacosName?: string
89
+ namespaceName?: string
17
90
  }
18
91
 
19
92
  export type GetNacosRes = {
93
+ nacos?: Nacos
20
94
  }
21
95
 
22
96
  export type UpdateNacosReq = {
23
97
  workspaceId?: string
98
+ clusterName?: string
24
99
  nacosName?: string
25
- config?: string
100
+ namespaceName?: string
101
+ config?: NacosConfig
26
102
  }
27
103
 
28
104
  export type UpdateNacosRes = {
@@ -30,7 +106,11 @@ export type UpdateNacosRes = {
30
106
 
31
107
  export type CreateNacosReq = {
32
108
  workspaceId?: string
33
- gatewayName?: string
109
+ clusterName?: string
110
+ nacosName?: string
111
+ namespaceName?: string
112
+ createNamespace?: boolean
113
+ config?: NacosConfig
34
114
  }
35
115
 
36
116
  export type CreateNacosRes = {
@@ -38,8 +118,30 @@ export type CreateNacosRes = {
38
118
 
39
119
  export type DeleteNacosReq = {
40
120
  workspaceId?: string
121
+ clusterName?: string
41
122
  nacosName?: string
123
+ namespaceName?: string
42
124
  }
43
125
 
44
126
  export type DeleteNacosRes = {
127
+ }
128
+
129
+ export type NacosConfig = {
130
+ type?: NacosConfigType
131
+ version?: string
132
+ replicas?: number
133
+ cpu?: string
134
+ memory?: string
135
+ serviceType?: NacosConfigServiceType
136
+ nodePort?: string
137
+ databaseEnabled?: boolean
138
+ databaseParam?: DatabaseParam
139
+ }
140
+
141
+ export type DatabaseParam = {
142
+ host?: string
143
+ port?: string
144
+ username?: string
145
+ password?: string
146
+ db?: string
45
147
  }
@@ -3,42 +3,84 @@
3
3
  /*
4
4
  * This file is a generated Typescript file for GRPC Gateway, DO NOT MODIFY
5
5
  */
6
+
7
+ import * as SkoalaApiGeneralV1alpha1Skoala from "../../general/v1alpha1/skoala.pb"
6
8
  export type ListSentinelReq = {
7
- workspaceId?: string
9
+ workspace?: string
10
+ cluster?: string
11
+ namespace?: string
8
12
  page?: number
13
+ pageSize?: number
9
14
  }
10
15
 
11
16
  export type ListSentinelRes = {
17
+ items?: Sentinel[]
18
+ pagination?: SkoalaApiGeneralV1alpha1Skoala.Pagination
19
+ }
20
+
21
+ export type Sentinel = {
22
+ workspace?: string
23
+ cluster?: string
24
+ namespace?: string
25
+ name?: string
26
+ config?: SentinelConfig
12
27
  }
13
28
 
14
29
  export type GetSentinelReq = {
15
- workspaceId?: string
16
- sentinelName?: string
30
+ workspace?: string
31
+ cluster?: string
32
+ namespace?: string
33
+ name?: string
17
34
  }
18
35
 
19
36
  export type GetSentinelRes = {
37
+ sentinel?: Sentinel
20
38
  }
21
39
 
22
40
  export type UpdateSentinelReq = {
23
- workspaceId?: string
24
- sentinelName?: string
25
- config?: string
41
+ workspace?: string
42
+ cluster?: string
43
+ namespace?: string
44
+ name?: string
45
+ nacosAddress?: string
46
+ config?: SentinelConfig
26
47
  }
27
48
 
28
49
  export type UpdateSentinelRes = {
29
50
  }
30
51
 
52
+ export type Resources = {
53
+ cpuRequests?: string
54
+ cpuLimits?: string
55
+ memoryRequests?: string
56
+ memoryLimits?: string
57
+ }
58
+
59
+ export type SentinelConfig = {
60
+ type?: string
61
+ port?: number
62
+ nodePort?: number
63
+ resources?: Resources
64
+ image?: string
65
+ }
66
+
31
67
  export type CreateSentinelReq = {
32
- workspaceId?: string
33
- gatewayName?: string
68
+ workspace?: string
69
+ cluster?: string
70
+ namespace?: string
71
+ name?: string
72
+ nacosAddress?: string
73
+ config?: SentinelConfig
34
74
  }
35
75
 
36
76
  export type CreateSentinelRes = {
37
77
  }
38
78
 
39
79
  export type DeleteSentinelReq = {
40
- workspaceId?: string
41
- sentinelName?: string
80
+ workspace?: string
81
+ cluster?: string
82
+ namespace?: string
83
+ name?: string
42
84
  }
43
85
 
44
86
  export type DeleteSentinelRes = {
@@ -8,6 +8,13 @@ import * as InsightIoApiMetricV1alpha1Metric from "../../../metric/v1alpha1/metr
8
8
  export type Insight = {
9
9
  serviceDetail?: InsightValue
10
10
  serviceMetrics?: InsightMetrics
11
+ instanceMonitorMetrics?: MonitorMetrics
12
+ }
13
+
14
+ export type InstanceInsight = {
15
+ instanceDetail?: InsightValue
16
+ instanceMetrics?: InsightMetrics
17
+ instanceMonitorMetrics?: MonitorMetrics
11
18
  }
12
19
 
13
20
  export type InsightValue = {
@@ -27,4 +34,17 @@ export type InsightMetrics = {
27
34
  errorsRateMetrics?: InsightIoApiMetricV1alpha1Metric.SampleStream[]
28
35
  successTotalCallsMetrics?: InsightIoApiMetricV1alpha1Metric.SampleStream[]
29
36
  errorTotalCallsMetrics?: InsightIoApiMetricV1alpha1Metric.SampleStream[]
37
+ }
38
+
39
+ export type MonitorMetrics = {
40
+ cpuRequest?: InsightIoApiMetricV1alpha1Metric.SampleStream[]
41
+ cpuLimit?: InsightIoApiMetricV1alpha1Metric.SampleStream[]
42
+ cpuUsage?: InsightIoApiMetricV1alpha1Metric.SampleStream[]
43
+ memoryRequest?: InsightIoApiMetricV1alpha1Metric.SampleStream[]
44
+ memoryLimit?: InsightIoApiMetricV1alpha1Metric.SampleStream[]
45
+ memoryUsage?: InsightIoApiMetricV1alpha1Metric.SampleStream[]
46
+ diskRead?: InsightIoApiMetricV1alpha1Metric.SampleStream[]
47
+ diskWrite?: InsightIoApiMetricV1alpha1Metric.SampleStream[]
48
+ netBytesReceived?: InsightIoApiMetricV1alpha1Metric.SampleStream[]
49
+ netBytesTransmitted?: InsightIoApiMetricV1alpha1Metric.SampleStream[]
30
50
  }
@@ -5,6 +5,7 @@
5
5
  */
6
6
 
7
7
  import * as SkoalaApiGeneralV1alpha1Skoala from "../../general/v1alpha1/skoala.pb"
8
+ import * as SkoalaApiIntegratedV1alpha1Insight from "./insight.pb"
8
9
 
9
10
  export enum InstanceStatus {
10
11
  STATUS_UNSPECIFIED = "STATUS_UNSPECIFIED",
@@ -23,6 +24,7 @@ export type Instance = {
23
24
  metadata?: {[key: string]: string}
24
25
  detail?: {[key: string]: string}
25
26
  updateAt?: string
27
+ insight?: SkoalaApiIntegratedV1alpha1Insight.InstanceInsight
26
28
  }
27
29
 
28
30
  export type ListInstanceReq = {
@@ -68,6 +68,7 @@ export type GetRegistryRes = {
68
68
  export type UpdateRegistryReq = {
69
69
  workspaceId?: string
70
70
  registryId?: string
71
+ extId?: string
71
72
  name?: string
72
73
  type?: string
73
74
  addresses?: string[]
@@ -82,6 +83,7 @@ export type UpdateRegistryRes = {
82
83
  export type CreateRegistryReq = {
83
84
  workspaceId?: string
84
85
  name?: string
86
+ extId?: string
85
87
  type?: string
86
88
  addresses?: string[]
87
89
  namespaces?: Namespace[]
@@ -8,6 +8,7 @@ import * as fm from "../../../fetch.pb"
8
8
  import * as GoogleProtobufEmpty from "../../../google/protobuf/empty.pb"
9
9
  import * as SkoalaApiGeneralV1alpha1Skoala from "../../general/v1alpha1/skoala.pb"
10
10
  import * as SkoalaApiGeneralV1alpha1Version from "../../general/v1alpha1/version.pb"
11
+ import * as SkoalaApiHostedV1alpha1Api from "../../hosted/v1alpha1/api.pb"
11
12
  import * as SkoalaApiHostedV1alpha1Gateway from "../../hosted/v1alpha1/gateway.pb"
12
13
  import * as SkoalaApiHostedV1alpha1Nacos from "../../hosted/v1alpha1/nacos.pb"
13
14
  import * as SkoalaApiHostedV1alpha1Sentinel from "../../hosted/v1alpha1/sentinel.pb"
@@ -34,6 +35,9 @@ export class Skoala {
34
35
  static ListWorkspace(req: SkoalaApiGeneralV1alpha1Skoala.ListWorkspaceReq, initReq?: fm.InitReq): Promise<SkoalaApiGeneralV1alpha1Skoala.ListWorkspaceRes> {
35
36
  return fm.fetchReq<SkoalaApiGeneralV1alpha1Skoala.ListWorkspaceReq, SkoalaApiGeneralV1alpha1Skoala.ListWorkspaceRes>(`/apis/skoala.io/v1alpha1/workspaces?${fm.renderURLSearchParams(req, [])}`, {...initReq, method: "GET"})
36
37
  }
38
+ static GetWorkspace(req: SkoalaApiGeneralV1alpha1Skoala.GetWorkspaceReq, initReq?: fm.InitReq): Promise<SkoalaApiGeneralV1alpha1Skoala.GetWorkspaceRes> {
39
+ return fm.fetchReq<SkoalaApiGeneralV1alpha1Skoala.GetWorkspaceReq, SkoalaApiGeneralV1alpha1Skoala.GetWorkspaceRes>(`/apis/skoala.io/v1alpha1/workspaces/${req["workspaceId"]}?${fm.renderURLSearchParams(req, ["workspaceId"])}`, {...initReq, method: "GET"})
40
+ }
37
41
  }
38
42
  export class Registry {
39
43
  static List(req: SkoalaApiIntegratedV1alpha1Registry.ListRegistryReq, initReq?: fm.InitReq): Promise<SkoalaApiIntegratedV1alpha1Registry.ListRegistryRes> {
@@ -81,31 +85,31 @@ export class Nacos {
81
85
  static Get(req: SkoalaApiHostedV1alpha1Nacos.GetNacosReq, initReq?: fm.InitReq): Promise<SkoalaApiHostedV1alpha1Nacos.GetNacosRes> {
82
86
  return fm.fetchReq<SkoalaApiHostedV1alpha1Nacos.GetNacosReq, SkoalaApiHostedV1alpha1Nacos.GetNacosRes>(`/apis/hive.skoala.io/v1alpha1/workspaces/${req["workspaceId"]}/nacoses/${req["nacosName"]}?${fm.renderURLSearchParams(req, ["workspaceId", "nacosName"])}`, {...initReq, method: "GET"})
83
87
  }
84
- static Create(req: SkoalaApiHostedV1alpha1Nacos.CreateNacosReq, initReq?: fm.InitReq): Promise<SkoalaApiHostedV1alpha1Nacos.CreateNacosRes> {
85
- return fm.fetchReq<SkoalaApiHostedV1alpha1Nacos.CreateNacosReq, SkoalaApiHostedV1alpha1Nacos.CreateNacosRes>(`/apis/hive.skoala.io/v1alpha1/workspaces/${req["workspaceId"]}/nacoses`, {...initReq, method: "POST", body: JSON.stringify(req, fm.replacer)})
88
+ static Create(req: SkoalaApiHostedV1alpha1Nacos.CreateNacosReq, initReq?: fm.InitReq): Promise<GoogleProtobufEmpty.Empty> {
89
+ return fm.fetchReq<SkoalaApiHostedV1alpha1Nacos.CreateNacosReq, GoogleProtobufEmpty.Empty>(`/apis/hive.skoala.io/v1alpha1/workspaces/${req["workspaceId"]}/nacoses`, {...initReq, method: "POST", body: JSON.stringify(req, fm.replacer)})
86
90
  }
87
- static Update(req: SkoalaApiHostedV1alpha1Nacos.UpdateNacosReq, initReq?: fm.InitReq): Promise<SkoalaApiHostedV1alpha1Nacos.UpdateNacosRes> {
88
- return fm.fetchReq<SkoalaApiHostedV1alpha1Nacos.UpdateNacosReq, SkoalaApiHostedV1alpha1Nacos.UpdateNacosRes>(`/apis/hive.skoala.io/v1alpha1/workspaces/${req["workspaceId"]}/nacoses/${req["nacosName"]}`, {...initReq, method: "PUT", body: JSON.stringify(req, fm.replacer)})
91
+ static Update(req: SkoalaApiHostedV1alpha1Nacos.UpdateNacosReq, initReq?: fm.InitReq): Promise<GoogleProtobufEmpty.Empty> {
92
+ return fm.fetchReq<SkoalaApiHostedV1alpha1Nacos.UpdateNacosReq, GoogleProtobufEmpty.Empty>(`/apis/hive.skoala.io/v1alpha1/workspaces/${req["workspaceId"]}/nacoses/${req["nacosName"]}`, {...initReq, method: "PUT", body: JSON.stringify(req, fm.replacer)})
89
93
  }
90
- static Delete(req: SkoalaApiHostedV1alpha1Nacos.DeleteNacosReq, initReq?: fm.InitReq): Promise<SkoalaApiHostedV1alpha1Nacos.DeleteNacosRes> {
91
- return fm.fetchReq<SkoalaApiHostedV1alpha1Nacos.DeleteNacosReq, SkoalaApiHostedV1alpha1Nacos.DeleteNacosRes>(`/apis/hive.skoala.io/v1alpha1/workspaces/${req["workspaceId"]}/nacoses/${req["nacosName"]}`, {...initReq, method: "DELETE"})
94
+ static Delete(req: SkoalaApiHostedV1alpha1Nacos.DeleteNacosReq, initReq?: fm.InitReq): Promise<GoogleProtobufEmpty.Empty> {
95
+ return fm.fetchReq<SkoalaApiHostedV1alpha1Nacos.DeleteNacosReq, GoogleProtobufEmpty.Empty>(`/apis/hive.skoala.io/v1alpha1/workspaces/${req["workspaceId"]}/nacoses/${req["nacosName"]}`, {...initReq, method: "DELETE"})
92
96
  }
93
97
  }
94
98
  export class Sentinel {
95
99
  static List(req: SkoalaApiHostedV1alpha1Sentinel.ListSentinelReq, initReq?: fm.InitReq): Promise<SkoalaApiHostedV1alpha1Sentinel.ListSentinelRes> {
96
- return fm.fetchReq<SkoalaApiHostedV1alpha1Sentinel.ListSentinelReq, SkoalaApiHostedV1alpha1Sentinel.ListSentinelRes>(`/apis/hive.skoala.io/v1alpha1/workspaces/${req["workspaceId"]}/sentinels?${fm.renderURLSearchParams(req, ["workspaceId"])}`, {...initReq, method: "GET"})
100
+ return fm.fetchReq<SkoalaApiHostedV1alpha1Sentinel.ListSentinelReq, SkoalaApiHostedV1alpha1Sentinel.ListSentinelRes>(`/apis/hive.skoala.io/v1alpha1/workspaces/${req["workspace"]}/clusters/${req["cluster"]}/namespaces/${req["namespace"]}/sentinels?${fm.renderURLSearchParams(req, ["workspace", "cluster", "namespace"])}`, {...initReq, method: "GET"})
97
101
  }
98
- static Get(req: SkoalaApiHostedV1alpha1Sentinel.GetSentinelReq, initReq?: fm.InitReq): Promise<SkoalaApiHostedV1alpha1Sentinel.GetSentinelRes> {
99
- return fm.fetchReq<SkoalaApiHostedV1alpha1Sentinel.GetSentinelReq, SkoalaApiHostedV1alpha1Sentinel.GetSentinelRes>(`/apis/hive.skoala.io/v1alpha1/workspaces/${req["workspaceId"]}/sentinels/${req["sentinelName"]}?${fm.renderURLSearchParams(req, ["workspaceId", "sentinelName"])}`, {...initReq, method: "GET"})
102
+ static Get(req: SkoalaApiHostedV1alpha1Sentinel.GetSentinelReq, initReq?: fm.InitReq): Promise<SkoalaApiHostedV1alpha1Sentinel.Sentinel> {
103
+ return fm.fetchReq<SkoalaApiHostedV1alpha1Sentinel.GetSentinelReq, SkoalaApiHostedV1alpha1Sentinel.Sentinel>(`/apis/hive.skoala.io/v1alpha1/workspaces/${req["workspace"]}/clusters/${req["cluster"]}/namespaces/${req["namespace"]}/sentinels/${req["name"]}?${fm.renderURLSearchParams(req, ["workspace", "cluster", "namespace", "name"])}`, {...initReq, method: "GET"})
100
104
  }
101
105
  static Create(req: SkoalaApiHostedV1alpha1Sentinel.CreateSentinelReq, initReq?: fm.InitReq): Promise<SkoalaApiHostedV1alpha1Sentinel.CreateSentinelRes> {
102
- return fm.fetchReq<SkoalaApiHostedV1alpha1Sentinel.CreateSentinelReq, SkoalaApiHostedV1alpha1Sentinel.CreateSentinelRes>(`/apis/hive.skoala.io/v1alpha1/workspaces/${req["workspaceId"]}/sentinels`, {...initReq, method: "POST", body: JSON.stringify(req, fm.replacer)})
106
+ return fm.fetchReq<SkoalaApiHostedV1alpha1Sentinel.CreateSentinelReq, SkoalaApiHostedV1alpha1Sentinel.CreateSentinelRes>(`/apis/hive.skoala.io/v1alpha1/workspaces/${req["workspace"]}/clusters/${req["cluster"]}/namespaces/${req["namespace"]}/sentinels`, {...initReq, method: "POST", body: JSON.stringify(req, fm.replacer)})
103
107
  }
104
108
  static Update(req: SkoalaApiHostedV1alpha1Sentinel.UpdateSentinelReq, initReq?: fm.InitReq): Promise<SkoalaApiHostedV1alpha1Sentinel.UpdateSentinelRes> {
105
- return fm.fetchReq<SkoalaApiHostedV1alpha1Sentinel.UpdateSentinelReq, SkoalaApiHostedV1alpha1Sentinel.UpdateSentinelRes>(`/apis/hive.skoala.io/v1alpha1/workspaces/${req["workspaceId"]}/sentinels/${req["sentinelName"]}`, {...initReq, method: "PUT", body: JSON.stringify(req, fm.replacer)})
109
+ return fm.fetchReq<SkoalaApiHostedV1alpha1Sentinel.UpdateSentinelReq, SkoalaApiHostedV1alpha1Sentinel.UpdateSentinelRes>(`/apis/hive.skoala.io/v1alpha1/workspaces/${req["workspace"]}/clusters/${req["cluster"]}/namespaces/${req["namespace"]}/sentinels/${req["name"]}`, {...initReq, method: "PUT", body: JSON.stringify(req, fm.replacer)})
106
110
  }
107
111
  static Delete(req: SkoalaApiHostedV1alpha1Sentinel.DeleteSentinelReq, initReq?: fm.InitReq): Promise<SkoalaApiHostedV1alpha1Sentinel.DeleteSentinelRes> {
108
- return fm.fetchReq<SkoalaApiHostedV1alpha1Sentinel.DeleteSentinelReq, SkoalaApiHostedV1alpha1Sentinel.DeleteSentinelRes>(`/apis/hive.skoala.io/v1alpha1/workspaces/${req["workspaceId"]}/sentinels/${req["sentinelName"]}`, {...initReq, method: "DELETE"})
112
+ return fm.fetchReq<SkoalaApiHostedV1alpha1Sentinel.DeleteSentinelReq, SkoalaApiHostedV1alpha1Sentinel.DeleteSentinelRes>(`/apis/hive.skoala.io/v1alpha1/workspaces/${req["workspace"]}/clusters/${req["cluster"]}/namespaces/${req["namespace"]}/sentinels/${req["name"]}`, {...initReq, method: "DELETE"})
109
113
  }
110
114
  }
111
115
  export class Gateway {
@@ -115,9 +119,6 @@ export class Gateway {
115
119
  static ListClusterGateway(req: SkoalaApiHostedV1alpha1Gateway.ListClusterGatewayReq, initReq?: fm.InitReq): Promise<SkoalaApiHostedV1alpha1Gateway.ListGatewayRes> {
116
120
  return fm.fetchReq<SkoalaApiHostedV1alpha1Gateway.ListClusterGatewayReq, SkoalaApiHostedV1alpha1Gateway.ListGatewayRes>(`/apis/sesame.skoala.io/v1alpha1/workspaces/${req["workspaceId"]}/clusters/${req["clusterName"]}/gateways?${fm.renderURLSearchParams(req, ["workspaceId", "clusterName"])}`, {...initReq, method: "GET"})
117
121
  }
118
- static ListNamespaceGateway(req: SkoalaApiHostedV1alpha1Gateway.ListNamespaceGatewayReq, initReq?: fm.InitReq): Promise<SkoalaApiHostedV1alpha1Gateway.ListGatewayRes> {
119
- return fm.fetchReq<SkoalaApiHostedV1alpha1Gateway.ListNamespaceGatewayReq, SkoalaApiHostedV1alpha1Gateway.ListGatewayRes>(`/apis/sesame.skoala.io/v1alpha1/workspaces/${req["workspaceId"]}/clusters/${req["clusterName"]}/namespaces/${req["namespaceName"]}/gateways?${fm.renderURLSearchParams(req, ["workspaceId", "clusterName", "namespaceName"])}`, {...initReq, method: "GET"})
120
- }
121
122
  static Get(req: SkoalaApiHostedV1alpha1Gateway.GetGatewayReq, initReq?: fm.InitReq): Promise<SkoalaApiHostedV1alpha1Gateway.GetGatewayRes> {
122
123
  return fm.fetchReq<SkoalaApiHostedV1alpha1Gateway.GetGatewayReq, SkoalaApiHostedV1alpha1Gateway.GetGatewayRes>(`/apis/sesame.skoala.io/v1alpha1/workspaces/${req["workspaceId"]}/clusters/${req["clusterName"]}/namespaces/${req["namespaceName"]}/gateways/${req["gatewayName"]}?${fm.renderURLSearchParams(req, ["workspaceId", "clusterName", "namespaceName", "gatewayName"])}`, {...initReq, method: "GET"})
123
124
  }
@@ -136,4 +137,19 @@ export class Gateway {
136
137
  static GetGatewayStatus(req: SkoalaApiHostedV1alpha1Gateway.GetGatewayStatusReq, initReq?: fm.InitReq): Promise<SkoalaApiHostedV1alpha1Gateway.GetGatewayStatusRes> {
137
138
  return fm.fetchReq<SkoalaApiHostedV1alpha1Gateway.GetGatewayStatusReq, SkoalaApiHostedV1alpha1Gateway.GetGatewayStatusRes>(`/apis/sesame.skoala.io/v1alpha1/workspaces/${req["workspaceId"]}/clusters/${req["clusterName"]}/namespaces/${req["namespaceName"]}/gateways/${req["gatewayName"]}/status?${fm.renderURLSearchParams(req, ["workspaceId", "clusterName", "namespaceName", "gatewayName"])}`, {...initReq, method: "GET"})
138
139
  }
140
+ static CreateAPI(req: SkoalaApiHostedV1alpha1Api.CreateAPIReq, initReq?: fm.InitReq): Promise<SkoalaApiHostedV1alpha1Api.CreateAPIRes> {
141
+ return fm.fetchReq<SkoalaApiHostedV1alpha1Api.CreateAPIReq, SkoalaApiHostedV1alpha1Api.CreateAPIRes>(`/apis/sesame.skoala.io/v1alpha1/workspaces/${req["workspaceId"]}/clusters/${req["clusterName"]}/gateways/${req["gatewayName"]}/apis`, {...initReq, method: "POST", body: JSON.stringify(req, fm.replacer)})
142
+ }
143
+ static ListAPI(req: SkoalaApiHostedV1alpha1Api.APIListReq, initReq?: fm.InitReq): Promise<SkoalaApiHostedV1alpha1Api.APIListRes> {
144
+ return fm.fetchReq<SkoalaApiHostedV1alpha1Api.APIListReq, SkoalaApiHostedV1alpha1Api.APIListRes>(`/apis/sesame.skoala.io/v1alpha1/workspaces/${req["workspaceId"]}/clusters/${req["clusterName"]}/gateways/${req["gatewayName"]}/apis?${fm.renderURLSearchParams(req, ["workspaceId", "clusterName", "gatewayName"])}`, {...initReq, method: "GET"})
145
+ }
146
+ static GetAPI(req: SkoalaApiHostedV1alpha1Api.GetAPIReq, initReq?: fm.InitReq): Promise<SkoalaApiHostedV1alpha1Api.GetAPIRes> {
147
+ return fm.fetchReq<SkoalaApiHostedV1alpha1Api.GetAPIReq, SkoalaApiHostedV1alpha1Api.GetAPIRes>(`/apis/sesame.skoala.io/v1alpha1/workspaces/${req["workspaceId"]}/clusters/${req["clusterName"]}/gateways/${req["gatewayName"]}/apis/${req["apiName"]}?${fm.renderURLSearchParams(req, ["workspaceId", "clusterName", "gatewayName", "apiName"])}`, {...initReq, method: "GET"})
148
+ }
149
+ static DeleteAPI(req: SkoalaApiHostedV1alpha1Api.DeleteAPIReq, initReq?: fm.InitReq): Promise<SkoalaApiHostedV1alpha1Api.DeleteAPIRes> {
150
+ return fm.fetchReq<SkoalaApiHostedV1alpha1Api.DeleteAPIReq, SkoalaApiHostedV1alpha1Api.DeleteAPIRes>(`/apis/sesame.skoala.io/v1alpha1/workspaces/${req["workspaceId"]}/clusters/${req["clusterName"]}/gateways/${req["gatewayName"]}/apis/${req["apiName"]}`, {...initReq, method: "DELETE"})
151
+ }
152
+ static UpdateAPI(req: SkoalaApiHostedV1alpha1Api.UpdateAPIReq, initReq?: fm.InitReq): Promise<SkoalaApiHostedV1alpha1Api.UpdateAPIRes> {
153
+ return fm.fetchReq<SkoalaApiHostedV1alpha1Api.UpdateAPIReq, SkoalaApiHostedV1alpha1Api.UpdateAPIRes>(`/apis/sesame.skoala.io/v1alpha1/workspaces/${req["workspaceId"]}/clusters/${req["clusterName"]}/gateways/${req["gatewayName"]}/apis/${req["apiName"]}`, {...initReq, method: "PUT", body: JSON.stringify(req, fm.replacer)})
154
+ }
139
155
  }
@@ -63,7 +63,7 @@ export type RuleSummary = {
63
63
  ruleId?: string
64
64
  ruleName?: string
65
65
  severity?: Severity
66
- cluster?: string
66
+ clusterName?: string
67
67
  namespace?: string
68
68
  targetType?: TargetType
69
69
  targetNames?: string[]
@@ -84,9 +84,8 @@ export type RuleID = {
84
84
  export type Rule = {
85
85
  ruleId?: string
86
86
  ruleName?: string
87
- ruleGroupName?: string
88
87
  builtin?: boolean
89
- cluster?: string
88
+ clusterName?: string
90
89
  namespace?: string
91
90
  source?: RuleSource
92
91
  targetType?: TargetType
@@ -118,7 +117,7 @@ export type AnnotationReceiver = {
118
117
  export type CreateRuleRequest = {
119
118
  ruleName?: string
120
119
  description?: string
121
- cluster?: string
120
+ clusterName?: string
122
121
  namespace?: string
123
122
  source?: RuleSource
124
123
  targetType?: TargetType
@@ -135,7 +134,7 @@ export type CreateRuleRequest = {
135
134
  export type UpdateRuleRequest = {
136
135
  id?: string
137
136
  description?: string
138
- cluster?: string
137
+ clusterName?: string
139
138
  namespace?: string
140
139
  targetNames?: string[]
141
140
  expr?: string
@@ -150,7 +149,7 @@ export type UpdateRuleRequest = {
150
149
  export type ListAlertsRequest = {
151
150
  resolved?: boolean
152
151
  name?: string
153
- cluster?: string
152
+ clusterName?: string
154
153
  namespace?: string
155
154
  severity?: Severity
156
155
  page?: number
@@ -167,7 +166,7 @@ export type AlertSummary = {
167
166
  alertId?: string
168
167
  ruleName?: string
169
168
  severity?: Severity
170
- cluster?: string
169
+ clusterName?: string
171
170
  namespace?: string
172
171
  targetType?: TargetType
173
172
  targetName?: string
@@ -183,7 +182,7 @@ export type AlertInfo = {
183
182
  fingerprint?: string
184
183
  ruleName?: string
185
184
  ruleId?: string
186
- cluster?: string
185
+ clusterName?: string
187
186
  namespace?: string
188
187
  targetType?: TargetType
189
188
  targetName?: string
@@ -200,7 +199,7 @@ export type AlertInfo = {
200
199
 
201
200
  export type CountAlertRequest = {
202
201
  resolved?: boolean
203
- cluster?: string
202
+ clusterName?: string
204
203
  namespace?: string
205
204
  targetType?: TargetType
206
205
  targetName?: string
@@ -4,6 +4,8 @@
4
4
  * This file is a generated Typescript file for GRPC Gateway, DO NOT MODIFY
5
5
  */
6
6
 
7
+ import * as InsightIoApiTypeV1alpha1Page from "../../type/v1alpha1/page.pb"
8
+
7
9
  type Absent<T, K extends keyof T> = { [k in Exclude<keyof T, K>]?: undefined };
8
10
  type OneOf<T> =
9
11
  | { [k in keyof T]?: undefined }
@@ -37,16 +39,25 @@ export type LogQueryEventFilter = {
37
39
  }
38
40
 
39
41
 
40
- type BaseLogQueryRequest = {
42
+ type BaseQueryLogRequest = {
43
+ startTime?: string
44
+ endTime?: string
45
+ page?: number
46
+ pageSize?: number
47
+ sorts?: string[]
48
+ }
49
+
50
+ export type QueryLogRequest = BaseQueryLogRequest
51
+ & OneOf<{ resource: LogQueryResourceFilter; system: LogQuerySystemFilter; event: LogQueryEventFilter }>
52
+
53
+
54
+ type BaseQueryLogHistogramRequest = {
41
55
  startTime?: string
42
56
  endTime?: string
43
- from?: number
44
- size?: number
45
- sort?: string
46
57
  interval?: string
47
58
  }
48
59
 
49
- export type LogQueryRequest = BaseLogQueryRequest
60
+ export type QueryLogHistogramRequest = BaseQueryLogHistogramRequest
50
61
  & OneOf<{ resource: LogQueryResourceFilter; system: LogQuerySystemFilter; event: LogQueryEventFilter }>
51
62
 
52
63
  export type LogContextResourceFilter = {
@@ -66,7 +77,7 @@ export type LogContextEventFilter = {
66
77
  }
67
78
 
68
79
 
69
- type BaseLogContextRequest = {
80
+ type BaseQueryLogContextRequest = {
70
81
  startTime?: string
71
82
  endTime?: string
72
83
  before?: number
@@ -74,7 +85,7 @@ type BaseLogContextRequest = {
74
85
  nanotimestamp?: string
75
86
  }
76
87
 
77
- export type LogContextRequest = BaseLogContextRequest
88
+ export type QueryLogContextRequest = BaseQueryLogContextRequest
78
89
  & OneOf<{ resource: LogContextResourceFilter; system: LogContextSystemFilter; event: LogContextEventFilter }>
79
90
 
80
91
  export type LogQueryResult = {
@@ -83,14 +94,13 @@ export type LogQueryResult = {
83
94
  labels?: {[key: string]: string}
84
95
  }
85
96
 
86
- export type LogQueryResponse = {
87
- total?: string
88
- data?: LogQueryResult[]
97
+ export type QueryLogResponse = {
98
+ items?: LogQueryResult[]
99
+ pagination?: InsightIoApiTypeV1alpha1Page.Pagination
89
100
  }
90
101
 
91
- export type LogHistogramResponse = {
92
- total?: string
93
- data?: LogHistogramResult[]
102
+ export type QueryLogHistogramResponse = {
103
+ items?: LogHistogramResult[]
94
104
  }
95
105
 
96
106
  export type LogHistogramResult = {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@daocloud-proto/skoala",
3
- "version": "0.3.3-99",
3
+ "version": "0.4.1",
4
4
  "description": "",
5
5
  "main": "index.js",
6
6
  "scripts": {
@@ -4,7 +4,6 @@
4
4
  * This file is a generated Typescript file for GRPC Gateway, DO NOT MODIFY
5
5
  */
6
6
 
7
- import * as InsightIoApiMetricV1alpha1Metric from "../../metric/v1alpha1/metric.pb"
8
7
  import * as InsightIoApiTypeV1alpha1Page from "../../type/v1alpha1/page.pb"
9
8
  import * as InsightIoApiResourceV1alpha1Type from "./type.pb"
10
9
 
@@ -64,6 +63,7 @@ export type GetClusterRequest = {
64
63
 
65
64
  export type ClusterSummary = {
66
65
  name?: string
66
+ kubeSystemId?: string
67
67
  phase?: ClusterPhase
68
68
  provider?: ClusterProvider
69
69
  kubernetesVersion?: string
@@ -71,12 +71,11 @@ export type ClusterSummary = {
71
71
  nodeNumSummary?: InsightIoApiResourceV1alpha1Type.ResourceNumSummary
72
72
  podNumSummary?: InsightIoApiResourceV1alpha1Type.ResourceNumSummary
73
73
  insightAgentStatus?: InsightAgentStatus
74
- cpuUsage?: InsightIoApiMetricV1alpha1Metric.samplePair[]
75
- memoryUsage?: InsightIoApiMetricV1alpha1Metric.samplePair[]
76
74
  }
77
75
 
78
76
  export type ClusterDetail = {
79
77
  name?: string
78
+ kubeSystemId?: string
80
79
  phase?: ClusterPhase
81
80
  provider?: ClusterProvider
82
81
  kubernetesVersion?: string
@@ -5,6 +5,7 @@
5
5
  */
6
6
 
7
7
  import * as GoogleProtobufDuration from "../../google/protobuf/duration.pb"
8
+ import * as InsightIoApiMetricV1alpha1Metric from "../../metric/v1alpha1/metric.pb"
8
9
  import * as InsightIoApiSpan_metricV1alpha1Openmetrics from "./openmetrics.pb"
9
10
  import * as InsightIoApiSpan_metricV1alpha1Otelspankind from "./otelspankind.pb"
10
11
  export type MetricsQueryBaseRequest = {
@@ -65,45 +66,31 @@ export type MetricsFamilyWithOperation = {
65
66
  }
66
67
 
67
68
  export type MetricsWithOperation = {
68
- operation?: string
69
- metricPointsGroups?: MetricsPointsGroup[]
69
+ operationName?: string
70
+ metricGroups?: MetricsGroup[]
70
71
  }
71
72
 
72
- export type MetricsPointsGroup = {
73
- apdex?: string
74
- metricPoints?: InsightIoApiSpan_metricV1alpha1Openmetrics.MetricPoint[]
73
+ export type MetricsGroup = {
74
+ metrics?: InsightIoApiMetricV1alpha1Metric.samplePair[]
75
75
  metricsLabel?: string
76
76
  metricsAvg?: number
77
77
  }
78
78
 
79
- export type GetREDRequest = {
80
- baseRequest?: MetricsQueryBaseRequest
81
- quantile?: string
82
- }
83
-
84
- export type GetREDResponse = {
85
- p95Metrics?: InsightIoApiSpan_metricV1alpha1Openmetrics.MetricPoint[]
86
- p75Metrics?: InsightIoApiSpan_metricV1alpha1Openmetrics.MetricPoint[]
87
- p50Metrics?: InsightIoApiSpan_metricV1alpha1Openmetrics.MetricPoint[]
88
- callsMetric?: InsightIoApiSpan_metricV1alpha1Openmetrics.MetricPoint[]
89
- errorsMetrics?: InsightIoApiSpan_metricV1alpha1Openmetrics.MetricPoint[]
90
- }
91
-
92
79
  export type GetServiceDetailRequest = {
93
80
  baseRequest?: MetricsQueryBaseRequest
94
81
  }
95
82
 
96
83
  export type GetServiceDetailResponse = {
97
- p95Metrics?: InsightIoApiSpan_metricV1alpha1Openmetrics.MetricPoint[]
98
- p75Metrics?: InsightIoApiSpan_metricV1alpha1Openmetrics.MetricPoint[]
99
- p50Metrics?: InsightIoApiSpan_metricV1alpha1Openmetrics.MetricPoint[]
100
- reqRateMetric?: InsightIoApiSpan_metricV1alpha1Openmetrics.MetricPoint[]
101
- repLatencyMetric?: InsightIoApiSpan_metricV1alpha1Openmetrics.MetricPoint[]
102
- errorsRateMetrics?: InsightIoApiSpan_metricV1alpha1Openmetrics.MetricPoint[]
103
- totalCallsMetrics?: InsightIoApiSpan_metricV1alpha1Openmetrics.MetricPoint[]
84
+ p95Metrics?: InsightIoApiMetricV1alpha1Metric.SampleStream[]
85
+ p75Metrics?: InsightIoApiMetricV1alpha1Metric.SampleStream[]
86
+ p50Metrics?: InsightIoApiMetricV1alpha1Metric.SampleStream[]
87
+ reqRateMetric?: InsightIoApiMetricV1alpha1Metric.SampleStream[]
88
+ repLatencyMetric?: InsightIoApiMetricV1alpha1Metric.SampleStream[]
89
+ errorsRateMetrics?: InsightIoApiMetricV1alpha1Metric.SampleStream[]
90
+ totalCallsMetrics?: InsightIoApiMetricV1alpha1Metric.SampleStream[]
104
91
  avgReqRate?: number
105
92
  avgRepLatency?: number
106
- avgErrorTate?: number
93
+ avgErrorRate?: number
107
94
  totalCalls?: number
108
95
  apdex?: number
109
96
  }
@@ -0,0 +1,266 @@
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 GoogleProtobufDuration from "../google/protobuf/duration.pb"
8
+ import * as GoogleProtobufTimestamp from "../google/protobuf/timestamp.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 KnownRegex {
20
+ UNKNOWN = "UNKNOWN",
21
+ HTTP_HEADER_NAME = "HTTP_HEADER_NAME",
22
+ HTTP_HEADER_VALUE = "HTTP_HEADER_VALUE",
23
+ }
24
+
25
+
26
+ type BaseFieldRules = {
27
+ message?: MessageRules
28
+ }
29
+
30
+ export type FieldRules = BaseFieldRules
31
+ & OneOf<{ float: FloatRules; double: DoubleRules; int32: Int32Rules; int64: Int64Rules; uint32: UInt32Rules; uint64: UInt64Rules; sint32: SInt32Rules; sint64: SInt64Rules; fixed32: Fixed32Rules; fixed64: Fixed64Rules; sfixed32: SFixed32Rules; sfixed64: SFixed64Rules; bool: BoolRules; string: StringRules; bytes: BytesRules; enum: EnumRules; repeated: RepeatedRules; map: MapRules; any: AnyRules; duration: DurationRules; timestamp: TimestampRules }>
32
+
33
+ export type FloatRules = {
34
+ const?: number
35
+ lt?: number
36
+ lte?: number
37
+ gt?: number
38
+ gte?: number
39
+ in?: number[]
40
+ notIn?: number[]
41
+ ignoreEmpty?: boolean
42
+ }
43
+
44
+ export type DoubleRules = {
45
+ const?: number
46
+ lt?: number
47
+ lte?: number
48
+ gt?: number
49
+ gte?: number
50
+ in?: number[]
51
+ notIn?: number[]
52
+ ignoreEmpty?: boolean
53
+ }
54
+
55
+ export type Int32Rules = {
56
+ const?: number
57
+ lt?: number
58
+ lte?: number
59
+ gt?: number
60
+ gte?: number
61
+ in?: number[]
62
+ notIn?: number[]
63
+ ignoreEmpty?: boolean
64
+ }
65
+
66
+ export type Int64Rules = {
67
+ const?: string
68
+ lt?: string
69
+ lte?: string
70
+ gt?: string
71
+ gte?: string
72
+ in?: string[]
73
+ notIn?: string[]
74
+ ignoreEmpty?: boolean
75
+ }
76
+
77
+ export type UInt32Rules = {
78
+ const?: number
79
+ lt?: number
80
+ lte?: number
81
+ gt?: number
82
+ gte?: number
83
+ in?: number[]
84
+ notIn?: number[]
85
+ ignoreEmpty?: boolean
86
+ }
87
+
88
+ export type UInt64Rules = {
89
+ const?: string
90
+ lt?: string
91
+ lte?: string
92
+ gt?: string
93
+ gte?: string
94
+ in?: string[]
95
+ notIn?: string[]
96
+ ignoreEmpty?: boolean
97
+ }
98
+
99
+ export type SInt32Rules = {
100
+ const?: number
101
+ lt?: number
102
+ lte?: number
103
+ gt?: number
104
+ gte?: number
105
+ in?: number[]
106
+ notIn?: number[]
107
+ ignoreEmpty?: boolean
108
+ }
109
+
110
+ export type SInt64Rules = {
111
+ const?: string
112
+ lt?: string
113
+ lte?: string
114
+ gt?: string
115
+ gte?: string
116
+ in?: string[]
117
+ notIn?: string[]
118
+ ignoreEmpty?: boolean
119
+ }
120
+
121
+ export type Fixed32Rules = {
122
+ const?: number
123
+ lt?: number
124
+ lte?: number
125
+ gt?: number
126
+ gte?: number
127
+ in?: number[]
128
+ notIn?: number[]
129
+ ignoreEmpty?: boolean
130
+ }
131
+
132
+ export type Fixed64Rules = {
133
+ const?: string
134
+ lt?: string
135
+ lte?: string
136
+ gt?: string
137
+ gte?: string
138
+ in?: string[]
139
+ notIn?: string[]
140
+ ignoreEmpty?: boolean
141
+ }
142
+
143
+ export type SFixed32Rules = {
144
+ const?: number
145
+ lt?: number
146
+ lte?: number
147
+ gt?: number
148
+ gte?: number
149
+ in?: number[]
150
+ notIn?: number[]
151
+ ignoreEmpty?: boolean
152
+ }
153
+
154
+ export type SFixed64Rules = {
155
+ const?: string
156
+ lt?: string
157
+ lte?: string
158
+ gt?: string
159
+ gte?: string
160
+ in?: string[]
161
+ notIn?: string[]
162
+ ignoreEmpty?: boolean
163
+ }
164
+
165
+ export type BoolRules = {
166
+ const?: boolean
167
+ }
168
+
169
+
170
+ type BaseStringRules = {
171
+ const?: string
172
+ len?: string
173
+ minLen?: string
174
+ maxLen?: string
175
+ lenBytes?: string
176
+ minBytes?: string
177
+ maxBytes?: string
178
+ pattern?: string
179
+ prefix?: string
180
+ suffix?: string
181
+ contains?: string
182
+ notContains?: string
183
+ in?: string[]
184
+ notIn?: string[]
185
+ strict?: boolean
186
+ ignoreEmpty?: boolean
187
+ }
188
+
189
+ export type StringRules = BaseStringRules
190
+ & OneOf<{ email: boolean; hostname: boolean; ip: boolean; ipv4: boolean; ipv6: boolean; uri: boolean; uriRef: boolean; address: boolean; uuid: boolean; wellKnownRegex: KnownRegex }>
191
+
192
+
193
+ type BaseBytesRules = {
194
+ const?: Uint8Array
195
+ len?: string
196
+ minLen?: string
197
+ maxLen?: string
198
+ pattern?: string
199
+ prefix?: Uint8Array
200
+ suffix?: Uint8Array
201
+ contains?: Uint8Array
202
+ in?: Uint8Array[]
203
+ notIn?: Uint8Array[]
204
+ ignoreEmpty?: boolean
205
+ }
206
+
207
+ export type BytesRules = BaseBytesRules
208
+ & OneOf<{ ip: boolean; ipv4: boolean; ipv6: boolean }>
209
+
210
+ export type EnumRules = {
211
+ const?: number
212
+ definedOnly?: boolean
213
+ in?: number[]
214
+ notIn?: number[]
215
+ }
216
+
217
+ export type MessageRules = {
218
+ skip?: boolean
219
+ required?: boolean
220
+ }
221
+
222
+ export type RepeatedRules = {
223
+ minItems?: string
224
+ maxItems?: string
225
+ unique?: boolean
226
+ items?: FieldRules
227
+ ignoreEmpty?: boolean
228
+ }
229
+
230
+ export type MapRules = {
231
+ minPairs?: string
232
+ maxPairs?: string
233
+ noSparse?: boolean
234
+ keys?: FieldRules
235
+ values?: FieldRules
236
+ ignoreEmpty?: boolean
237
+ }
238
+
239
+ export type AnyRules = {
240
+ required?: boolean
241
+ in?: string[]
242
+ notIn?: string[]
243
+ }
244
+
245
+ export type DurationRules = {
246
+ required?: boolean
247
+ const?: GoogleProtobufDuration.Duration
248
+ lt?: GoogleProtobufDuration.Duration
249
+ lte?: GoogleProtobufDuration.Duration
250
+ gt?: GoogleProtobufDuration.Duration
251
+ gte?: GoogleProtobufDuration.Duration
252
+ in?: GoogleProtobufDuration.Duration[]
253
+ notIn?: GoogleProtobufDuration.Duration[]
254
+ }
255
+
256
+ export type TimestampRules = {
257
+ required?: boolean
258
+ const?: GoogleProtobufTimestamp.Timestamp
259
+ lt?: GoogleProtobufTimestamp.Timestamp
260
+ lte?: GoogleProtobufTimestamp.Timestamp
261
+ gt?: GoogleProtobufTimestamp.Timestamp
262
+ gte?: GoogleProtobufTimestamp.Timestamp
263
+ ltNow?: boolean
264
+ gtNow?: boolean
265
+ within?: GoogleProtobufDuration.Duration
266
+ }