Skip to content

Commit ab707c1

Browse files
geremyCohenbrentley
authored andcommitted
Istiotweaks (#153)
* Update _index.md Fixing some grammar and typos. * Update introduction.md Fixed some formatting and grammar. * Update install.md Cleaning up formatting and grammar. * Update deploy.md Fixed grammar and formatting. * Update routing.md Grammar and typo fixes. * Update visualize.md fixed some grammar and typos * Update cleanup.md Cleaning up grammar and typos * Update routing.md Fixed error language message to better illustrate what to expect. * Update _index.md Removing callout
1 parent 0bdb6ae commit ab707c1

File tree

7 files changed

+61
-37
lines changed

7 files changed

+61
-37
lines changed

content/servicemesh/_index.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,15 @@
11
---
2-
title: "Servicemesh with Istio"
2+
title: "Service Mesh with Istio"
33
date: 2018-11-13T16:32:30+09:00
44
weight: 68
55
draft: false
66
---
77

88
### Service Mesh
99

10-
> A service mesh is a dedicated infrastructure layer for handling **service-to-service communication**. It’s responsible for the reliable delivery of requests through the complex topology of services that comprise a modern, cloud native application
10+
A service mesh is a dedicated infrastructure layer for handling **service-to-service communication**. It’s responsible for the reliable delivery of requests through the complex topology of services that comprise a modern, cloud native application.
1111

12-
Sservice mesh solution have two distinct components that behave somewhat differently: a data plane and a control plane. Below is an presents the basic architecture.
12+
Service mesh solutions have two distinct components that behave somewhat differently: 1) a data plane, and 2) a control plane. The following diagram illustrates the basic architecture.
1313

1414
![Service Mesh Architecture](/images/servicemesh-intro1.png)
1515

content/servicemesh/cleanup.md

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,29 +5,31 @@ weight: 70
55
draft: false
66
---
77

8-
#### Remove telemetry configuration / port-forward process
8+
To cleanup, follow the below steps.
9+
10+
To remove telemetry configuration / port-forward process
911

1012
```
1113
kubectl delete -f istio-telemetry.yaml
1214
```
1315

14-
#### Remove the application virtual services / destination rules
16+
To remove the application virtual services / destination rules
1517

1618
```
1719
kubectl delete -f samples/bookinfo/networking/virtual-service-all-v1.yaml
1820
1921
kubectl delete -f samples/bookinfo/networking/destination-rule-all.yaml
2022
```
2123

22-
#### Remove the gateway / application
24+
To remove the gateway / application
2325

2426
```
2527
kubectl delete -f samples/bookinfo/networking/bookinfo-gateway.yaml
2628
2729
kubectl delete -f samples/bookinfo/platform/kube/bookinfo.yaml
2830
```
2931

30-
#### Remove the Istio
32+
To remove Istio
3133

3234
```
3335
kubectl delete -f istio.yaml

content/servicemesh/deploy.md

Lines changed: 23 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ weight: 40
55
draft: false
66
---
77

8-
> Now that we have all the resources installed for Istio, we will use sample application called BookInfo to review key capabilities of Service Mesh such as intelligent routing and review telemetry data using Prometheus & Grafana.
8+
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.
99

1010
### Sample Apps
1111

@@ -47,7 +47,13 @@ Deploy sample apps by manually injecting istio proxy and confirm pods, services
4747
kubectl apply -f <(istioctl kube-inject -f samples/bookinfo/platform/kube/bookinfo.yaml)
4848
```
4949

50-
The output from 'kubectl get pod, svc' will look like this.
50+
The output from
51+
52+
```
53+
kubectl get pod,svc
54+
```
55+
56+
Should look similar to:
5157

5258
```
5359
NAME READY STATUS RESTARTS AGE
@@ -66,21 +72,31 @@ ratings ClusterIP 10.100.1.63 <none> 9080/TCP 17s
6672
reviews ClusterIP 10.100.255.157 <none> 9080/TCP 17s
6773
```
6874

69-
and define virtualservice, ingressgateway and find out ELB endpoint to get connected from your browser.
75+
Next we'll define the virtual service and ingress gateway:
7076

7177
```
7278
kubectl apply -f samples/bookinfo/networking/bookinfo-gateway.yaml
79+
```
7380

74-
kubectl get service istio-ingressgateway -o jsonpath='{.status.loadBalancer.ingress[0].hostname}' -n istio-system
81+
Next, we'll query the DNS name of the ingress gateway and use it to connect via the browser.
82+
83+
```
84+
kubectl get service istio-ingressgateway -o jsonpath='{.status.loadBalancer.ingress[0].hostname}' -n istio-system ; echo
7585
```
86+
7687
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.
7788

78-
Open a browser and connect to the endpoint that you get from istio-ingressgateway to see whether sample app is working.
89+
To test, do the following:
90+
91+
1. Open a new browser tab
92+
2. Paste the DNS endpoint returned from the previous ```get service istiogateway``` command
93+
3. Add /productpage to the end of that DNS endpoint
94+
4. Hit enter to retrieve the page.
7995

8096
{{% notice info %}}
81-
You have to add **/productpage** at the end of the URI in the browser to see the sample webpage
97+
Remember to add **/productpage** to the end of the URI in the browser to see the sample webpage!
8298
{{% /notice %}}
8399

84100
![Sample Apps](/images/servicemesh-deploy2.png)
85101

86-
> Iterate reloading the page and check out review section calls different versions of reviews (v1, v2, v3) each time
102+
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.

content/servicemesh/install.md

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,14 +6,13 @@ draft: false
66
---
77

88
### Install Istio's CRD
9-
The CRD(Custom Resource Definition) API resource allows you to define custom resources. To find more about CRD click [here](https://kubernetes.io/docs/concepts/extend-kubernetes/api-extension/custom-resources/#customresourcedefinitions).
10-
9+
The [Custom Resource Definition, also known as a CRD](https://kubernetes.io/docs/concepts/extend-kubernetes/api-extension/custom-resources/#customresourcedefinitions), is an API resource which allows you to define custom resources.
1110
```
1211
kubectl apply -f install/kubernetes/helm/istio/templates/crds.yaml
1312
```
1413

1514
### Install Istio
16-
Make sure you have Helm to install Istio into your EKS Cluster.
15+
Helm is required for the following examples. If you have not installed Helm yet, [please first reference the Helm chapter](/helm_root) before proceeding.
1716

1817
```
1918
kubectl create -f install/kubernetes/helm/helm-service-account.yaml
@@ -25,7 +24,13 @@ kubectl create namespace istio-system
2524
kubectl apply -f istio.yaml
2625
```
2726

28-
You can watch the progress of installation using 'kubectl get pod -n istio-system -w'
27+
Watch the progress of installation using:
28+
29+
```
30+
kubectl get pod -n istio-system -w
31+
```
32+
33+
And hit CTRL-C when you're ready to proceed.
2934

3035
```
3136
NAME READY STATUS RESTARTS AGE

content/servicemesh/introduction.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,12 +9,12 @@ draft: false
99

1010
![Istio Architecture](/images/servicemesh-intro2.png)
1111

12-
> Let's review in detail what each of these components are,
13-
>
14-
> It is a completely open source service mesh that layers transparently onto existing distributed applications. It is also a platform, including APIs that let it integrate into any logging platform, or telemetry or policy system.
12+
Istio is a completely open source service mesh that layers transparently onto existing distributed applications. It's also a platform, including APIs, that let it integrate into any logging platform, or telemetry or policy system.
13+
14+
Let's review in more detail what each of the components that make up this service mesh are.
1515

1616
* <span style="color:orange">**Envoy**</span>
17-
* Process the inbound/outbound traffic from inter-service and service-to-external-service transparently.
17+
* Processes the inbound/outbound traffic from inter-service and service-to-external-service transparently.
1818

1919
* <span style="color:orange">**Pilot**</span>
2020
* Pilot provides service discovery for the Envoy sidecars, traffic management capabilities for intelligent routing (e.g., A/B tests, canary deployments, etc.), and resiliency (timeouts, retries, circuit breakers, etc.)

content/servicemesh/routing.md

Lines changed: 13 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,9 @@ draft: false
77

88
### Intelligent Routing
99

10-
> Deploying a microservice-based application in an Istio service mesh allows one to externally control service monitoring and tracing, request (version) routing, resiliency testing, security and policy enforcement, etc., In a consistent way across the services, for the application as a whole.
10+
Deploying a microservice-based application in an Istio service mesh allows one to externally control service monitoring and tracing, request (version) routing, resiliency testing, security and policy enforcement, and more in a consistent manner across the services, and the application.
1111

12-
Before you can use Istio to control the Bookinfo version routing, you need to define the available versions, called <span style="color:orange">**subsets**</span>, in destination rules.
12+
Before you can use Istio to control the Bookinfo version routing, you'll need to define the available versions, called <span style="color:orange">**subsets**</span>, in destination rules.
1313

1414
{{% notice info %}}
1515
Service versions (a.k.a. subsets) - In a continuous deployment scenario, for a given service, there can be distinct subsets of instances running different variants of the application binary. These variants are not necessarily different API versions. They could be iterative changes to the same service, deployed in different environments (prod, staging, dev, etc.). Common scenarios where this occurs include A/B testing, canary rollouts, etc. The choice of a particular version can be decided based on various criterion (headers, url, etc.) and/or by weights assigned to each version. Each service has a default version consisting of all its instances.
@@ -42,9 +42,9 @@ spec:
4242
subset: v1
4343
```
4444

45-
> Iterate reloading the page and check out review section calls only version of reviews v1 all the time
45+
Try now to reload the page multiple times, and note how only version 1 of reviews is displayed each time.
4646

47-
Change the route configuration so that all traffic from a specific user is routed to a specific service version. In this case, all traffic from a user named <span style="color:orange">*Jason*</span> will be routed to the service <span style="color:orange">**reviews:v2**</span>.
47+
Next, we'll change the route configuration so that all traffic from a specific user is routed to a specific service version. In this case, all traffic from a user named <span style="color:orange">*Jason*</span> will be routed to the service <span style="color:orange">**reviews:v2**</span>.
4848

4949
```
5050
kubectl apply -f samples/bookinfo/networking/virtual-service-reviews-test-v2.yaml
@@ -73,7 +73,7 @@ spec:
7373
subset: v1
7474
```
7575

76-
> Click Sign in on top right corner and login using 'jason' as user name with blank password. You will only see reviews:v2 all the time. Others will see reviews:v1
76+
To test, click **Sign in** from the top right corner of the page, and login using **jason** as user name with a blank password. You will only see reviews:v2 all the time. Others will see reviews:v1.
7777

7878
To test for resiliency, inject a 7s delay between the reviews:v2 and ratings microservices for user jason. This test will uncover a bug that was intentionally introduced into the Bookinfo app.
7979

@@ -108,9 +108,9 @@ spec:
108108
subset: v1
109109
```
110110

111-
> Click Sign in on top right corner and login using 'jason' as user name with blank password. You will see the delays and it ends up display error for reviews. Others will see reviews without error.
112-
>
113-
> The timeout between the productpage and the reviews service is 6 seconds - coded as 3s + 1 retry for 6s total.
111+
Logout, then click **Sign in** from the top right corner of the page, using **jason** as the user name with a blank password. You will see the delays and it ends up display error for reviews. Others will see reviews without error.
112+
113+
The timeout between the productpage and the reviews service is 6 seconds - coded as 3s + 1 retry for 6s total.
114114

115115
To test for another resiliency, introduce an HTTP abort to the ratings microservices for the test user jason. The page will immediately display the “<span style="color:orange">*Ratings service is currently unavailable*</span>”
116116

@@ -120,7 +120,7 @@ kubectl apply -f samples/bookinfo/networking/virtual-service-ratings-test-abort.
120120
kubectl get virtualservice ratings -o yaml
121121
```
122122

123-
The subset is set to v1 in default and return 500 HTTP error for all the request if the logged user is match with 'jason' for ratings.
123+
The subset is set to v1 and by default returns an error message of "Ratings service is currently unavailable" below the reviewer name if the logged username matches 'jason'.
124124

125125
```
126126
spec:
@@ -144,9 +144,10 @@ spec:
144144
host: ratings
145145
subset: v1
146146
```
147-
> Click Sign in on top right corner and login using 'jason' as user name with blank password. You will see error for ratings. Others will see rating without error.
148147

149-
This demo shows you how to gradually migrate traffic from one version of a microservice to another. Send <span style="color:orange">50% of traffic to reviews:v1</span> and <span style="color:blue">50% to reviews:v3</span>.
148+
To test, click **Sign in** from the top right corner of the page and login using **jason** for the user name with a blank password. As **jason** you will see the error message. Others (not logged in as **jason**) will see no error message.
149+
150+
Next, we'll demonstrate how to gradually migrate traffic from one version of a microservice to another. In our example, we'll send <span style="color:orange">50% of traffic to reviews:v1</span> and <span style="color:blue">50% to reviews:v3</span>.
150151

151152
```
152153
kubectl apply -f samples/bookinfo/networking/virtual-service-all-v1.yaml
@@ -173,4 +174,4 @@ spec:
173174
weight: 50
174175
```
175176

176-
> keep refreshing your browser. You will see the pages for reviews:v1 and reviews:v3
177+
To test it, refresh your browser over and over, and you'll see only reviews:v1 and reviews:v3.

content/servicemesh/visualize.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,15 +7,15 @@ draft: false
77

88
### Collecting new telemetry data
99

10-
Download a YAML file to hold configuration for the new metric and log stream that Istio will generate and collect automatically.
10+
Next, download a YAML file to hold configuration for the new metric and log stream that Istio will generate and collect automatically.
1111

1212
```
1313
curl -LO https://eksworkshop.com/servicemesh/deploy.files/istio-telemetry.yaml
1414
1515
kubectl apply -f istio-telemetry.yaml
1616
```
1717

18-
Make sure prometheus and grafana is running
18+
Make sure Prometheus and Grafana are running
1919

2020
```
2121
kubectl -n istio-system get svc prometheus
@@ -52,4 +52,4 @@ You will see that the traffic is evenly spread between <span style="color:orange
5252

5353
![Grafana Dashabord](/images/servicemesh-visualize1.png)
5454

55-
We encourage you to review other Istio dashboards that are available by clicking Istio Mesh Dashboard Menu on top left and selecting different dashboard
55+
We encourage you to explore other Istio dashboards that are available by clicking the **Istio Mesh Dashboard** menu on top left of the page, and selecting a different dashboard.

0 commit comments

Comments
 (0)