...

Text file src/k8s.io/api/discovery/v1/generated.proto

Documentation: k8s.io/api/discovery/v1

     1/*
     2Copyright The Kubernetes Authors.
     3
     4Licensed under the Apache License, Version 2.0 (the "License");
     5you may not use this file except in compliance with the License.
     6You may obtain a copy of the License at
     7
     8    http://www.apache.org/licenses/LICENSE-2.0
     9
    10Unless required by applicable law or agreed to in writing, software
    11distributed under the License is distributed on an "AS IS" BASIS,
    12WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    13See the License for the specific language governing permissions and
    14limitations under the License.
    15*/
    16
    17
    18// This file was autogenerated by go-to-protobuf. Do not edit it manually!
    19
    20syntax = "proto2";
    21
    22package k8s.io.api.discovery.v1;
    23
    24import "k8s.io/api/core/v1/generated.proto";
    25import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto";
    26import "k8s.io/apimachinery/pkg/runtime/generated.proto";
    27import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto";
    28
    29// Package-wide variables from generator "generated".
    30option go_package = "k8s.io/api/discovery/v1";
    31
    32// Endpoint represents a single logical "backend" implementing a service.
    33message Endpoint {
    34  // addresses of this endpoint. The contents of this field are interpreted
    35  // according to the corresponding EndpointSlice addressType field. Consumers
    36  // must handle different types of addresses in the context of their own
    37  // capabilities. This must contain at least one address but no more than
    38  // 100. These are all assumed to be fungible and clients may choose to only
    39  // use the first element. Refer to: https://issue.k8s.io/106267
    40  // +listType=set
    41  repeated string addresses = 1;
    42
    43  // conditions contains information about the current status of the endpoint.
    44  optional EndpointConditions conditions = 2;
    45
    46  // hostname of this endpoint. This field may be used by consumers of
    47  // endpoints to distinguish endpoints from each other (e.g. in DNS names).
    48  // Multiple endpoints which use the same hostname should be considered
    49  // fungible (e.g. multiple A values in DNS). Must be lowercase and pass DNS
    50  // Label (RFC 1123) validation.
    51  // +optional
    52  optional string hostname = 3;
    53
    54  // targetRef is a reference to a Kubernetes object that represents this
    55  // endpoint.
    56  // +optional
    57  optional k8s.io.api.core.v1.ObjectReference targetRef = 4;
    58
    59  // deprecatedTopology contains topology information part of the v1beta1
    60  // API. This field is deprecated, and will be removed when the v1beta1
    61  // API is removed (no sooner than kubernetes v1.24).  While this field can
    62  // hold values, it is not writable through the v1 API, and any attempts to
    63  // write to it will be silently ignored. Topology information can be found
    64  // in the zone and nodeName fields instead.
    65  // +optional
    66  map<string, string> deprecatedTopology = 5;
    67
    68  // nodeName represents the name of the Node hosting this endpoint. This can
    69  // be used to determine endpoints local to a Node.
    70  // +optional
    71  optional string nodeName = 6;
    72
    73  // zone is the name of the Zone this endpoint exists in.
    74  // +optional
    75  optional string zone = 7;
    76
    77  // hints contains information associated with how an endpoint should be
    78  // consumed.
    79  // +optional
    80  optional EndpointHints hints = 8;
    81}
    82
    83// EndpointConditions represents the current condition of an endpoint.
    84message EndpointConditions {
    85  // ready indicates that this endpoint is prepared to receive traffic,
    86  // according to whatever system is managing the endpoint. A nil value
    87  // indicates an unknown state. In most cases consumers should interpret this
    88  // unknown state as ready. For compatibility reasons, ready should never be
    89  // "true" for terminating endpoints, except when the normal readiness
    90  // behavior is being explicitly overridden, for example when the associated
    91  // Service has set the publishNotReadyAddresses flag.
    92  // +optional
    93  optional bool ready = 1;
    94
    95  // serving is identical to ready except that it is set regardless of the
    96  // terminating state of endpoints. This condition should be set to true for
    97  // a ready endpoint that is terminating. If nil, consumers should defer to
    98  // the ready condition.
    99  // +optional
   100  optional bool serving = 2;
   101
   102  // terminating indicates that this endpoint is terminating. A nil value
   103  // indicates an unknown state. Consumers should interpret this unknown state
   104  // to mean that the endpoint is not terminating.
   105  // +optional
   106  optional bool terminating = 3;
   107}
   108
   109// EndpointHints provides hints describing how an endpoint should be consumed.
   110message EndpointHints {
   111  // forZones indicates the zone(s) this endpoint should be consumed by to
   112  // enable topology aware routing.
   113  // +listType=atomic
   114  repeated ForZone forZones = 1;
   115}
   116
   117// EndpointPort represents a Port used by an EndpointSlice
   118// +structType=atomic
   119message EndpointPort {
   120  // name represents the name of this port. All ports in an EndpointSlice must have a unique name.
   121  // If the EndpointSlice is derived from a Kubernetes service, this corresponds to the Service.ports[].name.
   122  // Name must either be an empty string or pass DNS_LABEL validation:
   123  // * must be no more than 63 characters long.
   124  // * must consist of lower case alphanumeric characters or '-'.
   125  // * must start and end with an alphanumeric character.
   126  // Default is empty string.
   127  optional string name = 1;
   128
   129  // protocol represents the IP protocol for this port.
   130  // Must be UDP, TCP, or SCTP.
   131  // Default is TCP.
   132  optional string protocol = 2;
   133
   134  // port represents the port number of the endpoint.
   135  // If this is not specified, ports are not restricted and must be
   136  // interpreted in the context of the specific consumer.
   137  optional int32 port = 3;
   138
   139  // The application protocol for this port.
   140  // This is used as a hint for implementations to offer richer behavior for protocols that they understand.
   141  // This field follows standard Kubernetes label syntax.
   142  // Valid values are either:
   143  //
   144  // * Un-prefixed protocol names - reserved for IANA standard service names (as per
   145  // RFC-6335 and https://www.iana.org/assignments/service-names).
   146  //
   147  // * Kubernetes-defined prefixed names:
   148  //   * '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-
   149  //   * 'kubernetes.io/ws'  - WebSocket over cleartext as described in https://www.rfc-editor.org/rfc/rfc6455
   150  //   * 'kubernetes.io/wss' - WebSocket over TLS as described in https://www.rfc-editor.org/rfc/rfc6455
   151  //
   152  // * Other protocols should use implementation-defined prefixed names such as
   153  // mycompany.com/my-custom-protocol.
   154  // +optional
   155  optional string appProtocol = 4;
   156}
   157
   158// EndpointSlice represents a subset of the endpoints that implement a service.
   159// For a given service there may be multiple EndpointSlice objects, selected by
   160// labels, which must be joined to produce the full set of endpoints.
   161message EndpointSlice {
   162  // Standard object's metadata.
   163  // +optional
   164  optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1;
   165
   166  // addressType specifies the type of address carried by this EndpointSlice.
   167  // All addresses in this slice must be the same type. This field is
   168  // immutable after creation. The following address types are currently
   169  // supported:
   170  // * IPv4: Represents an IPv4 Address.
   171  // * IPv6: Represents an IPv6 Address.
   172  // * FQDN: Represents a Fully Qualified Domain Name.
   173  optional string addressType = 4;
   174
   175  // endpoints is a list of unique endpoints in this slice. Each slice may
   176  // include a maximum of 1000 endpoints.
   177  // +listType=atomic
   178  repeated Endpoint endpoints = 2;
   179
   180  // ports specifies the list of network ports exposed by each endpoint in
   181  // this slice. Each port must have a unique name. When ports is empty, it
   182  // indicates that there are no defined ports. When a port is defined with a
   183  // nil port value, it indicates "all ports". Each slice may include a
   184  // maximum of 100 ports.
   185  // +optional
   186  // +listType=atomic
   187  repeated EndpointPort ports = 3;
   188}
   189
   190// EndpointSliceList represents a list of endpoint slices
   191message EndpointSliceList {
   192  // Standard list metadata.
   193  // +optional
   194  optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1;
   195
   196  // items is the list of endpoint slices
   197  repeated EndpointSlice items = 2;
   198}
   199
   200// ForZone provides information about which zones should consume this endpoint.
   201message ForZone {
   202  // name represents the name of the zone.
   203  optional string name = 1;
   204}
   205

View as plain text