Hi,
I am trying to establish communication between ServiceA and ServiceB.
The issue that I am facing is that ServiceA istio-proxy is not able to match the route rule and the request does not reach ServiceB.
To achieve this goal, created virtual virtualservice based on the HTTP match filters as follows:
apiVersion: networking.istio.io/v1alpha3
kind: VirtualService
metadata:
name: serviceA
namespace: default
spec:
gateways:
- mesh
hosts: - serviceA-service.default.svc.cluster.local
http: - match:
- uri:
prefix: /deviceData
route: - destination:
host: serviceB-service.default.svc.cluster.local
port:
number: 8888
- uri:
The router debug logs at the istio-proxy(envoyproxy) of ServiceA for the pod under interest shows the following log:
[2019-01-14 17:24:06.025][18][debug][router] external/envoy/source/common/router/router.cc:211] [C97][S13446136181091525502] no cluster match for URL ‘/deviceData/operationalData/10.56.0.1’
I also checked the istio-proxy proxy-config routes and it shows the following information:
[root@centos-dev istio-yaml]# istioctl proxy-config routes serviceA-68998fd5ff-v47b7 --name 8888 -o json
[
{
“name”: “8888”,
“virtualHosts”: [
{
“name”: “serviceB.default.svc.cluster.local:8888”,
“domains”: [
“serviceB.default.svc.cluster.local”,
“serviceB.default.svc.cluster.local:8888”,
“serviceB”,
“serviceB:8888”,
“serviceB.default.svc.cluster”,
“serviceB.default.svc.cluster:8888”,
“serviceB.default.svc”,
“serviceB.default.svc:8888”,
“serviceB.default”,
“serviceB.default:8888”,
“10.59.241.3”,
“10.59.241.3:8888”
],
“routes”: [
{
“match”: {
“prefix”: “/deviceData”
},
“route”: {
“cluster”: “outbound|8888||serviceB.default.svc.cluster.local”,
“timeout”: “0.000s”,
“maxGrpcTimeout”: “0.000s”
},
“decorator”: {
“operation”: “serviceB.default.svc.cluster.local:8888/deviceData*”
},
Can you please help and let me know what I’m missing.
Thanks,
Poojan.