mirror of
https://github.com/alibaba/higress.git
synced 2026-04-21 03:57:28 +08:00
upgrade to istio 1.19 (#1211)
Co-authored-by: CH3CHO <ch3cho@qq.com> Co-authored-by: rinfx <893383980@qq.com>
This commit is contained in:
@@ -84,4 +84,4 @@ spec:
|
||||
overwrite: true
|
||||
ingress:
|
||||
- higress-conformance-infra/wasmplugin-ai-proxy-qwen
|
||||
url: file:///opt/plugins/wasm-go/extensions/ai-proxy/plugin.wasm
|
||||
url: oci://higress-registry.cn-hangzhou.cr.aliyuncs.com/plugins/ai-proxy:1.0.0
|
||||
|
||||
@@ -53,4 +53,4 @@ spec:
|
||||
configDisable: false
|
||||
ingress:
|
||||
- higress-conformance-infra/wasmplugin-basic-auth
|
||||
url: file:///opt/plugins/wasm-go/extensions/basic-auth/plugin.wasm
|
||||
url: oci://higress-registry.cn-hangzhou.cr.aliyuncs.com/plugins/go-basic-auth:1.0.0
|
||||
|
||||
@@ -50,4 +50,4 @@ spec:
|
||||
configDisable: false
|
||||
ingress:
|
||||
- higress-conformance-infra/wasmplugin-bot-detect
|
||||
url: file:///opt/plugins/wasm-go/extensions/bot-detect/plugin.wasm
|
||||
url: oci://higress-registry.cn-hangzhou.cr.aliyuncs.com/plugins/go-bot-detect:1.0.0
|
||||
|
||||
@@ -45,4 +45,4 @@ spec:
|
||||
configDisable: false
|
||||
ingress:
|
||||
- higress-conformance-infra/wasmplugin-cache-control
|
||||
url: file:///opt/plugins/wasm-go/extensions/cache-control/plugin.wasm
|
||||
url: oci://higress-registry.cn-hangzhou.cr.aliyuncs.com/plugins/cache-control:1.0.0
|
||||
|
||||
@@ -94,7 +94,7 @@ spec:
|
||||
headers:
|
||||
- key5=value5
|
||||
"body": "{\"hello\":\"qux\"}"
|
||||
url: file:///opt/plugins/wasm-go/extensions/custom-response/plugin.wasm
|
||||
url: oci://higress-registry.cn-hangzhou.cr.aliyuncs.com/plugins/go-custom-response:1.0.0
|
||||
---
|
||||
# test enable_on_status 401
|
||||
apiVersion: extensions.higress.io/v1alpha1
|
||||
@@ -115,4 +115,4 @@ spec:
|
||||
- consumer1
|
||||
domain:
|
||||
- baz.com
|
||||
url: file:///opt/plugins/wasm-go/extensions/basic-auth/plugin.wasm
|
||||
url: oci://higress-registry.cn-hangzhou.cr.aliyuncs.com/plugins/basic-auth:1.0.0
|
||||
|
||||
@@ -43,4 +43,4 @@ spec:
|
||||
allow:
|
||||
- 192.168.0.1/16
|
||||
- 10.0.0.1
|
||||
url: file:///opt/plugins/wasm-go/extensions/ip-restriction/plugin.wasm
|
||||
url: oci://higress-registry.cn-hangzhou.cr.aliyuncs.com/plugins/ip-restriction:1.0.0
|
||||
|
||||
@@ -43,4 +43,4 @@ spec:
|
||||
deny:
|
||||
- 192.168.0.1/16
|
||||
- 10.0.0.1
|
||||
url: file:///opt/plugins/wasm-go/extensions/ip-restriction/plugin.wasm
|
||||
url: oci://higress-registry.cn-hangzhou.cr.aliyuncs.com/plugins/ip-restriction:1.0.0
|
||||
|
||||
@@ -139,4 +139,4 @@ spec:
|
||||
configDisable: false
|
||||
ingress:
|
||||
- higress-conformance-infra/wasmplugin-jwt-auth
|
||||
url: file:///opt/plugins/wasm-go/extensions/jwt-auth/plugin.wasm
|
||||
url: oci://higress-registry.cn-hangzhou.cr.aliyuncs.com/plugins/go-jwt-auth:1.0.0
|
||||
|
||||
@@ -128,4 +128,4 @@ spec:
|
||||
configDisable: false
|
||||
ingress:
|
||||
- higress-conformance-infra/wasmplugin-jwt-auth
|
||||
url: file:///opt/plugins/wasm-go/extensions/jwt-auth/plugin.wasm
|
||||
url: oci://higress-registry.cn-hangzhou.cr.aliyuncs.com/plugins/go-jwt-auth:1.0.0
|
||||
|
||||
@@ -125,4 +125,4 @@ spec:
|
||||
configDisable: false
|
||||
ingress:
|
||||
- higress-conformance-infra/wasmplugin-jwt-auth
|
||||
url: file:///opt/plugins/wasm-go/extensions/jwt-auth/plugin.wasm
|
||||
url: oci://higress-registry.cn-hangzhou.cr.aliyuncs.com/plugins/go-jwt-auth:1.0.0
|
||||
|
||||
@@ -57,4 +57,4 @@ spec:
|
||||
configDisable: false
|
||||
ingress:
|
||||
- higress-conformance-infra/wasmplugin-key-auth
|
||||
url: file:///opt/plugins/wasm-go/extensions/key-auth/plugin.wasm
|
||||
url: oci://higress-registry.cn-hangzhou.cr.aliyuncs.com/plugins/go-key-auth:1.0.0
|
||||
|
||||
@@ -45,4 +45,4 @@ spec:
|
||||
servicePort: 8181
|
||||
policy: example1
|
||||
timeout: 5s
|
||||
url: file:///opt/plugins/wasm-go/extensions/opa/plugin.wasm
|
||||
url: oci://higress-registry.cn-hangzhou.cr.aliyuncs.com/plugins/opa:1.0.0
|
||||
|
||||
@@ -69,4 +69,4 @@ spec:
|
||||
- "/web/info"
|
||||
block_bodies:
|
||||
- "hello world"
|
||||
url: file:///opt/plugins/wasm-go/extensions/request-block/plugin.wasm
|
||||
url: oci://higress-registry.cn-hangzhou.cr.aliyuncs.com/plugins/go-request-block:1.0.0
|
||||
|
||||
@@ -94,4 +94,4 @@ spec:
|
||||
rejected_msg: "customize reject message"
|
||||
enable_swagger: true
|
||||
enable_oas3: false
|
||||
url: file:///opt/plugins/wasm-go/extensions/request-validation/plugin.wasm
|
||||
url: oci://higress-registry.cn-hangzhou.cr.aliyuncs.com/plugins/request-validation:1.0.0
|
||||
|
||||
@@ -40,4 +40,4 @@ spec:
|
||||
defaultConfig:
|
||||
token_headers: token
|
||||
token_secret_key: Dav7kfq3iA8S!JUj8&CUkdnQe72E@Cw6
|
||||
url: file:///opt/plugins/wasm-go/extensions/simple-jwt-auth/plugin.wasm
|
||||
url: oci://higress-registry.cn-hangzhou.cr.aliyuncs.com/plugins/simple-jwt-auth:1.0.0
|
||||
|
||||
@@ -43,4 +43,4 @@ metadata:
|
||||
name: sni-misdirect
|
||||
namespace: higress-system
|
||||
spec:
|
||||
url: file:///opt/plugins/wasm-go/extensions/sni-misdirect/plugin.wasm
|
||||
url: oci://higress-registry.cn-hangzhou.cr.aliyuncs.com/plugins/go-sni-misdirect:1.0.0
|
||||
|
||||
@@ -569,4 +569,4 @@ spec:
|
||||
strategy: RETAIN_LAST
|
||||
- key: X-dedupe-unique
|
||||
strategy: RETAIN_UNIQUE
|
||||
url: file:///opt/plugins/wasm-go/extensions/transformer/plugin.wasm
|
||||
url: oci://higress-registry.cn-hangzhou.cr.aliyuncs.com/plugins/transformer:1.0.0
|
||||
|
||||
@@ -34,6 +34,20 @@ spec:
|
||||
paramType: "java.lang.String"
|
||||
---
|
||||
apiVersion: networking.higress.io/v1
|
||||
kind: McpBridge
|
||||
metadata:
|
||||
name: default
|
||||
namespace: higress-system
|
||||
spec:
|
||||
registries:
|
||||
- domain: nacos-standlone-rc3-service.higress-conformance-app-backend
|
||||
nacosGroups:
|
||||
- DEFAULT_GROUP
|
||||
name: nacos-service-resource
|
||||
port: 8848
|
||||
type: nacos
|
||||
---
|
||||
apiVersion: networking.higress.io/v1
|
||||
kind: Http2Rpc
|
||||
metadata:
|
||||
name: httproute-http2rpc-healthservice
|
||||
@@ -84,3 +98,25 @@ spec:
|
||||
apiGroup: networking.higress.io
|
||||
kind: McpBridge
|
||||
name: default
|
||||
---
|
||||
apiVersion: networking.k8s.io/v1
|
||||
kind: Ingress
|
||||
metadata:
|
||||
annotations:
|
||||
higress.io/destination: providers:com.dubbo.demo.api.DemoService:1.0.0:dev.DEFAULT-GROUP.public.nacos
|
||||
higress.io/rpc-destination-name: httproute-http2rpc-demo
|
||||
name: httproute-http2rpc-demo-ingress
|
||||
namespace: higress-system
|
||||
spec:
|
||||
ingressClassName: higress
|
||||
rules:
|
||||
- host: "foo.com"
|
||||
http:
|
||||
paths:
|
||||
- pathType: Prefix
|
||||
path: /dubbo
|
||||
backend:
|
||||
resource:
|
||||
apiGroup: networking.higress.io
|
||||
kind: McpBridge
|
||||
name: default
|
||||
|
||||
@@ -1,34 +0,0 @@
|
||||
# Copyright (c) 2022 Alibaba Group Holding Ltd.
|
||||
#
|
||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||
# you may not use this file except in compliance with the License.
|
||||
# You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
apiVersion: networking.higress.io/v1
|
||||
kind: Http2Rpc
|
||||
metadata:
|
||||
name: httproute-http2rpc-demo
|
||||
namespace: higress-system
|
||||
spec:
|
||||
dubbo:
|
||||
service: com.dubbo.demo.api.DemoService
|
||||
version: 1.0.0
|
||||
group: dev
|
||||
methods:
|
||||
- serviceMethod: sayHello
|
||||
headersAttach: "*"
|
||||
httpMethods:
|
||||
- GET
|
||||
httpPath: "/dubbo/hello_update"
|
||||
params:
|
||||
- paramKey: name
|
||||
paramSource: QUERY
|
||||
paramType: "java.lang.String"
|
||||
@@ -24,7 +24,6 @@ import (
|
||||
func init() {
|
||||
Register(HTTPRouteHttp2RpcCreate)
|
||||
Register(HTTPRouteHttp2RpcUpdate)
|
||||
Register(HTTPRouteHttp2RpcDelete)
|
||||
}
|
||||
|
||||
var HTTPRouteHttp2RpcCreate = suite.ConformanceTest{
|
||||
@@ -77,7 +76,7 @@ var HTTPRouteHttp2RpcUpdate = suite.ConformanceTest{
|
||||
Response: http.AssertionResponse{
|
||||
ExpectedResponseNoRequest: true,
|
||||
ExpectedResponse: http.Response{
|
||||
StatusCode: 200,
|
||||
StatusCode: 500,
|
||||
},
|
||||
},
|
||||
},
|
||||
@@ -92,68 +91,7 @@ var HTTPRouteHttp2RpcUpdate = suite.ConformanceTest{
|
||||
Response: http.AssertionResponse{
|
||||
ExpectedResponseNoRequest: true,
|
||||
ExpectedResponse: http.Response{
|
||||
StatusCode: 404,
|
||||
},
|
||||
},
|
||||
},
|
||||
{
|
||||
Request: http.AssertionRequest{
|
||||
ActualRequest: http.Request{
|
||||
Host: "foo.com",
|
||||
Path: "/dubbo/health/readiness?type=readiness",
|
||||
Method: "GET",
|
||||
},
|
||||
},
|
||||
Response: http.AssertionResponse{
|
||||
ExpectedResponseNoRequest: true,
|
||||
ExpectedResponse: http.Response{
|
||||
StatusCode: 200,
|
||||
},
|
||||
},
|
||||
},
|
||||
{
|
||||
Request: http.AssertionRequest{
|
||||
ActualRequest: http.Request{
|
||||
Host: "foo.com",
|
||||
Path: "/dubbo/health/liveness?type=liveness",
|
||||
Method: "GET",
|
||||
},
|
||||
},
|
||||
Response: http.AssertionResponse{
|
||||
ExpectedResponseNoRequest: true,
|
||||
ExpectedResponse: http.Response{
|
||||
StatusCode: 200,
|
||||
},
|
||||
},
|
||||
},
|
||||
}
|
||||
t.Run("HTTPRoute uses HTTP to RPC", func(t *testing.T) {
|
||||
for _, testcase := range testcases {
|
||||
http.MakeRequestAndExpectEventuallyConsistentResponse(t, suite.RoundTripper, suite.TimeoutConfig, suite.GatewayAddress, testcase)
|
||||
}
|
||||
})
|
||||
},
|
||||
}
|
||||
|
||||
var HTTPRouteHttp2RpcDelete = suite.ConformanceTest{
|
||||
ShortName: "HTTPRouteHttp2RpcDelete",
|
||||
Description: "The Ingress in the higress-conformance-infra namespace test delete the http2rpc.",
|
||||
PreDeleteRs: []string{"tests/httproute-http2rpc-2-delete.yaml"},
|
||||
Features: []suite.SupportedFeature{suite.DubboConformanceFeature, suite.NacosConformanceFeature},
|
||||
Test: func(t *testing.T, suite *suite.ConformanceTestSuite) {
|
||||
testcases := []http.Assertion{
|
||||
{
|
||||
Request: http.AssertionRequest{
|
||||
ActualRequest: http.Request{
|
||||
Host: "foo.com",
|
||||
Path: "/dubbo/hello_update?name=higress",
|
||||
Method: "GET",
|
||||
},
|
||||
},
|
||||
Response: http.AssertionResponse{
|
||||
ExpectedResponseNoRequest: true,
|
||||
ExpectedResponse: http.Response{
|
||||
StatusCode: 404,
|
||||
StatusCode: 200,
|
||||
},
|
||||
},
|
||||
},
|
||||
|
||||
@@ -19,7 +19,7 @@ import (
|
||||
"testing"
|
||||
"time"
|
||||
|
||||
"github.com/alibaba/higress/cmd/hgctl/config"
|
||||
"github.com/alibaba/higress/hgctl/cmd/hgctl/config"
|
||||
cfg "github.com/alibaba/higress/test/e2e/conformance/utils/config"
|
||||
"github.com/tidwall/gjson"
|
||||
"k8s.io/apimachinery/pkg/util/wait"
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
|
||||
package suite
|
||||
|
||||
import "istio.io/istio/pilot/pkg/util/sets"
|
||||
import "istio.io/istio/pkg/util/sets"
|
||||
|
||||
type SupportedFeature string
|
||||
|
||||
@@ -44,7 +44,7 @@ var WasmPluginTypeMap = map[string]SupportedFeature{
|
||||
"RUST": WASMRustConformanceFeature,
|
||||
}
|
||||
|
||||
var AllFeatures = sets.Set{}.
|
||||
var AllFeatures = sets.Set[string]{}.
|
||||
Insert(string(HTTPConformanceFeature)).
|
||||
Insert(string(DubboConformanceFeature)).
|
||||
Insert(string(EurekaConformanceFeature)).
|
||||
@@ -52,7 +52,7 @@ var AllFeatures = sets.Set{}.
|
||||
Insert(string(NacosConformanceFeature)).
|
||||
Insert(string(EnvoyConfigConformanceFeature))
|
||||
|
||||
var ExperimentFeatures = sets.Set{}.
|
||||
var ExperimentFeatures = sets.Set[string]{}.
|
||||
Insert(string(WASMGoConformanceFeature)).
|
||||
Insert(string(WASMCPPConformanceFeature)).
|
||||
Insert(string(WASMRustConformanceFeature))
|
||||
|
||||
@@ -21,7 +21,7 @@ import (
|
||||
"github.com/alibaba/higress/test/e2e/conformance/utils/config"
|
||||
"github.com/alibaba/higress/test/e2e/conformance/utils/kubernetes"
|
||||
"github.com/alibaba/higress/test/e2e/conformance/utils/roundtripper"
|
||||
"istio.io/istio/pilot/pkg/util/sets"
|
||||
"istio.io/istio/pkg/util/sets"
|
||||
"sigs.k8s.io/controller-runtime/pkg/client"
|
||||
)
|
||||
|
||||
@@ -43,16 +43,16 @@ type ConformanceTestSuite struct {
|
||||
Cleanup bool
|
||||
BaseManifests []string
|
||||
Applier kubernetes.Applier
|
||||
SkipTests sets.Set
|
||||
ExecuteTests sets.Set
|
||||
SkipTests sets.Set[string]
|
||||
ExecuteTests sets.Set[string]
|
||||
TimeoutConfig config.TimeoutConfig
|
||||
SupportedFeatures sets.Set
|
||||
SupportedFeatures sets.Set[string]
|
||||
}
|
||||
|
||||
// Options can be used to initialize a ConformanceTestSuite.
|
||||
type Options struct {
|
||||
SupportedFeatures sets.Set
|
||||
ExemptFeatures sets.Set
|
||||
SupportedFeatures sets.Set[string]
|
||||
ExemptFeatures sets.Set[string]
|
||||
ExecuteTests string
|
||||
|
||||
EnableAllSupportedFeatures bool
|
||||
@@ -91,7 +91,7 @@ func New(s Options) *ConformanceTestSuite {
|
||||
}
|
||||
|
||||
if s.SupportedFeatures == nil {
|
||||
s.SupportedFeatures = sets.Set{}
|
||||
s.SupportedFeatures = sets.Set[string]{}
|
||||
}
|
||||
|
||||
if s.IsWasmPluginTest {
|
||||
@@ -120,7 +120,7 @@ func New(s Options) *ConformanceTestSuite {
|
||||
BaseManifests: s.BaseManifests,
|
||||
SupportedFeatures: s.SupportedFeatures,
|
||||
GatewayAddress: s.GatewayAddress,
|
||||
ExecuteTests: sets.NewSet(),
|
||||
ExecuteTests: sets.New[string](),
|
||||
Applier: kubernetes.Applier{
|
||||
NamespaceLabels: s.NamespaceLabels,
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user