Now that we have all the resources installed for Istio, we will use sample application called BookInfo to review key capabilities of the service mesh such as intelligent routing, and review telemetry data using Prometheus & Grafana.
The Bookinfo application is broken into four separate microservices:
productpage
details
reviews
ratings
There are 3 versions of the reviews microservice:
Version v1
Version v2
Version v3
Deploy sample apps by manually injecting istio proxy and confirm pods, services are running correctly
kubectl apply -f <(istioctl kube-inject -f samples/bookinfo/platform/kube/bookinfo.yaml)
The output from
kubectl get pod,svc
Should look similar to:
Next we’ll define the virtual service and ingress gateway:
kubectl apply -f samples/bookinfo/networking/bookinfo-gateway.yaml
Next, we’ll query the DNS name of the ingress gateway and use it to connect via the browser.
kubectl get service istio-ingressgateway -o jsonpath='{.status.loadBalancer.ingress[0].hostname}' -n istio-system ; echo
This may take a minute or two, first for the Ingress to be created, and secondly for the Ingress to hook up with the services it exposes.
To test, do the following:
get service istiogateway
commandRemember to add /productpage to the end of the URI in the browser to see the sample webpage!
Click reload multiple times to see how the layout and content of the reviews changes as differnt versions (v1, v2, v3) of the app are called.