Skip to content

Commit 3a80dd9

Browse files
committed
[zh-cn]sync endpoint-slice-v1
Signed-off-by: xin.li <[email protected]>
1 parent a01d6f3 commit 3a80dd9

1 file changed

Lines changed: 51 additions & 50 deletions

File tree

content/zh-cn/docs/reference/kubernetes-api/service-resources/endpoint-slice-v1.md

Lines changed: 51 additions & 50 deletions
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ EndpointSlice 对象,这些对象必须被组合在一起以产生完整的端
4949
标准的对象元数据。
5050

5151
- **addressType** (string), <!--required-->必需
52-
52+
5353
<!--
5454
addressType specifies the type of address carried by this EndpointSlice. All addresses in this slice must be the same type. This field is immutable after creation. The following address types are currently supported: * IPv4: Represents an IPv4 Address. * IPv6: Represents an IPv6 Address. * FQDN: Represents a Fully Qualified Domain Name. (Deprecated) The EndpointSlice controller only generates, and kube-proxy only processes, slices of addressType "IPv4" and "IPv6". No semantics are defined for the "FQDN" type.
5555
-->
@@ -71,7 +71,7 @@ EndpointSlice 对象,这些对象必须被组合在一起以产生完整的端
7171
-->
7272

7373
可能的枚举值:
74-
74+
7575
- `"FQDN"` 表示完全限定域名(FQDN)。
7676
- `"IPv4"` 表示 IPv4 地址。
7777
- `"IPv6"` 表示 IPv6 地址。
@@ -86,7 +86,9 @@ EndpointSlice 对象,这些对象必须被组合在一起以产生完整的端
8686
<!--
8787
endpoints is a list of unique endpoints in this slice. Each slice may include a maximum of 1000 endpoints.
8888
-->
89-
`endpoints` 是当前 EndpointSlice 中一组唯一的端点。每个 EndpointSlice 最多可以包含 1000 个端点。
89+
90+
`endpoints` 是当前 EndpointSlice 中一组唯一的端点。每个 EndpointSlice
91+
最多可以包含 1000 个端点。
9092

9193
<a name="Endpoint"></a>
9294

@@ -96,17 +98,17 @@ EndpointSlice 对象,这些对象必须被组合在一起以产生完整的端
9698
**端点是实现某 Service 的一个逻辑“后端”。**
9799

98100
- **endpoints.addresses** ([]string), <!--required-->必需
99-
101+
100102
<!--
101103
*Set: unique values will be kept during a merge*
102104
-->
103-
105+
104106
**集合:不重复的值在合并期间会被保留**
105107

106108
<!--
107109
addresses of this endpoint. For EndpointSlices of addressType "IPv4" or "IPv6", the values are IP addresses in canonical form. The syntax and semantics of other addressType values are not defined. This must contain at least one address but no more than 100. EndpointSlices generated by the EndpointSlice controller will always have exactly 1 address. No semantics are defined for additional addresses beyond the first, and kube-proxy does not look at them.
108110
-->
109-
111+
110112
本端点的地址。对于地址类型为 "IPv4" 或 "IPv6" 的 EndpointSlices,
111113
值是规范形式的 IP 地址。其他地址类型值的语法和语义未定义。
112114
这必须包含至少一个地址但不超过 100 个。由 EndpointSlice 控制器生成的
@@ -118,7 +120,7 @@ EndpointSlice 对象,这些对象必须被组合在一起以产生完整的端
118120
<!--
119121
conditions contains information about the current status of the endpoint.
120122
-->
121-
123+
122124
`conditions` 包含和本端点当前状态有关的信息。
123125

124126
<a name="EndpointConditions"></a>
@@ -129,8 +131,8 @@ EndpointSlice 对象,这些对象必须被组合在一起以产生完整的端
129131

130132
**EndpointConditions 是端点的当前状况。**
131133

132-
- **endpoints.conditions.ready** (boolean)
133-
134+
- **endpoints.conditions.ready** (boolean)
135+
134136
<!--
135137
ready indicates that this endpoint is ready to receive traffic, according to whatever system is managing the endpoint. A nil value should be interpreted as "true". In general, an endpoint should be marked ready if it is serving and not terminating, though this can be overridden in some cases, such as when the associated Service has set the publishNotReadyAddresses flag.
136138
-->
@@ -141,30 +143,30 @@ EndpointSlice 对象,这些对象必须被组合在一起以产生完整的端
141143
publishNotReadyAddresses 标志时。
142144

143145
- **endpoints.conditions.serving** (boolean)
144-
146+
145147
<!--
146148
serving indicates that this endpoint is able to receive traffic, according to whatever system is managing the endpoint. For endpoints backed by pods, the EndpointSlice controller will mark the endpoint as serving if the pod's Ready condition is True. A nil value should be interpreted as "true".
147149
-->
148-
150+
149151
`serving` 表示此端点能够接收流量,根据管理端点的系统。对于由 Pod 支持的端点,
150152
如果 Pod 的 Ready 条件为 True,EndpointSlice 控制器会将端点标记为 `serving`
151153
nil 值应解释为 "true"。
152154

153155
- **endpoints.conditions.terminating** (boolean)
154-
156+
155157
<!--
156158
terminating indicates that this endpoint is terminating. A nil value should be interpreted as "false".
157159
-->
158160

159-
terminating 说明当前端点正在终止过程中。
161+
`terminating` 说明当前端点正在终止过程中。
160162
nil 值应解释为 "false"。
161163

162164
- **endpoints.deprecatedTopology** (map[string]string)
163-
165+
164166
<!--
165167
deprecatedTopology contains topology information part of the v1beta1 API. This field is deprecated, and will be removed when the v1beta1 API is removed (no sooner than kubernetes v1.24). While this field can hold values, it is not writable through the v1 API, and any attempts to write to it will be silently ignored. Topology information can be found in the zone and nodeName fields instead.
166168
-->
167-
169+
168170
`deprecatedTopology` 包含 v1beta1 API 的拓扑信息部分。目前已经弃用了此字段,
169171
移除 v1beta1 API 时(不早于 Kubernetes v1.24)会一起移除此字段。
170172
此字段目前仍然可以存储值,但是不能通过 v1 API 写入数据。
@@ -176,35 +178,34 @@ EndpointSlice 对象,这些对象必须被组合在一起以产生完整的端
176178
<!--
177179
hints contains information associated with how an endpoint should be consumed.
178180
-->
179-
181+
180182
`hints` 是关于应该如何使用某端点的提示信息。
181183

182184
<a name="EndpointHints"></a>
183185

184186
<!--
185187
*EndpointHints provides hints describing how an endpoint should be consumed.*
186188
-->
187-
189+
188190
**EndpointHints 提供应该如何使用某端点的提示信息。**
189191

190192
- **endpoints.hints.forNodes** ([]ForNode)
191193

192194
<!--
193195
*Atomic: will be replaced during a merge*
194196
-->
195-
197+
196198
**原子性:合并期间将被替换**
197199

198200
<!--
199-
forNodes indicates the node(s) this endpoint should be consumed by when using topology aware routing. May contain a maximum of 8 entries. This is an Alpha feature and is only used when the PreferSameTrafficDistribution feature gate is enabled.
201+
forNodes indicates the node(s) this endpoint should be consumed by when using topology aware routing. May contain a maximum of 8 entries.
200202
-->
201203

202204
`forNodes` 表示在使用拓扑感知路由时,此端点应由哪个(些)节点消费。
203-
最多可能包含 8 个条目。这是一个 Alpha 级别特性,仅在启用了 PreferSameTrafficDistribution
204-
特性门控时使用。
205+
最多可能包含 8 个条目。
205206

206207
<a name="ForNode"></a>
207-
208+
208209
<!--
209210
*ForNode provides information about which nodes should consume this endpoint.*
210211
@@ -224,13 +225,13 @@ EndpointSlice 对象,这些对象必须被组合在一起以产生完整的端
224225
<!--
225226
*Atomic: will be replaced during a merge*
226227
-->
227-
228+
228229
**原子性:合并期间将被替换**
229230

230231
<!--
231232
forZones indicates the zone(s) this endpoint should be consumed by when using topology aware routing. May contain a maximum of 8 entries.
232233
-->
233-
234+
234235
`forZones` 表示在使用拓扑感知路由时,该端点应由哪个(些)区域消费。
235236
最多可能包含 8 个条目。
236237

@@ -239,23 +240,23 @@ EndpointSlice 对象,这些对象必须被组合在一起以产生完整的端
239240
<!--
240241
*ForZone provides information about which zones should consume this endpoint.*
241242
-->
242-
243+
243244
**ForZone 指示应该由哪些可用区调度此端点。**
244245

245246
- **endpoints.hints.forZones.name** (string), <!--required-->必需
246247

247248
<!--
248249
name represents the name of the zone.
249250
-->
250-
251+
251252
`name` 代表可用区的名称。
252253

253254
- **endpoints.hostname** (string)
254255

255256
<!--
256257
hostname of this endpoint. This field may be used by consumers of endpoints to distinguish endpoints from each other (e.g. in DNS names). Multiple endpoints which use the same hostname should be considered fungible (e.g. multiple A values in DNS). Must be lowercase and pass DNS Label (RFC 1123) validation.
257258
-->
258-
259+
259260
此端点的主机名称。端点的使用者可以通过此字段区分各个端点(例如,通过 DNS 域名)。
260261
使用同一主机名称的多个端点应被视为可替换(例如,DNS 中的多个 A 记录)。
261262
必须为小写字母,并且需要通过 DNS Label (RFC 1123) 验证。
@@ -265,33 +266,33 @@ EndpointSlice 对象,这些对象必须被组合在一起以产生完整的端
265266
<!--
266267
nodeName represents the name of the Node hosting this endpoint. This can be used to determine endpoints local to a Node.
267268
-->
268-
269+
269270
`nodeName` 是托管此端点的 Node 的名称,使用 nodeName 可以决定 Node 本地有哪些端点。
270271

271272
- **endpoints.targetRef** (<a href="{{< ref "../common-definitions/object-reference#ObjectReference" >}}">ObjectReference</a>)
272273

273274
<!--
274275
targetRef is a reference to a Kubernetes object that represents this endpoint.
275276
-->
276-
277+
277278
`targetRef` 是对代表此端点的 Kubernetes 对象的引用。
278279

279280
- **endpoints.zone** (string)
280281

281282
<!--
282283
zone is the name of the Zone this endpoint exists in.
283284
-->
284-
285+
285286
`zone` 是此端点所在的可用区(Zone)的名称。
286287

287288
- **ports** ([]EndpointPort)
288289

289290
<!--
290291
*Atomic: will be replaced during a merge*
291292
-->
292-
293+
293294
**原子性:合并期间会被替代**
294-
295+
295296
<!--
296297
ports specifies the list of network ports exposed by each endpoint in this slice. Each port must have a unique name. Each slice may include a maximum of 100 ports. Services always have at least 1 port, so EndpointSlices generated by the EndpointSlice controller will likewise always have at least 1 port. EndpointSlices used for other purposes may have an empty ports list.
297298
-->
@@ -300,22 +301,22 @@ EndpointSlice 对象,这些对象必须被组合在一起以产生完整的端
300301
`ports` 列出了当前 EndpointSlice 中各个端点所暴露的网络端口。每个端口的名称不得重复。
301302
每个切片最多可能包含 100 个端口。Service 总是至少有 1 个端口,因此由 EndpointSlice
302303
控制器生成的 EndpointSlices 同样总是至少有 1 个端口。用于其他目的的 EndpointSlices
303-
可能有一个空的 ports 列表。
304+
可能有一个空的 `ports` 列表。
304305

305306
<a name="EndpointPort"></a>
306307

307308
<!--
308309
*EndpointPort represents a Port used by an EndpointSlice*
309310
-->
310-
311+
311312
**EndpointPort 是 EndpointSlice 使用的端口。**
312313

313314
- **ports.port** (int32)
314315

315316
<!--
316317
port represents the port number of the endpoint. If the EndpointSlice is derived from a Kubernetes service, this must be set to the service's target port. EndpointSlices used for other purposes may have a nil port.
317318
-->
318-
319+
319320
`port` 表示端点的端口号。如果 EndpointSlice 是从 Kubernetes 服务派生的,
320321
这必须设置为服务的目标端口。用于其他目的的 EndpointSlices 可能有一个 nil 端口。
321322

@@ -329,9 +330,9 @@ EndpointSlice 对象,这些对象必须被组合在一起以产生完整的端
329330
- `"TCP"` is the TCP protocol.
330331
- `"UDP"` is the UDP protocol.
331332
-->
332-
333-
`protocol` 表示此端口的 IP 协议。必须为 UDPTCP 或 SCTP。默认为 TCP。
334-
333+
334+
`protocol` 表示此端口的 IP 协议。必须为 `UDP``TCP``SCTP`。默认为 `TCP`
335+
335336
可能的枚举值:
336337
- `"SCTP"` 是 SCTP 协议
337338
- `"TCP"` 是 TCP 协议
@@ -342,12 +343,12 @@ EndpointSlice 对象,这些对象必须被组合在一起以产生完整的端
342343
<!--
343344
name represents the name of this port. All ports in an EndpointSlice must have a unique name. If the EndpointSlice is derived from a Kubernetes service, this corresponds to the Service.ports[].name. Name must either be an empty string or pass DNS_LABEL validation: * must be no more than 63 characters long. * must consist of lower case alphanumeric characters or '-'. * must start and end with an alphanumeric character. Default is empty string.
344345
-->
345-
346+
346347
`name` 表示此端口的名称。EndpointSlice 中所有端口的名称都不得重复。
347348
如果 EndpointSlice 是基于 Kubernetes Service 创建的,
348349
那么此端口的名称和 `Service.ports[].name` 字段的值一致。默认为空字符串。
349350
名称必须是空字符串,或者必须通过 DNS_LABEL 验证:
350-
351+
351352
* 最多包含 63 个字符。
352353
* 必须包含英文小写字母或'-'。
353354
* 必须以字母开头并以字母结尾。
@@ -356,14 +357,14 @@ EndpointSlice 对象,这些对象必须被组合在一起以产生完整的端
356357

357358
<!--
358359
The application protocol for this port. This is used as a hint for implementations to offer richer behavior for protocols that they understand. This field follows standard Kubernetes label syntax. Valid values are either:
359-
360+
360361
* Un-prefixed protocol names - reserved for IANA standard service names (as per RFC-6335 and https://www.iana.org/assignments/service-names).
361-
362+
362363
* Kubernetes-defined prefixed names:
363364
* 'kubernetes.io/h2c' - HTTP/2 prior knowledge over cleartext as described in https://www.rfc-editor.org/rfc/rfc9113.html#name-starting-http-2-with-prior-
364365
* 'kubernetes.io/ws' - WebSocket over cleartext as described in https://www.rfc-editor.org/rfc/rfc6455
365-
* 'kubernetes.io/wss' - WebSocket over TLS as described in https://www.rfc-editor.org/rfc/rfc6455
366-
366+
* 'kubernetes.io/wss' - WebSocket over TLS as described in https://www.rfc-editor.org/rfc/rfc6455
367+
367368
* Other protocols should use implementation-defined prefixed names such as mycompany.com/my-custom-protocol.
368369
-->
369370

@@ -399,16 +400,16 @@ EndpointSliceList 是 EndpointSlice 的列表。
399400
<!--
400401
Standard list metadata.
401402
-->
402-
403+
403404
标准的列表元数据。
404405

405406
- **items** ([]<a href="{{< ref "../service-resources/endpoint-slice-v1#EndpointSlice" >}}">EndpointSlice</a>), <!--required-->必需
406407

407408
<!--
408409
items is the list of endpoint slices
409410
-->
410-
411-
`items` 是 EndpointSlice 列表
411+
412+
`items` 是 EndpointSlice 列表
412413

413414
<!--
414415
## Operations {#Operations}
@@ -441,7 +442,7 @@ GET /apis/discovery.k8s.io/v1/namespaces/{namespace}/endpointslices/{name}
441442
<!--
442443
name of the EndpointSlice
443444
-->
444-
445+
445446
EndpointSlice 的名称。
446447

447448
<!--
@@ -761,7 +762,7 @@ PUT /apis/discovery.k8s.io/v1/namespaces/{namespace}/endpointslices/{name}
761762
<!--
762763
name of the EndpointSlice
763764
-->
764-
EndpointSlice 的名称
765+
EndpointSlice 的名称
765766

766767
<!--
767768
- **namespace** (*in path*): string, required
@@ -834,7 +835,7 @@ PATCH /apis/discovery.k8s.io/v1/namespaces/{namespace}/endpointslices/{name}
834835
- **name** (**路径参数**): string, 必需
835836

836837
<!--name of the EndpointSlice-->
837-
EndpointSlice 的名称
838+
EndpointSlice 的名称
838839

839840
<!--
840841
- **namespace** (*in path*): string, required

0 commit comments

Comments
 (0)