Skip to content

Commit 0d561f8

Browse files
committed
Make the code snippets prettier in the gateway-api blog
1 parent 44eec58 commit 0d561f8

File tree

1 file changed

+27
-30
lines changed
  • content/en/blog/_posts/2024-05-09-gateway-api-v1.1

1 file changed

+27
-30
lines changed

content/en/blog/_posts/2024-05-09-gateway-api-v1.1/index.md

Lines changed: 27 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ session persistence and client certificate verification.
3333
## What's new
3434

3535
### Graduation to Standard
36+
3637
This release includes the graduation to Standard of four eagerly awaited features.
3738
This means they are no longer experimental concepts; inclusion in the Standard
3839
release channel denotes a high level of confidence in the API surface and
@@ -43,22 +44,21 @@ refinements and improvements to these new features in the future.
4344
For more information on how all of this works, refer to the
4445
[Gateway API Versioning Policy](https://gateway-api.sigs.k8s.io/concepts/versioning/).
4546

46-
4747
#### [Service Mesh Support](https://gateway-api.sigs.k8s.io/mesh/)
48+
4849
Service mesh support in Gateway API allows service mesh users to use the same
4950
API to manage ingress traffic and mesh traffic, reusing the same policy and
5051
routing interfaces. In Gateway API v1.1, routes (such as HTTPRoute) can now have
5152
a Service as a `parentRef`, to control how traffic to specific services behave.
52-
For more information, read the
53+
For more information, read the
5354
[Gateway API service mesh documentation](https://gateway-api.sigs.k8s.io/mesh/)
5455
or see the
55-
[list of Gateway API implementations
56-
](https://gateway-api.sigs.k8s.io/implementations/#service-mesh-implementation-status).
56+
[list of Gateway API implementations](https://gateway-api.sigs.k8s.io/implementations/#service-mesh-implementation-status).
5757

5858
As an example, one could do a canary deployment of a workload deep in an
5959
application's call graph with an HTTPRoute as follows:
6060

61-
```
61+
```yaml
6262
apiVersion: gateway.networking.k8s.io/v1
6363
kind: HTTPRoute
6464
metadata:
@@ -79,21 +79,21 @@ spec:
7979
port: 80
8080
weight: 50
8181
```
82-
82+
8383
This would split traffic sent to the `color` Service in the `faces` namespace
8484
50/50 between the original `color` Service and the `color2` Service, using a
8585
portable configuration that's easy to move from one mesh to another.
8686

87-
8887
#### [GRPCRoute](https://gateway-api.sigs.k8s.io/guides/grpc-routing/)
88+
8989
If you are already using the experimental version of GRPCRoute, we recommend holding
9090
off on upgrading to the standard channel version of GRPCRoute until the
9191
controllers you're using have been updated to support GRPCRoute v1. Until then,
9292
it is safe to upgrade to the experimental channel version of GRPCRoute in v1.1
9393
that includes both v1alpha2 and v1 API versions.
9494

95-
9695
#### [ParentReference Port](https://gateway-api.sigs.k8s.io/reference/spec/#gateway.networking.k8s.io%2fv1.ParentReference)
96+
9797
The `port` field was added to ParentReference, allowing you to attach resources
9898
to Gateway Listeners, Services, or other parent resources
9999
(depending on the implementation). Binding to a port also allows you to attach
@@ -102,9 +102,8 @@ to multiple Listeners at once.
102102
For example, you can attach an HTTPRoute to one or more specific Listeners of a
103103
Gateway as specified by the Listener `port`, instead of the Listener `name` field.
104104

105-
For more information, see [Attaching to Gateways.
106-
](https://gateway-api.sigs.k8s.io/api-types/httproute/#attaching-to-gateways)
107-
105+
For more information, see
106+
[Attaching to Gateways](https://gateway-api.sigs.k8s.io/api-types/httproute/#attaching-to-gateways).
108107

109108
#### [Conformance Profiles and Reports](https://gateway-api.sigs.k8s.io/concepts/conformance/#conformance-profiles)
110109

@@ -116,7 +115,6 @@ description of the testing outcome. The Reports have been reorganized in a more
116115
structured way, and the implementations can now add information on how the tests
117116
have been run and provide reproduction steps.
118117

119-
120118
### New additions to Experimental channel
121119

122120
#### [Gateway Client Certificate Verification](https://gateway-api.sigs.k8s.io/geps/gep-91/)
@@ -130,7 +128,7 @@ The following example shows how the CACertificate stored in
130128
the `foo-example-com-ca-cert` ConfigMap can be used to validate the certificates
131129
presented by clients connecting to the `foo-https` Gateway Listener.
132130

133-
```
131+
```yaml
134132
apiVersion: gateway.networking.k8s.io/v1
135133
kind: Gateway
136134
metadata:
@@ -156,7 +154,8 @@ spec:
156154

157155
#### [Session Persistence and BackendLBPolicy](https://gateway-api.sigs.k8s.io/geps/gep-1619/)
158156

159-
[Session Persistence](https://gateway-api.sigs.k8s.io/reference/spec/#gateway.networking.k8s.io%2fv1.SessionPersistence) is being introduced to Gateway API via a new policy
157+
[Session Persistence](https://gateway-api.sigs.k8s.io/reference/spec/#gateway.networking.k8s.io%2fv1.SessionPersistence)
158+
is being introduced to Gateway API via a new policy
160159
([BackendLBPolicy](https://gateway-api.sigs.k8s.io/reference/spec/#gateway.networking.k8s.io/v1alpha2.BackendLBPolicy))
161160
for Service-level configuration and as fields within HTTPRoute
162161
and GRPCRoute for route-level configuration. The BackendLBPolicy and route-level
@@ -168,7 +167,7 @@ session persistence for the `foo` service. It sets the session name to
168167
`foo-session`, defines absolute and idle timeouts, and configures the cookie to
169168
be a session cookie:
170169

171-
```
170+
```yaml
172171
apiVersion: gateway.networking.k8s.io/v1alpha2
173172
kind: BackendLBPolicy
174173
metadata:
@@ -201,16 +200,15 @@ newer version.
201200

202201
Any references to v1alpha2 BackendTLSPolicy fields will need to be updated to
203202
v1alpha3. Specific changes to fields include:
203+
204204
- `targetRef` becomes `targetRefs` to allow a BackendTLSPolicy to attach to
205-
multiple targets
205+
multiple targets
206206
- `tls` becomes `validation`
207207
- `tls.caCertRefs` becomes `validation.caCertificateRefs`
208208
- `tls.wellKnownCACerts` becomes `validation.wellKnownCACertificates`
209209

210-
211210
For a full list of the changes included in this release, please refer to the
212-
[v1.1.0 release notes.
213-
](https://github.com/kubernetes-sigs/gateway-api/releases/tag/v1.1.0)
211+
[v1.1.0 release notes](https://github.com/kubernetes-sigs/gateway-api/releases/tag/v1.1.0).
214212

215213
## Gateway API background
216214

@@ -219,11 +217,9 @@ at the 2019 KubeCon San Diego as the next generation
219217
of Ingress API. Since then, an incredible community has formed to develop what
220218
has likely become the
221219
[most collaborative API in Kubernetes history](https://www.youtube.com/watch?v=V3Vu_FWb4l4).
222-
Over 200 people have contributed to this API so far, and that number continues
223-
to grow.
220+
Over 200 people have contributed to this API so far, and that number continues to grow.
224221

225-
The maintainers
226-
would like to thank _everyone_ who's contributed to Gateway API, whether in the
222+
The maintainers would like to thank _everyone_ who's contributed to Gateway API, whether in the
227223
form of commits to the repo, discussion, ideas, or general support. We literally
228224
couldn't have gotten this far without the support of this dedicated and active
229225
community.
@@ -242,17 +238,18 @@ To try out the API, follow our [Getting Started Guide](https://gateway-api.sigs.
242238
There are lots of opportunities to get involved and help define the future of
243239
Kubernetes routing APIs for both ingress and service mesh.
244240

245-
* Check out the [user guides](https://gateway-api.sigs.k8s.io/guides) to see what use-cases can be addressed.
246-
* Try out one of the [existing Gateway controllers](https://gateway-api.sigs.k8s.io/implementations/)
241+
* Check out the [user guides](https://gateway-api.sigs.k8s.io/guides) to see what use-cases can be addressed.
242+
* Try out one of the [existing Gateway controllers](https://gateway-api.sigs.k8s.io/implementations/).
247243
* Or [join us in the community](https://gateway-api.sigs.k8s.io/contributing/)
248-
and help us build the future of Gateway API together!
244+
and help us build the future of Gateway API together!
249245

250246
## Related Kubernetes blog articles
247+
251248
* [New Experimental Features in Gateway API v1.0](/blog/2023/11/28/gateway-api-ga/)
252-
11/2023
249+
11/2023
253250
* [Gateway API v1.0: GA Release](/blog/2023/10/31/gateway-api-ga/)
254-
10/2023
251+
10/2023
255252
* [Introducing ingress2gateway; Simplifying Upgrades to Gateway API](/blog/2023/10/25/introducing-ingress2gateway/)
256-
10/2023
253+
10/2023
257254
* [Gateway API v0.8.0: Introducing Service Mesh Support](/blog/2023/08/29/gateway-api-v0-8/)
258-
08/2023
255+
08/2023

0 commit comments

Comments
 (0)