@daocloud-proto/skoala 0.32.0 → 0.33.0-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.
|
@@ -18,6 +18,21 @@ type OneOf<T> =
|
|
|
18
18
|
: never)
|
|
19
19
|
: never);
|
|
20
20
|
|
|
21
|
+
export enum HeaderSendMode {
|
|
22
|
+
HEADER_SEND_MODE_UNSPECIFIED = "HEADER_SEND_MODE_UNSPECIFIED",
|
|
23
|
+
ProcessingModeDefault = "ProcessingModeDefault",
|
|
24
|
+
ProcessingModeSend = "ProcessingModeSend",
|
|
25
|
+
ProcessingModeSkip = "ProcessingModeSkip",
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
export enum BodySendMode {
|
|
29
|
+
BODY_SEND_MODE_UNSPECIFIED = "BODY_SEND_MODE_UNSPECIFIED",
|
|
30
|
+
ProcessingModeNone = "ProcessingModeNone",
|
|
31
|
+
ProcessingModeStreamed = "ProcessingModeStreamed",
|
|
32
|
+
ProcessingModeBuffered = "ProcessingModeBuffered",
|
|
33
|
+
ProcessingModeBufferedPartial = "ProcessingModeBufferedPartial",
|
|
34
|
+
}
|
|
35
|
+
|
|
21
36
|
export enum HttpRetryOnEnum {
|
|
22
37
|
five_xx = "five_xx",
|
|
23
38
|
gateway_error = "gateway_error",
|
|
@@ -153,6 +168,24 @@ export type PathRewritePolicy = {
|
|
|
153
168
|
replacement?: string
|
|
154
169
|
}
|
|
155
170
|
|
|
171
|
+
export type ProcessingMode = {
|
|
172
|
+
requestHeaderMode?: HeaderSendMode
|
|
173
|
+
responseHeaderMode?: HeaderSendMode
|
|
174
|
+
requestBodyMode?: BodySendMode
|
|
175
|
+
responseBodyMode?: BodySendMode
|
|
176
|
+
requestTrailerMode?: HeaderSendMode
|
|
177
|
+
responseTrailerMode?: HeaderSendMode
|
|
178
|
+
}
|
|
179
|
+
|
|
180
|
+
export type ExtProcOverride = {
|
|
181
|
+
processingMode?: ProcessingMode
|
|
182
|
+
pluginName?: string
|
|
183
|
+
}
|
|
184
|
+
|
|
185
|
+
export type ExtProcPolicy = {
|
|
186
|
+
overrides?: ExtProcOverride
|
|
187
|
+
}
|
|
188
|
+
|
|
156
189
|
export type AdvancedAPIConfig = {
|
|
157
190
|
loadBalancePolicy?: LoadBalancePolicy
|
|
158
191
|
timeoutPolicy?: TimeoutPolicy
|
|
@@ -168,6 +201,7 @@ export type AdvancedAPIConfig = {
|
|
|
168
201
|
cookieRewritePolicy?: CookieRewritePolicy[]
|
|
169
202
|
ipPolicy?: SkoalaApiHostedV1alpha1Gateway.IPPolicy
|
|
170
203
|
domainIpPolicyStatus?: SkoalaApiHostedV1alpha1Gateway.IPPolicyStatus
|
|
204
|
+
extProcPolicy?: ExtProcPolicy
|
|
171
205
|
}
|
|
172
206
|
|
|
173
207
|
export type CookieRewritePolicy = {
|
|
@@ -20,6 +20,7 @@ export enum PluginType {
|
|
|
20
20
|
AUTH = "AUTH",
|
|
21
21
|
RATELIMIT = "RATELIMIT",
|
|
22
22
|
WASM = "WASM",
|
|
23
|
+
EXTPROC = "EXTPROC",
|
|
23
24
|
UNDEFINE = "UNDEFINE",
|
|
24
25
|
}
|
|
25
26
|
|
|
@@ -44,7 +45,7 @@ type BaseCreateSkoalaPluginReq = {
|
|
|
44
45
|
}
|
|
45
46
|
|
|
46
47
|
export type CreateSkoalaPluginReq = BaseCreateSkoalaPluginReq
|
|
47
|
-
& OneOf<{ jwt: JWTPluginConfig; auth: AuthPluginConfig; rateLimit: RateLimitPluginConfig; wasm: WasmPluginConfig }>
|
|
48
|
+
& OneOf<{ jwt: JWTPluginConfig; auth: AuthPluginConfig; rateLimit: RateLimitPluginConfig; wasm: WasmPluginConfig; extProc: ExtProcPluginConfig }>
|
|
48
49
|
|
|
49
50
|
export type UpdateUsage = {
|
|
50
51
|
}
|
|
@@ -64,7 +65,7 @@ type BaseUpdateSkoalaPluginReq = {
|
|
|
64
65
|
}
|
|
65
66
|
|
|
66
67
|
export type UpdateSkoalaPluginReq = BaseUpdateSkoalaPluginReq
|
|
67
|
-
& OneOf<{ jwt: JWTPluginConfig; auth: AuthPluginConfig; rateLimit: RateLimitPluginConfig; wasm: WasmPluginConfig }>
|
|
68
|
+
& OneOf<{ jwt: JWTPluginConfig; auth: AuthPluginConfig; rateLimit: RateLimitPluginConfig; wasm: WasmPluginConfig; extProc: ExtProcPluginConfig }>
|
|
68
69
|
|
|
69
70
|
export type DeleteSkoalaPluginReq = {
|
|
70
71
|
workspaceId?: string
|
|
@@ -91,7 +92,7 @@ type BaseGetSkoalaPluginRes = {
|
|
|
91
92
|
}
|
|
92
93
|
|
|
93
94
|
export type GetSkoalaPluginRes = BaseGetSkoalaPluginRes
|
|
94
|
-
& OneOf<{ jwt: JWTPluginConfig; auth: AuthPluginConfig; rateLimit: RateLimitPluginConfig; wasm: WasmPluginConfig }>
|
|
95
|
+
& OneOf<{ jwt: JWTPluginConfig; auth: AuthPluginConfig; rateLimit: RateLimitPluginConfig; wasm: WasmPluginConfig; extProc: ExtProcPluginConfig }>
|
|
95
96
|
|
|
96
97
|
export type PluginUsage = {
|
|
97
98
|
resourceType?: PluginUsageResourceType
|
|
@@ -162,6 +163,13 @@ export type AuthPluginConfig = {
|
|
|
162
163
|
validation?: TLSValidation
|
|
163
164
|
}
|
|
164
165
|
|
|
166
|
+
export type ExtProcPluginConfig = {
|
|
167
|
+
pluginAddress?: PluginAddress
|
|
168
|
+
timeout?: IntervalTimeUnit
|
|
169
|
+
failOpen?: boolean
|
|
170
|
+
validation?: TLSValidation
|
|
171
|
+
}
|
|
172
|
+
|
|
165
173
|
export type JWTPluginConfigJWTValidExtConfig = {
|
|
166
174
|
issuer?: string
|
|
167
175
|
audiences?: string[]
|
|
@@ -132,7 +132,7 @@ export type UpdateRegistryReq = {
|
|
|
132
132
|
registryId?: string
|
|
133
133
|
extId?: string
|
|
134
134
|
name?: string
|
|
135
|
-
type?:
|
|
135
|
+
type?: RegistryType
|
|
136
136
|
addresses?: string[]
|
|
137
137
|
namespaces?: Namespace[]
|
|
138
138
|
isHosted?: boolean
|
|
@@ -145,7 +145,7 @@ export type CreateRegistryReq = {
|
|
|
145
145
|
workspaceId?: string
|
|
146
146
|
name?: string
|
|
147
147
|
extId?: string
|
|
148
|
-
type?:
|
|
148
|
+
type?: RegistryType
|
|
149
149
|
addresses?: string[]
|
|
150
150
|
namespaces?: Namespace[]
|
|
151
151
|
isHosted?: boolean
|
|
@@ -161,7 +161,7 @@ export type DeleteRegistryReq = {
|
|
|
161
161
|
|
|
162
162
|
export type PingRegistryReq = {
|
|
163
163
|
workspaceId?: string
|
|
164
|
-
type?:
|
|
164
|
+
type?: RegistryType
|
|
165
165
|
name?: string
|
|
166
166
|
addresses?: string[]
|
|
167
167
|
namespaces?: Namespace[]
|
|
@@ -186,7 +186,7 @@ export class Nacos {
|
|
|
186
186
|
return fm.fetchReq<SkoalaApiHostedV1alpha1Nacos.UpdateNacosReq, GoogleProtobufEmpty.Empty>(`/apis/hive.skoala.io/v1alpha1/workspaces/${req["workspaceId"]}/clusters/${req["clusterName"]}/namespaces/${req["namespaceName"]}/nacoses/${req["nacosName"]}`, {...initReq, method: "PUT", body: JSON.stringify(req, fm.replacer)})
|
|
187
187
|
}
|
|
188
188
|
static Delete(req: SkoalaApiHostedV1alpha1Nacos.DeleteNacosReq, initReq?: fm.InitReq): Promise<GoogleProtobufEmpty.Empty> {
|
|
189
|
-
return fm.fetchReq<SkoalaApiHostedV1alpha1Nacos.DeleteNacosReq, GoogleProtobufEmpty.Empty>(`/apis/hive.skoala.io/v1alpha1/workspaces/${req["workspaceId"]}/clusters/${req["clusterName"]}/namespaces/${req["namespaceName"]}/nacoses/${req["nacosName"]}`, {...initReq, method: "DELETE"})
|
|
189
|
+
return fm.fetchReq<SkoalaApiHostedV1alpha1Nacos.DeleteNacosReq, GoogleProtobufEmpty.Empty>(`/apis/hive.skoala.io/v1alpha1/workspaces/${req["workspaceId"]}/clusters/${req["clusterName"]}/namespaces/${req["namespaceName"]}/nacoses/${req["nacosName"]}`, {...initReq, method: "DELETE", body: JSON.stringify(req, fm.replacer)})
|
|
190
190
|
}
|
|
191
191
|
static Restart(req: SkoalaApiHostedV1alpha1Nacos.RestartNacosReq, initReq?: fm.InitReq): Promise<GoogleProtobufEmpty.Empty> {
|
|
192
192
|
return fm.fetchReq<SkoalaApiHostedV1alpha1Nacos.RestartNacosReq, GoogleProtobufEmpty.Empty>(`/apis/hive.skoala.io/v1alpha1/workspaces/${req["workspaceId"]}/clusters/${req["clusterName"]}/namespaces/${req["namespaceName"]}/nacoses/${req["nacosName"]}/restart?${fm.renderURLSearchParams(req, ["workspaceId", "clusterName", "namespaceName", "nacosName"])}`, {...initReq, method: "GET"})
|