istio:
If you want use the gateway api recoures "Httproute" to Traffic Shifting your app flow rate,
Here is a yaml about Traffic Shifting within istio.
apiVersion: gateway.networking.k8s.io/v1beta1
kind: HTTPRoute
...
spec:
parentRefs:
- group: ""
kind: Service
name: reviews
port: 9080
rules:
- backendRefs:
- group: ""
kind: Service
name: reviews-v1
port: 9080
weight: 50
- group: ""
kind: Service
name: reviews-v3
port: 9080
weight: 50
matches:
- path:
type: PathPrefix
value: /
the will lei flow rate %50 to service reviews-v1 and %50 to service reviews-v3.
You can refresh the website to see what happening .
And if you service reviews-v3 is working and have no bug ,you can lei flow rate %100 to reviews-v3.
like :
apiVersion: gateway.networking.k8s.io/v1beta1
kind: HTTPRoute
...
spec:
parentRefs:
- group: ""
kind: Service
name: reviews
port: 9080
rules:
- backendRefs:
- group: ""
kind: Service
name: reviews-v3
port: 9080
matches:
- path:
type: PathPrefix
value: /