From 58b23a5515a979ec28f198eac3977c864cdf76f9 Mon Sep 17 00:00:00 2001 From: Jared Kirschner <85913323+jkirschner-hashicorp@users.noreply.github.com> Date: Mon, 23 Jan 2023 13:12:27 -0500 Subject: [PATCH] docs: clarify service defaults example --- .../config-entries/service-defaults.mdx | 39 ++++++++++--------- 1 file changed, 20 insertions(+), 19 deletions(-) diff --git a/website/content/docs/connect/config-entries/service-defaults.mdx b/website/content/docs/connect/config-entries/service-defaults.mdx index 28907c99ac..c1b9cd67dc 100644 --- a/website/content/docs/connect/config-entries/service-defaults.mdx +++ b/website/content/docs/connect/config-entries/service-defaults.mdx @@ -56,14 +56,14 @@ spec: Set default connection limits and mesh gateway mode across all upstreams -of "counting", and also override the mesh gateway mode used when dialing -the "dashboard" service. +of "dashboard", and also override the mesh gateway mode used when dialing +its upstream "counting" service. ```hcl Kind = "service-defaults" -Name = "counting" +Name = "dashboard" UpstreamConfig = { Defaults = { @@ -79,7 +79,7 @@ UpstreamConfig = { Overrides = [ { - Name = "dashboard" + Name = "counting" MeshGateway = { Mode = "remote" } @@ -92,7 +92,7 @@ UpstreamConfig = { apiVersion: consul.hashicorp.com/v1alpha1 kind: ServiceDefaults metadata: - name: counting + name: dashboard spec: upstreamConfig: defaults: @@ -103,7 +103,7 @@ spec: maxPendingRequests: 512 maxConcurrentRequests: 512 overrides: - - name: dashboard + - name: counting meshGateway: mode: remote ``` @@ -111,7 +111,7 @@ spec: ```json { "Kind": "service-defaults", - "Name": "counting", + "Name": "dashboard", "UpstreamConfig": { "Defaults": { "MeshGateway": { @@ -125,7 +125,7 @@ spec: }, "Overrides": [ { - "Name": "dashboard", + "Name": "counting", "MeshGateway": { "Mode": "remote" } @@ -141,14 +141,15 @@ spec: Set default connection limits and mesh gateway mode across all upstreams -of "counting" and also override the mesh gateway mode used when dialing -the "dashboard" service in the "frontend" namespace. +of "dashboard" in the "product" namespace, +and also override the mesh gateway mode used when dialing +its upstream "counting" service in the "backend" namespace. ```hcl Kind = "service-defaults" -Name = "counting" +Name = "dashboard" Namespace = "product" UpstreamConfig = { @@ -165,8 +166,8 @@ UpstreamConfig = { Overrides = [ { - Name = "dashboard" - Namespace = "frontend" + Name = "counting" + Namespace = "backend" MeshGateway = { Mode = "remote" } @@ -179,7 +180,7 @@ UpstreamConfig = { apiVersion: consul.hashicorp.com/v1alpha1 kind: ServiceDefaults metadata: - name: counting + name: dashboard namespace: product spec: upstreamConfig: @@ -191,8 +192,8 @@ spec: maxPendingRequests: 512 maxConcurrentRequests: 512 overrides: - - name: dashboard - namespace: frontend + - name: counting + namespace: backend meshGateway: mode: remote ``` @@ -200,7 +201,7 @@ spec: ```json { "Kind": "service-defaults", - "Name": "counting", + "Name": "dashboard", "Namespace": "product", "UpstreamConfig": { "Defaults": { @@ -215,8 +216,8 @@ spec: }, "Overrides": [ { - "Name": "dashboard", - "Namespace": "frontend", + "Name": "counting", + "Namespace": "backend", "MeshGateway": { "Mode": "remote" }