@daocloud-proto/kairship 0.1.5-8 → 0.1.6

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.
@@ -0,0 +1,56 @@
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 KairshipIoApiTypesPage from "../../types/page.pb"
8
+
9
+ export enum EventType {
10
+ EVENT_TYPE_UNSPECIFIED = "EVENT_TYPE_UNSPECIFIED",
11
+ Normal = "Normal",
12
+ Warning = "Warning",
13
+ }
14
+
15
+ export type Event = {
16
+ involvedObject?: ObjectReference
17
+ reason?: string
18
+ message?: string
19
+ source?: EventSource
20
+ lastTimestamp?: string
21
+ type?: EventType
22
+ }
23
+
24
+ export type ObjectReference = {
25
+ kind?: string
26
+ name?: string
27
+ }
28
+
29
+ export type EventSource = {
30
+ component?: string
31
+ host?: string
32
+ }
33
+
34
+ export type ListInstanceEventsRequest = {
35
+ instance?: string
36
+ page?: number
37
+ pageSize?: number
38
+ sortBy?: KairshipIoApiTypesPage.SortBy
39
+ sortDir?: KairshipIoApiTypesPage.SortDir
40
+ type?: EventType[]
41
+ kind?: string
42
+ name?: string
43
+ }
44
+
45
+ export type ListInstanceEventsResponse = {
46
+ items?: Event[]
47
+ pagination?: KairshipIoApiTypesPage.Pagination
48
+ }
49
+
50
+ export type ListInstanceEventKindsRequest = {
51
+ instance?: string
52
+ }
53
+
54
+ export type ListInstanceEventKindsResponse = {
55
+ data?: string[]
56
+ }
@@ -61,9 +61,15 @@ export type InstanceStatusSummary = {
61
61
  policyTotalNum?: {[key: string]: number}
62
62
  clusterSummary?: NumStatistic
63
63
  nodeSummary?: NumStatistic
64
+ resourceSummary?: ResourceSummary
64
65
  workLoadSummary?: {[key: string]: NumStatistic}
65
66
  }
66
67
 
68
+ export type ResourceSummary = {
69
+ allocatable?: {[key: string]: string}
70
+ allocated?: {[key: string]: string}
71
+ }
72
+
67
73
  export type NumStatistic = {
68
74
  totalNum?: number
69
75
  readyNum?: number
@@ -10,6 +10,7 @@ import * as KairshipIoApiAppsV1alpha1Deployment from "../apps/v1alpha1/deploymen
10
10
  import * as KairshipIoApiCloudshellV1alpha1Cloudshell from "../cloudshell/v1alpha1/cloudshell.pb"
11
11
  import * as KairshipIoApiClusterV1alpha1Cluster from "../cluster/v1alpha1/cluster.pb"
12
12
  import * as KairshipIoApiCoreV1alpha1Configmap from "../core/v1alpha1/configmap.pb"
13
+ import * as KairshipIoApiCoreV1alpha1Event from "../core/v1alpha1/event.pb"
13
14
  import * as KairshipIoApiCoreV1alpha1Namespace from "../core/v1alpha1/namespace.pb"
14
15
  import * as KairshipIoApiCoreV1alpha1Pod from "../core/v1alpha1/pod.pb"
15
16
  import * as KairshipIoApiCoreV1alpha1Secret from "../core/v1alpha1/secret.pb"
@@ -175,6 +176,12 @@ export class Core {
175
176
  static ListSecretsForMemberCluster(req: KairshipIoApiCoreV1alpha1Secret.ListSecretsForMemberClusterRequest, initReq?: fm.InitReq): Promise<KairshipIoApiCoreV1alpha1Secret.ListSecretsForMemberClusterResponse> {
176
177
  return fm.fetchReq<KairshipIoApiCoreV1alpha1Secret.ListSecretsForMemberClusterRequest, KairshipIoApiCoreV1alpha1Secret.ListSecretsForMemberClusterResponse>(`/apis/kairship.io/v1alpha1/instances/${req["instance"]}/clusters/${req["cluster"]}/namespaces/${req["namespace"]}/secrets?${fm.renderURLSearchParams(req, ["instance", "cluster", "namespace"])}`, {...initReq, method: "GET"})
177
178
  }
179
+ static ListInstanceEvents(req: KairshipIoApiCoreV1alpha1Event.ListInstanceEventsRequest, initReq?: fm.InitReq): Promise<KairshipIoApiCoreV1alpha1Event.ListInstanceEventsResponse> {
180
+ return fm.fetchReq<KairshipIoApiCoreV1alpha1Event.ListInstanceEventsRequest, KairshipIoApiCoreV1alpha1Event.ListInstanceEventsResponse>(`/apis/kairship.io/v1alpha1/instances/${req["instance"]}/events?${fm.renderURLSearchParams(req, ["instance"])}`, {...initReq, method: "GET"})
181
+ }
182
+ static ListInstanceEventKinds(req: KairshipIoApiCoreV1alpha1Event.ListInstanceEventKindsRequest, initReq?: fm.InitReq): Promise<KairshipIoApiCoreV1alpha1Event.ListInstanceEventKindsResponse> {
183
+ return fm.fetchReq<KairshipIoApiCoreV1alpha1Event.ListInstanceEventKindsRequest, KairshipIoApiCoreV1alpha1Event.ListInstanceEventKindsResponse>(`/apis/kairship.io/v1alpha1/instances/${req["instance"]}/events/kinds?${fm.renderURLSearchParams(req, ["instance"])}`, {...initReq, method: "GET"})
184
+ }
178
185
  }
179
186
  export class Apps {
180
187
  static ListInstanceDeployments(req: KairshipIoApiAppsV1alpha1Deployment.ListInstanceDeploymentsRequest, initReq?: fm.InitReq): Promise<KairshipIoApiAppsV1alpha1Deployment.ListInstanceDeploymentsResponse> {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name":"@daocloud-proto/kairship",
3
- "version":"0.1.5-8",
3
+ "version":"0.1.6",
4
4
  "description": "",
5
5
  "main": "index.js",
6
6
  "scripts": {