@daocloud-proto/kairship 0.2.2-8 → 0.2.3-2

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.
@@ -11,5 +11,6 @@ export type AggregationResource = {
11
11
 
12
12
  export type CreateAggregationResourceRequest = {
13
13
  instance?: string
14
+ namespace?: string
14
15
  data?: AggregationResource
15
16
  }
@@ -104,8 +104,8 @@ export type ListDeploymentsRequest = {
104
104
  namespace?: string
105
105
  page?: number
106
106
  pageSize?: number
107
- name?: string[]
108
- phases?: string[]
107
+ name?: string
108
+ phase?: string
109
109
  sortBy?: KairshipIoApiTypesPage.SortBy
110
110
  sortDir?: KairshipIoApiTypesPage.SortDir
111
111
  }
@@ -116,7 +116,7 @@ export type ListMemberClusterDeploymentsRequest = {
116
116
  namespace?: string
117
117
  page?: number
118
118
  pageSize?: number
119
- name?: string[]
119
+ name?: string
120
120
  sortBy?: KairshipIoApiTypesPage.SortBy
121
121
  sortDir?: KairshipIoApiTypesPage.SortDir
122
122
  }
@@ -135,8 +135,8 @@ export type ListInstanceDeploymentsRequest = {
135
135
  instance?: string
136
136
  page?: number
137
137
  pageSize?: number
138
- name?: string[]
139
- phases?: string[]
138
+ name?: string
139
+ phase?: string
140
140
  sortBy?: KairshipIoApiTypesPage.SortBy
141
141
  sortDir?: KairshipIoApiTypesPage.SortDir
142
142
  }
@@ -82,7 +82,7 @@ export type ListClustersRequest = {
82
82
  pageSize?: number
83
83
  role?: string[]
84
84
  kubernetesVersion?: string
85
- phases?: string[]
85
+ phase?: string
86
86
  labels?: {[key: string]: string}
87
87
  annotations?: {[key: string]: string}
88
88
  managedBy?: string
@@ -107,4 +107,17 @@ export type ClusterRequest = {
107
107
 
108
108
  export type ClusterResponse = {
109
109
  cluster?: Cluster
110
+ }
111
+
112
+ export type ListClustersLabelsRequest = {
113
+ instance?: string
114
+ }
115
+
116
+ export type ListClustersLabelsResponse = {
117
+ clusterLabels?: ClusterLabels[]
118
+ }
119
+
120
+ export type ClusterLabels = {
121
+ cluster?: string
122
+ labels?: {[key: string]: string}
110
123
  }
@@ -20,7 +20,7 @@ export type ListConfigMapsRequest = {
20
20
  pageSize?: number
21
21
  sortBy?: KairshipIoApiTypesPage.SortBy
22
22
  sortDir?: KairshipIoApiTypesPage.SortDir
23
- name?: string[]
23
+ name?: string
24
24
  labelSelector?: string
25
25
  fieldSelector?: string
26
26
  }
@@ -43,7 +43,7 @@ export type NamespaceSummary = {
43
43
 
44
44
  export type ListNamespacesRequest = {
45
45
  instance?: string
46
- name?: string[]
46
+ name?: string
47
47
  page?: number
48
48
  pageSize?: number
49
49
  sortBy?: KairshipIoApiTypesPage.SortBy
@@ -105,4 +105,19 @@ export type PatchNamespaceResponse = {
105
105
  export type DeleteNamespaceRequest = {
106
106
  instance?: string
107
107
  name?: string
108
+ }
109
+
110
+ export type ListMemberClusterNamespaceSummaryRequest = {
111
+ instance?: string
112
+ cluster?: string
113
+ }
114
+
115
+ export type ListMemberClusterNamespaceSummaryResponse = {
116
+ data?: MemberClusterNamespaceSummary[]
117
+ }
118
+
119
+ export type MemberClusterNamespaceSummary = {
120
+ name?: string
121
+ instance?: string
122
+ cluster?: string
108
123
  }
@@ -77,10 +77,13 @@ export type ListPersistentVolumeClaimsRequest = {
77
77
  namespace?: string
78
78
  page?: number
79
79
  pageSize?: number
80
- name?: string[]
81
- phases?: string[]
80
+ name?: string
81
+ phase?: string
82
82
  sortBy?: KairshipIoApiTypesPage.SortBy
83
83
  orderBy?: KairshipIoApiTypesPage.SortDir
84
+ labelSelector?: string
85
+ fieldSelector?: string
86
+ accessMode?: AccessMode
84
87
  }
85
88
 
86
89
  export type ListPersistentVolumeClaimsResponse = {
@@ -456,7 +456,7 @@ export type ListPodsForMemberClusterRequest = {
456
456
  kind?: ListPodsForMemberClusterRequestKind
457
457
  kindName?: string
458
458
  name?: string
459
- phases?: string[]
459
+ phase?: string
460
460
  sortBy?: KairshipIoApiTypesPage.SortBy
461
461
  sortDir?: KairshipIoApiTypesPage.SortDir
462
462
  labelSelector?: string
@@ -19,7 +19,7 @@ export type ListSecretsRequest = {
19
19
  page?: number
20
20
  pageSize?: number
21
21
  namespace?: string
22
- name?: string[]
22
+ name?: string
23
23
  sortBy?: KairshipIoApiTypesPage.SortBy
24
24
  sortDir?: KairshipIoApiTypesPage.SortDir
25
25
  labelSelector?: string
@@ -37,7 +37,7 @@ export type ListSecretsForMemberClusterRequest = {
37
37
  page?: number
38
38
  pageSize?: number
39
39
  namespace?: string
40
- name?: string[]
40
+ name?: string
41
41
  sortBy?: KairshipIoApiTypesPage.SortBy
42
42
  sortDir?: KairshipIoApiTypesPage.SortDir
43
43
  labelSelector?: string
@@ -21,4 +21,21 @@ export type Sample = {
21
21
  export type samplePair = {
22
22
  timestamp?: string
23
23
  value?: string
24
+ }
25
+
26
+ export type PrometheusQueryRangeRequest = {
27
+ instance?: string
28
+ query?: string
29
+ start?: string
30
+ end?: string
31
+ step?: number
32
+ }
33
+
34
+ export type PrometheusQueryRangeResult = {
35
+ matrix?: SampleStream[]
36
+ }
37
+
38
+ export type SampleStream = {
39
+ metric?: {[key: string]: string}
40
+ values?: samplePair[]
24
41
  }
@@ -47,8 +47,8 @@ export type ListInstanceOverridePoliciesRequest = {
47
47
  instance?: string
48
48
  page?: number
49
49
  pageSize?: number
50
- name?: string[]
51
- phases?: string[]
50
+ name?: string
51
+ phase?: string
52
52
  sortBy?: KairshipIoApiTypesPage.SortBy
53
53
  sortDir?: KairshipIoApiTypesPage.SortDir
54
54
  }
@@ -10,22 +10,22 @@ import * as KairshipIoApiPolicyV1alpha1Types from "./types.pb"
10
10
 
11
11
  export enum SpreadFieldValue {
12
12
  SPREAD_FIELD_VALUE_UNSPECIFIED = "SPREAD_FIELD_VALUE_UNSPECIFIED",
13
- SpreadByFieldCluster = "SpreadByFieldCluster",
14
- SpreadByFieldRegion = "SpreadByFieldRegion",
15
- SpreadByFieldZone = "SpreadByFieldZone",
16
- SpreadByFieldProvider = "SpreadByFieldProvider",
13
+ cluster = "cluster",
14
+ region = "region",
15
+ zone = "zone",
16
+ provider = "provider",
17
17
  }
18
18
 
19
19
  export enum ReplicaSchedulingType {
20
20
  REPLICA_SCHEDULING_TYPE_UNSPECIFIED = "REPLICA_SCHEDULING_TYPE_UNSPECIFIED",
21
- ReplicaSchedulingTypeDuplicated = "ReplicaSchedulingTypeDuplicated",
22
- ReplicaSchedulingTypeDivided = "ReplicaSchedulingTypeDivided",
21
+ Duplicated = "Duplicated",
22
+ Divided = "Divided",
23
23
  }
24
24
 
25
25
  export enum ReplicaDivisionPreference {
26
26
  REPLICA_DIVISION_PREFERENCE_UNSPECIFIED = "REPLICA_DIVISION_PREFERENCE_UNSPECIFIED",
27
- ReplicaDivisionPreferenceAggregated = "ReplicaDivisionPreferenceAggregated",
28
- ReplicaDivisionPreferenceWeighted = "ReplicaDivisionPreferenceWeighted",
27
+ Aggregated = "Aggregated",
28
+ Weighted = "Weighted",
29
29
  }
30
30
 
31
31
  export enum DynamicWeightFactor {
@@ -96,8 +96,8 @@ export type ListInstancePropagationPoliciesRequest = {
96
96
  instance?: string
97
97
  page?: number
98
98
  pageSize?: number
99
- name?: string[]
100
- phases?: string[]
99
+ name?: string
100
+ phase?: string
101
101
  sortBy?: KairshipIoApiTypesPage.SortBy
102
102
  sortDir?: KairshipIoApiTypesPage.SortDir
103
103
  }
@@ -16,4 +16,5 @@ export type ResourceSelector = {
16
16
  export type ClusterAffinity = {
17
17
  labelSelector?: KairshipIoApiTypesObjectmeta.LabelSelector
18
18
  clusterNames?: string[]
19
+ exclude?: string[]
19
20
  }
@@ -81,6 +81,9 @@ export class Cluster {
81
81
  static UpdateJoinedCluster(req: KairshipIoApiClusterV1alpha1Cluster.ClusterRequest, initReq?: fm.InitReq): Promise<KairshipIoApiClusterV1alpha1Cluster.ClusterResponse> {
82
82
  return fm.fetchReq<KairshipIoApiClusterV1alpha1Cluster.ClusterRequest, KairshipIoApiClusterV1alpha1Cluster.ClusterResponse>(`/apis/kairship.io/v1alpha1/instances/${req["instance"]}/clusters/${req["name"]}`, {...initReq, method: "PUT", body: JSON.stringify(req, fm.replacer)})
83
83
  }
84
+ static ListClustersLabels(req: KairshipIoApiClusterV1alpha1Cluster.ListClustersLabelsRequest, initReq?: fm.InitReq): Promise<KairshipIoApiClusterV1alpha1Cluster.ListClustersLabelsResponse> {
85
+ return fm.fetchReq<KairshipIoApiClusterV1alpha1Cluster.ListClustersLabelsRequest, KairshipIoApiClusterV1alpha1Cluster.ListClustersLabelsResponse>(`/apis/kairship.io/v1alpha1/instances/${req["instance"]}/clusters-labels?${fm.renderURLSearchParams(req, ["instance"])}`, {...initReq, method: "GET"})
86
+ }
84
87
  }
85
88
  export class Core {
86
89
  static ListNamespaces(req: KairshipIoApiCoreV1alpha1Namespace.ListNamespacesRequest, initReq?: fm.InitReq): Promise<KairshipIoApiCoreV1alpha1Namespace.ListNamespacesResponse> {
@@ -89,6 +92,9 @@ export class Core {
89
92
  static ListNamespaceSummary(req: KairshipIoApiCoreV1alpha1Namespace.ListNamespaceSummaryRequest, initReq?: fm.InitReq): Promise<KairshipIoApiCoreV1alpha1Namespace.ListNamespaceSummaryResponse> {
90
93
  return fm.fetchReq<KairshipIoApiCoreV1alpha1Namespace.ListNamespaceSummaryRequest, KairshipIoApiCoreV1alpha1Namespace.ListNamespaceSummaryResponse>(`/apis/kairship.io/v1alpha1/instances/${req["instance"]}/namespacesummary?${fm.renderURLSearchParams(req, ["instance"])}`, {...initReq, method: "GET"})
91
94
  }
95
+ static ListMemberClusterNamespaceSummary(req: KairshipIoApiCoreV1alpha1Namespace.ListMemberClusterNamespaceSummaryRequest, initReq?: fm.InitReq): Promise<KairshipIoApiCoreV1alpha1Namespace.ListMemberClusterNamespaceSummaryResponse> {
96
+ return fm.fetchReq<KairshipIoApiCoreV1alpha1Namespace.ListMemberClusterNamespaceSummaryRequest, KairshipIoApiCoreV1alpha1Namespace.ListMemberClusterNamespaceSummaryResponse>(`/apis/kairship.io/v1alpha1/instances/${req["instance"]}/member-clusters/${req["cluster"]}/namespacesummary?${fm.renderURLSearchParams(req, ["instance", "cluster"])}`, {...initReq, method: "GET"})
97
+ }
92
98
  static GetNamespace(req: KairshipIoApiCoreV1alpha1Namespace.GetNamespaceRequest, initReq?: fm.InitReq): Promise<KairshipIoApiCoreV1alpha1Namespace.GetNamespaceResponse> {
93
99
  return fm.fetchReq<KairshipIoApiCoreV1alpha1Namespace.GetNamespaceRequest, KairshipIoApiCoreV1alpha1Namespace.GetNamespaceResponse>(`/apis/kairship.io/v1alpha1/instances/${req["instance"]}/namespaces/${req["name"]}?${fm.renderURLSearchParams(req, ["instance", "name"])}`, {...initReq, method: "GET"})
94
100
  }
@@ -232,6 +238,9 @@ export class Apps {
232
238
  static ListMemberClusterDeployments(req: KairshipIoApiAppsV1alpha1Deployment.ListMemberClusterDeploymentsRequest, initReq?: fm.InitReq): Promise<KairshipIoApiAppsV1alpha1Deployment.ListMemberClusterDeploymentsResponse> {
233
239
  return fm.fetchReq<KairshipIoApiAppsV1alpha1Deployment.ListMemberClusterDeploymentsRequest, KairshipIoApiAppsV1alpha1Deployment.ListMemberClusterDeploymentsResponse>(`/apis/kairship.io/v1alpha1/instances/${req["instance"]}/member-clusters/${req["cluster"]}/namespaces/${req["namespace"]}/deployments?${fm.renderURLSearchParams(req, ["instance", "cluster", "namespace"])}`, {...initReq, method: "GET"})
234
240
  }
241
+ static ListMemberClusterAllDeployments(req: KairshipIoApiAppsV1alpha1Deployment.ListMemberClusterDeploymentsRequest, initReq?: fm.InitReq): Promise<KairshipIoApiAppsV1alpha1Deployment.ListMemberClusterDeploymentsResponse> {
242
+ return fm.fetchReq<KairshipIoApiAppsV1alpha1Deployment.ListMemberClusterDeploymentsRequest, KairshipIoApiAppsV1alpha1Deployment.ListMemberClusterDeploymentsResponse>(`/apis/kairship.io/v1alpha1/instances/${req["instance"]}/member-clusters/${req["cluster"]}/deployments?${fm.renderURLSearchParams(req, ["instance", "cluster"])}`, {...initReq, method: "GET"})
243
+ }
235
244
  static PromoteMemberClusterDeployment(req: KairshipIoApiAppsV1alpha1Deployment.PromoteMemberClusterDeploymentRequest, initReq?: fm.InitReq): Promise<GoogleProtobufEmpty.Empty> {
236
245
  return fm.fetchReq<KairshipIoApiAppsV1alpha1Deployment.PromoteMemberClusterDeploymentRequest, GoogleProtobufEmpty.Empty>(`/apis/kairship.io/v1alpha1/instances/${req["instance"]}/member-clusters/${req["cluster"]}/namespaces/${req["namespace"]}/deployments/${req["name"]}:promote`, {...initReq, method: "POST"})
237
246
  }
@@ -274,10 +283,13 @@ export class Insight {
274
283
  static QueryMetric(req: KairshipIoApiInsightV1alpha1Prometheus.PrometheusQueryRequest, initReq?: fm.InitReq): Promise<KairshipIoApiInsightV1alpha1Prometheus.PrometheusQueryResult> {
275
284
  return fm.fetchReq<KairshipIoApiInsightV1alpha1Prometheus.PrometheusQueryRequest, KairshipIoApiInsightV1alpha1Prometheus.PrometheusQueryResult>(`/apis/kairship.io/v1alpha1/instances/${req["instance"]}/metric?${fm.renderURLSearchParams(req, ["instance"])}`, {...initReq, method: "GET"})
276
285
  }
286
+ static QueryRangeMetric(req: KairshipIoApiInsightV1alpha1Prometheus.PrometheusQueryRangeRequest, initReq?: fm.InitReq): Promise<KairshipIoApiInsightV1alpha1Prometheus.PrometheusQueryRangeResult> {
287
+ return fm.fetchReq<KairshipIoApiInsightV1alpha1Prometheus.PrometheusQueryRangeRequest, KairshipIoApiInsightV1alpha1Prometheus.PrometheusQueryRangeResult>(`/apis/kairship.io/v1alpha1/instances/${req["instance"]}/range-metric?${fm.renderURLSearchParams(req, ["instance"])}`, {...initReq, method: "GET"})
288
+ }
277
289
  }
278
- export class aggregation {
290
+ export class Aggregation {
279
291
  static CreateAggregationResource(req: KairshipIoApiAggregationV1alpha1Aggregation.CreateAggregationResourceRequest, initReq?: fm.InitReq): Promise<KairshipIoApiAggregationV1alpha1Aggregation.AggregationResource> {
280
- return fm.fetchReq<KairshipIoApiAggregationV1alpha1Aggregation.CreateAggregationResourceRequest, KairshipIoApiAggregationV1alpha1Aggregation.AggregationResource>(`/apis/kairship.io/v1alpha1/instances/${req["instance"]}/aggregationresource`, {...initReq, method: "POST", body: JSON.stringify(req, fm.replacer)})
292
+ return fm.fetchReq<KairshipIoApiAggregationV1alpha1Aggregation.CreateAggregationResourceRequest, KairshipIoApiAggregationV1alpha1Aggregation.AggregationResource>(`/apis/kairship.io/v1alpha1/instances/${req["instance"]}/namespaces/${req["namespace"]}/aggregationresource`, {...initReq, method: "POST", body: JSON.stringify(req, fm.replacer)})
281
293
  }
282
294
  }
283
295
  export class Workspace {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name":"@daocloud-proto/kairship",
3
- "version":"0.2.2-8",
3
+ "version":"0.2.3-2",
4
4
  "description": "",
5
5
  "main": "index.js",
6
6
  "scripts": {