You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: website/content/docs/k8s/connect/cluster-peering/usage/k8s-l7-traffic.mdx
+1-31Lines changed: 1 addition & 31 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -25,8 +25,6 @@ To configure L7 traffic management behavior in deployments with cluster peering
25
25
26
26
The following example updates the [`service-resolver` CRD](/docs/connect/config-entries/) in `cluster-01` so that Consul redirects traffic intended for the `frontend` service to a backup instance in peer `cluster-02` when it detects multiple connection failures.
@@ -42,20 +40,10 @@ To configure L7 traffic management behavior in deployments with cluster peering
42
40
namespace: 'default'
43
41
```
44
42
45
-
</CodeBlockConfig>
46
-
47
-
1. Apply the resource to the local cluster.
48
-
49
-
```shell-session
50
-
$ kubectl apply --filename failover-resolver.yaml
51
-
```
52
-
53
43
1. Define the desired behavior in `service-splitter` or `service-router` CRD.
54
44
55
45
The following example splits traffic evenly between `frontend` and `frontend-peer`:
56
46
57
-
<CodeBlockConfigfilename="splitter.yaml">
58
-
59
47
```yaml
60
48
apiVersion: consul.hashicorp.com/v1alpha1
61
49
kind: ServiceSplitter
@@ -69,20 +57,10 @@ To configure L7 traffic management behavior in deployments with cluster peering
69
57
service: frontend-peer
70
58
```
71
59
72
-
</CodeBlockConfig>
73
-
74
-
1. Apply the resource to the local cluster.
75
-
76
-
```shell-session
77
-
$ kubectl apply --filename splitter.yaml
78
-
```
79
-
80
60
1. Create a second `service-resolver` configuration entry on the local cluster that resolves the name of the peer service you used when splitting or routing the traffic.
81
61
82
62
The following example uses the name `frontend-peer` to define a redirect targeting the `frontend` service on the peer `cluster-02`:
83
63
84
-
<CodeBlockConfigfilename="peer-resolver.yaml">
85
-
86
64
```yaml
87
65
apiVersion: consul.hashicorp.com/v1alpha1
88
66
kind: ServiceResolver
@@ -92,12 +70,4 @@ To configure L7 traffic management behavior in deployments with cluster peering
0 commit comments