@daocloud-proto/skoala 0.14.0-8 → 0.15.0

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.
@@ -54,4 +54,14 @@ export type InsightMonitorMetrics = {
54
54
  diskWrite?: InsightIoApiMetricV1alpha1Metric.SampleStream[]
55
55
  netBytesReceived?: InsightIoApiMetricV1alpha1Metric.SampleStream[]
56
56
  netBytesTransmitted?: InsightIoApiMetricV1alpha1Metric.SampleStream[]
57
+ }
58
+
59
+ export type NacosInsightMetrics = {
60
+ enabled?: boolean
61
+ serviceCount?: number
62
+ avgPushCost?: InsightIoApiMetricV1alpha1Metric.SampleStream[]
63
+ maxPushCost?: InsightIoApiMetricV1alpha1Metric.SampleStream[]
64
+ failedPush?: InsightIoApiMetricV1alpha1Metric.SampleStream[]
65
+ configCount?: number
66
+ longPolling?: number
57
67
  }
@@ -12,6 +12,11 @@ export enum ListNamespaceReqGatewayStatus {
12
12
  Unavailable = "Unavailable",
13
13
  }
14
14
 
15
+ export enum ListRegistryServiceReqRegistryType {
16
+ hosted = "hosted",
17
+ integrated = "integrated",
18
+ }
19
+
15
20
  export enum RegistryServiceInfoRegistryType {
16
21
  NACOS = "NACOS",
17
22
  EUREKA = "EUREKA",
@@ -89,6 +94,11 @@ export type ListMeshServiceReq = {
89
94
  export type ListRegistryServiceReq = {
90
95
  workspaceId?: string
91
96
  registryId?: string
97
+ kubernetesClusterName?: string
98
+ kubernetesNamespaceName?: string
99
+ registryName?: string
100
+ nacosNamespaceName?: string
101
+ registryType?: ListRegistryServiceReqRegistryType
92
102
  serviceName?: string
93
103
  page?: number
94
104
  pageSize?: number
@@ -115,6 +125,7 @@ export type RegistryServiceInfo = {
115
125
  kubernetesPorts?: string[]
116
126
  kubernetesLabels?: string[]
117
127
  registryType?: RegistryServiceInfoRegistryType
128
+ isHosted?: boolean
118
129
  }
119
130
 
120
131
  export type ListMeshServiceRes = {
@@ -101,6 +101,12 @@ export type AdvancedAPIConfig = {
101
101
  requestHeadersPolicy?: HeaderPolicy
102
102
  responseHeadersPolicy?: HeaderPolicy
103
103
  jwtPolicy?: JWTPolicy
104
+ authPolicy?: AuthPolicy
105
+ }
106
+
107
+ export type AuthPolicy = {
108
+ context?: {[key: string]: string}
109
+ disabled?: boolean
104
110
  }
105
111
 
106
112
  export type JWTPolicy = {
@@ -21,6 +21,7 @@ export enum ServiceSource {
21
21
  SOURCE_MESH = "SOURCE_MESH",
22
22
  SOURCE_REGISTRY = "SOURCE_REGISTRY",
23
23
  SOURCE_EXTERNAL = "SOURCE_EXTERNAL",
24
+ SOURCE_HOSTED_REGISTRY = "SOURCE_HOSTED_REGISTRY",
24
25
  }
25
26
 
26
27
  export enum SesameServiceType {
@@ -168,7 +169,15 @@ type BaseExternalServiceConf = {
168
169
  }
169
170
 
170
171
  export type ExternalServiceConf = BaseExternalServiceConf
171
- & OneOf<{ kubernetesService: KubernetesService; registryService: RegistryService; externalService: ExternalService; meshService: MeshService }>
172
+ & OneOf<{ kubernetesService: KubernetesService; registryService: RegistryService; externalService: ExternalService; meshService: MeshService; hostedRegistryService: HostedRegistryService }>
173
+
174
+
175
+ type BaseHostedRegistryService = {
176
+ registrationName?: string
177
+ }
178
+
179
+ export type HostedRegistryService = BaseHostedRegistryService
180
+ & OneOf<{ eurekaService: EurekaService; nacosService: NacosService; zookeeperService: ZookeeperService; kubernetesService: KubernetesService; meshService: MeshService }>
172
181
 
173
182
  export type CircuitBreakerPolicy = {
174
183
  maxConnections?: number
@@ -100,15 +100,13 @@ export type Nacos = {
100
100
  version?: string
101
101
  nodeCount?: number
102
102
  healthNodeCount?: number
103
- serviceCount?: number
104
- configCount?: number
105
- insightEnabled?: boolean
106
103
  database?: NacosDatabase
107
104
  resources?: SkoalaApiGeneralV1alpha1Resource.ResourceRequirements
108
105
  condition?: NacosCondition[]
109
106
  certificationEnabled?: boolean
110
107
  volume?: Volume
111
108
  createAt?: string
109
+ insight?: SkoalaApiGeneralV1alpha1Insight.NacosInsightMetrics
112
110
  }
113
111
 
114
112
  export type NacosDatabase = {
@@ -845,22 +843,4 @@ export type GetNacosGrafanaReq = {
845
843
  export type GetNacosGrafanaRes = {
846
844
  url?: string
847
845
  zhUrl?: string
848
- }
849
-
850
- export type NacosDashBoardReq = {
851
- workspaceId?: string
852
- isHosted?: boolean
853
- }
854
-
855
- export type NacosDashBoardRessvcCount = {
856
- count?: number
857
- name?: string
858
- }
859
-
860
- export type NacosDashBoardRes = {
861
- total?: number
862
- health?: number
863
- serviceCount?: number
864
- configCount?: number
865
- serviceRanking?: NacosDashBoardRessvcCount[]
866
846
  }
@@ -45,6 +45,18 @@ export type VirtualhostConfig = {
45
45
  corsPolicy?: CorsPolicy
46
46
  tlsPolicy?: VirtualhostTLSPolicy
47
47
  jwtProviders?: JwtProvider[]
48
+ authPolicy?: AuthorizationPolicy
49
+ }
50
+
51
+ export type AuthorizationPolicy = {
52
+ disabled?: boolean
53
+ context?: {[key: string]: string}
54
+ authServer?: string
55
+ failOpen?: boolean
56
+ responseTimeout?: string
57
+ maxRequestBytes?: number
58
+ allowPartialMessage?: boolean
59
+ packAsBytes?: boolean
48
60
  }
49
61
 
50
62
  export type JwtProvider = {
@@ -101,6 +113,7 @@ export type VirtualhostInfo = {
101
113
  secretNamespaceName?: string
102
114
  healthCheckUrl?: string
103
115
  enableJWT?: boolean
116
+ enableAuth?: boolean
104
117
  namespaceName?: string
105
118
  apiCount?: number
106
119
  updatedAt?: string
@@ -130,6 +143,7 @@ export type GetVirtualhostRes = {
130
143
  corsPolicy?: CorsPolicy
131
144
  tlsPolicy?: VirtualhostTLSPolicy
132
145
  jwtProviders?: JwtProvider[]
146
+ authorizationPolicy?: AuthorizationPolicy
133
147
  }
134
148
 
135
149
  export type UpdateVirtualhostReq = {
@@ -208,10 +222,4 @@ export type LocalRateLimitPolicy = {
208
222
  export type TimeUnit = {
209
223
  time?: number
210
224
  unit?: TimeUnitUnit
211
- }
212
-
213
- export type Authorization = {
214
- }
215
-
216
- export type AuthPolicy = {
217
225
  }
@@ -250,9 +250,6 @@ export class Nacos {
250
250
  static CheckConfig(req: SkoalaApiHostedV1alpha1Nacos.CheckNacosConfigReq, initReq?: fm.InitReq): Promise<SkoalaApiHostedV1alpha1Nacos.CheckNacosConfigRes> {
251
251
  return fm.fetchReq<SkoalaApiHostedV1alpha1Nacos.CheckNacosConfigReq, SkoalaApiHostedV1alpha1Nacos.CheckNacosConfigRes>(`/apis/hive.skoala.io/v1alpha1/workspaces/${req["workspaceId"]}/clusters/${req["clusterName"]}/namespaces/${req["namespaceName"]}/nacoses/${req["nacosName"]}/namespaces/${req["nacosNamespace"]}/configs/${req["dataId"]}/check?${fm.renderURLSearchParams(req, ["workspaceId", "clusterName", "namespaceName", "nacosName", "nacosNamespace", "dataId"])}`, {...initReq, method: "GET"})
252
252
  }
253
- static GetNacosDashBoard(req: SkoalaApiHostedV1alpha1Nacos.NacosDashBoardReq, initReq?: fm.InitReq): Promise<SkoalaApiHostedV1alpha1Nacos.NacosDashBoardRes> {
254
- return fm.fetchReq<SkoalaApiHostedV1alpha1Nacos.NacosDashBoardReq, SkoalaApiHostedV1alpha1Nacos.NacosDashBoardRes>(`/apis/hive.skoala.io/v1alpha1/workspaces/${req["workspaceId"]}/nacos_dashboard?${fm.renderURLSearchParams(req, ["workspaceId"])}`, {...initReq, method: "GET"})
255
- }
256
253
  }
257
254
  export class Sentinel {
258
255
  static GetInsGovern(req: SkoalaApiHostedV1alpha1Sentinel.GetInsGovernReq, initReq?: fm.InitReq): Promise<SkoalaApiHostedV1alpha1Sentinel.GetInsGovernRes> {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@daocloud-proto/skoala",
3
- "version": "0.14.0-8",
3
+ "version": "0.15.0",
4
4
  "description": "",
5
5
  "main": "index.js",
6
6
  "scripts": {