mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-29 22:46:12 +00:00
generated
This commit is contained in:
parent
ac7a95efb0
commit
2d10dec3a2
@ -1656,6 +1656,32 @@
|
||||
],
|
||||
"version": "v1"
|
||||
},
|
||||
{
|
||||
"freshness": "Current",
|
||||
"resources": [
|
||||
{
|
||||
"resource": "leasecandidates",
|
||||
"responseKind": {
|
||||
"group": "",
|
||||
"kind": "LeaseCandidate",
|
||||
"version": ""
|
||||
},
|
||||
"scope": "Namespaced",
|
||||
"singularResource": "leasecandidate",
|
||||
"verbs": [
|
||||
"create",
|
||||
"delete",
|
||||
"deletecollection",
|
||||
"get",
|
||||
"list",
|
||||
"patch",
|
||||
"update",
|
||||
"watch"
|
||||
]
|
||||
}
|
||||
],
|
||||
"version": "v1beta1"
|
||||
},
|
||||
{
|
||||
"freshness": "Current",
|
||||
"resources": [
|
||||
|
@ -239,6 +239,10 @@
|
||||
"groupVersion": "coordination.k8s.io/v1",
|
||||
"version": "v1"
|
||||
},
|
||||
{
|
||||
"groupVersion": "coordination.k8s.io/v1beta1",
|
||||
"version": "v1beta1"
|
||||
},
|
||||
{
|
||||
"groupVersion": "coordination.k8s.io/v1alpha2",
|
||||
"version": "v1alpha2"
|
||||
|
@ -11,6 +11,10 @@
|
||||
"groupVersion": "coordination.k8s.io/v1",
|
||||
"version": "v1"
|
||||
},
|
||||
{
|
||||
"groupVersion": "coordination.k8s.io/v1beta1",
|
||||
"version": "v1beta1"
|
||||
},
|
||||
{
|
||||
"groupVersion": "coordination.k8s.io/v1alpha2",
|
||||
"version": "v1alpha2"
|
||||
|
@ -8,7 +8,7 @@
|
||||
"name": "leasecandidates",
|
||||
"namespaced": true,
|
||||
"singularName": "leasecandidate",
|
||||
"storageVersionHash": "RuOD9aJW3DI=",
|
||||
"storageVersionHash": "lvME0iHWE20=",
|
||||
"verbs": [
|
||||
"create",
|
||||
"delete",
|
||||
|
24
api/discovery/apis__coordination.k8s.io__v1beta1.json
Normal file
24
api/discovery/apis__coordination.k8s.io__v1beta1.json
Normal file
@ -0,0 +1,24 @@
|
||||
{
|
||||
"apiVersion": "v1",
|
||||
"groupVersion": "coordination.k8s.io/v1beta1",
|
||||
"kind": "APIResourceList",
|
||||
"resources": [
|
||||
{
|
||||
"kind": "LeaseCandidate",
|
||||
"name": "leasecandidates",
|
||||
"namespaced": true,
|
||||
"singularName": "leasecandidate",
|
||||
"storageVersionHash": "lvME0iHWE20=",
|
||||
"verbs": [
|
||||
"create",
|
||||
"delete",
|
||||
"deletecollection",
|
||||
"get",
|
||||
"list",
|
||||
"patch",
|
||||
"update",
|
||||
"watch"
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
952
api/openapi-spec/swagger.json
generated
952
api/openapi-spec/swagger.json
generated
@ -5440,6 +5440,105 @@
|
||||
],
|
||||
"type": "object"
|
||||
},
|
||||
"io.k8s.api.coordination.v1beta1.LeaseCandidate": {
|
||||
"description": "LeaseCandidate defines a candidate for a Lease object. Candidates are created such that coordinated leader election will pick the best leader from the list of candidates.",
|
||||
"properties": {
|
||||
"apiVersion": {
|
||||
"description": "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources",
|
||||
"type": "string"
|
||||
},
|
||||
"kind": {
|
||||
"description": "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds",
|
||||
"type": "string"
|
||||
},
|
||||
"metadata": {
|
||||
"$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.ObjectMeta",
|
||||
"description": "More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata"
|
||||
},
|
||||
"spec": {
|
||||
"$ref": "#/definitions/io.k8s.api.coordination.v1beta1.LeaseCandidateSpec",
|
||||
"description": "spec contains the specification of the Lease. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status"
|
||||
}
|
||||
},
|
||||
"type": "object",
|
||||
"x-kubernetes-group-version-kind": [
|
||||
{
|
||||
"group": "coordination.k8s.io",
|
||||
"kind": "LeaseCandidate",
|
||||
"version": "v1beta1"
|
||||
}
|
||||
]
|
||||
},
|
||||
"io.k8s.api.coordination.v1beta1.LeaseCandidateList": {
|
||||
"description": "LeaseCandidateList is a list of Lease objects.",
|
||||
"properties": {
|
||||
"apiVersion": {
|
||||
"description": "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources",
|
||||
"type": "string"
|
||||
},
|
||||
"items": {
|
||||
"description": "items is a list of schema objects.",
|
||||
"items": {
|
||||
"$ref": "#/definitions/io.k8s.api.coordination.v1beta1.LeaseCandidate"
|
||||
},
|
||||
"type": "array"
|
||||
},
|
||||
"kind": {
|
||||
"description": "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds",
|
||||
"type": "string"
|
||||
},
|
||||
"metadata": {
|
||||
"$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.ListMeta",
|
||||
"description": "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"items"
|
||||
],
|
||||
"type": "object",
|
||||
"x-kubernetes-group-version-kind": [
|
||||
{
|
||||
"group": "coordination.k8s.io",
|
||||
"kind": "LeaseCandidateList",
|
||||
"version": "v1beta1"
|
||||
}
|
||||
]
|
||||
},
|
||||
"io.k8s.api.coordination.v1beta1.LeaseCandidateSpec": {
|
||||
"description": "LeaseCandidateSpec is a specification of a Lease.",
|
||||
"properties": {
|
||||
"binaryVersion": {
|
||||
"description": "BinaryVersion is the binary version. It must be in a semver format without leading `v`. This field is required.",
|
||||
"type": "string"
|
||||
},
|
||||
"emulationVersion": {
|
||||
"description": "EmulationVersion is the emulation version. It must be in a semver format without leading `v`. EmulationVersion must be less than or equal to BinaryVersion. This field is required when strategy is \"OldestEmulationVersion\"",
|
||||
"type": "string"
|
||||
},
|
||||
"leaseName": {
|
||||
"description": "LeaseName is the name of the lease for which this candidate is contending. The limits on this field are the same as on Lease.name. Multiple lease candidates may reference the same Lease.name. This field is immutable.",
|
||||
"type": "string"
|
||||
},
|
||||
"pingTime": {
|
||||
"$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.MicroTime",
|
||||
"description": "PingTime is the last time that the server has requested the LeaseCandidate to renew. It is only done during leader election to check if any LeaseCandidates have become ineligible. When PingTime is updated, the LeaseCandidate will respond by updating RenewTime."
|
||||
},
|
||||
"renewTime": {
|
||||
"$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.MicroTime",
|
||||
"description": "RenewTime is the time that the LeaseCandidate was last updated. Any time a Lease needs to do leader election, the PingTime field is updated to signal to the LeaseCandidate that they should update the RenewTime. Old LeaseCandidate objects are also garbage collected if it has been hours since the last renew. The PingTime field is updated regularly to prevent garbage collection for still active LeaseCandidates."
|
||||
},
|
||||
"strategy": {
|
||||
"description": "Strategy is the strategy that coordinated leader election will use for picking the leader. If multiple candidates for the same Lease return different strategies, the strategy provided by the candidate with the latest BinaryVersion will be used. If there is still conflict, this is a user error and coordinated leader election will not operate the Lease until resolved.",
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"leaseName",
|
||||
"binaryVersion",
|
||||
"strategy"
|
||||
],
|
||||
"type": "object"
|
||||
},
|
||||
"io.k8s.api.core.v1.AWSElasticBlockStoreVolumeSource": {
|
||||
"description": "Represents a Persistent Disk resource in AWS.\n\nAn AWS EBS disk must exist before mounting to a container. The disk must also be in the same AWS zone as the kubelet. An AWS EBS disk can only be mounted as read/write once. AWS EBS volumes support ownership management and SELinux relabeling.",
|
||||
"properties": {
|
||||
@ -58000,6 +58099,859 @@
|
||||
}
|
||||
]
|
||||
},
|
||||
"/apis/coordination.k8s.io/v1beta1/": {
|
||||
"get": {
|
||||
"consumes": [
|
||||
"application/json",
|
||||
"application/yaml",
|
||||
"application/vnd.kubernetes.protobuf",
|
||||
"application/cbor"
|
||||
],
|
||||
"description": "get available resources",
|
||||
"operationId": "getCoordinationV1beta1APIResources",
|
||||
"produces": [
|
||||
"application/json",
|
||||
"application/yaml",
|
||||
"application/vnd.kubernetes.protobuf",
|
||||
"application/cbor"
|
||||
],
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "OK",
|
||||
"schema": {
|
||||
"$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.APIResourceList"
|
||||
}
|
||||
},
|
||||
"401": {
|
||||
"description": "Unauthorized"
|
||||
}
|
||||
},
|
||||
"schemes": [
|
||||
"https"
|
||||
],
|
||||
"tags": [
|
||||
"coordination_v1beta1"
|
||||
]
|
||||
}
|
||||
},
|
||||
"/apis/coordination.k8s.io/v1beta1/leasecandidates": {
|
||||
"get": {
|
||||
"consumes": [
|
||||
"*/*"
|
||||
],
|
||||
"description": "list or watch objects of kind LeaseCandidate",
|
||||
"operationId": "listCoordinationV1beta1LeaseCandidateForAllNamespaces",
|
||||
"produces": [
|
||||
"application/json",
|
||||
"application/yaml",
|
||||
"application/vnd.kubernetes.protobuf",
|
||||
"application/cbor",
|
||||
"application/json;stream=watch",
|
||||
"application/vnd.kubernetes.protobuf;stream=watch",
|
||||
"application/cbor-seq"
|
||||
],
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "OK",
|
||||
"schema": {
|
||||
"$ref": "#/definitions/io.k8s.api.coordination.v1beta1.LeaseCandidateList"
|
||||
}
|
||||
},
|
||||
"401": {
|
||||
"description": "Unauthorized"
|
||||
}
|
||||
},
|
||||
"schemes": [
|
||||
"https"
|
||||
],
|
||||
"tags": [
|
||||
"coordination_v1beta1"
|
||||
],
|
||||
"x-kubernetes-action": "list",
|
||||
"x-kubernetes-group-version-kind": {
|
||||
"group": "coordination.k8s.io",
|
||||
"kind": "LeaseCandidate",
|
||||
"version": "v1beta1"
|
||||
}
|
||||
},
|
||||
"parameters": [
|
||||
{
|
||||
"$ref": "#/parameters/allowWatchBookmarks-HC2hJt-J"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/continue-QfD61s0i"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/fieldSelector-xIcQKXFG"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/labelSelector-5Zw57w4C"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/limit-1NfNmdNH"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/pretty-tJGM1-ng"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/resourceVersion-5WAnf1kx"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/resourceVersionMatch-t8XhRHeC"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/sendInitialEvents-rLXlEK_k"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/timeoutSeconds-yvYezaOC"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/watch-XNNPZGbK"
|
||||
}
|
||||
]
|
||||
},
|
||||
"/apis/coordination.k8s.io/v1beta1/namespaces/{namespace}/leasecandidates": {
|
||||
"delete": {
|
||||
"consumes": [
|
||||
"*/*"
|
||||
],
|
||||
"description": "delete collection of LeaseCandidate",
|
||||
"operationId": "deleteCoordinationV1beta1CollectionNamespacedLeaseCandidate",
|
||||
"parameters": [
|
||||
{
|
||||
"$ref": "#/parameters/body-2Y1dVQaQ"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/continue-QfD61s0i"
|
||||
},
|
||||
{
|
||||
"description": "When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed",
|
||||
"in": "query",
|
||||
"name": "dryRun",
|
||||
"type": "string",
|
||||
"uniqueItems": true
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/fieldSelector-xIcQKXFG"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/gracePeriodSeconds--K5HaBOS"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/ignoreStoreReadErrorWithClusterBreakingPotential-QbNkfIqj"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/labelSelector-5Zw57w4C"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/limit-1NfNmdNH"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/orphanDependents-uRB25kX5"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/propagationPolicy-6jk3prlO"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/resourceVersion-5WAnf1kx"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/resourceVersionMatch-t8XhRHeC"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/sendInitialEvents-rLXlEK_k"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/timeoutSeconds-yvYezaOC"
|
||||
}
|
||||
],
|
||||
"produces": [
|
||||
"application/json",
|
||||
"application/yaml",
|
||||
"application/vnd.kubernetes.protobuf",
|
||||
"application/cbor"
|
||||
],
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "OK",
|
||||
"schema": {
|
||||
"$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.Status"
|
||||
}
|
||||
},
|
||||
"401": {
|
||||
"description": "Unauthorized"
|
||||
}
|
||||
},
|
||||
"schemes": [
|
||||
"https"
|
||||
],
|
||||
"tags": [
|
||||
"coordination_v1beta1"
|
||||
],
|
||||
"x-kubernetes-action": "deletecollection",
|
||||
"x-kubernetes-group-version-kind": {
|
||||
"group": "coordination.k8s.io",
|
||||
"kind": "LeaseCandidate",
|
||||
"version": "v1beta1"
|
||||
}
|
||||
},
|
||||
"get": {
|
||||
"consumes": [
|
||||
"*/*"
|
||||
],
|
||||
"description": "list or watch objects of kind LeaseCandidate",
|
||||
"operationId": "listCoordinationV1beta1NamespacedLeaseCandidate",
|
||||
"parameters": [
|
||||
{
|
||||
"$ref": "#/parameters/allowWatchBookmarks-HC2hJt-J"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/continue-QfD61s0i"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/fieldSelector-xIcQKXFG"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/labelSelector-5Zw57w4C"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/limit-1NfNmdNH"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/resourceVersion-5WAnf1kx"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/resourceVersionMatch-t8XhRHeC"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/sendInitialEvents-rLXlEK_k"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/timeoutSeconds-yvYezaOC"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/watch-XNNPZGbK"
|
||||
}
|
||||
],
|
||||
"produces": [
|
||||
"application/json",
|
||||
"application/yaml",
|
||||
"application/vnd.kubernetes.protobuf",
|
||||
"application/cbor",
|
||||
"application/json;stream=watch",
|
||||
"application/vnd.kubernetes.protobuf;stream=watch",
|
||||
"application/cbor-seq"
|
||||
],
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "OK",
|
||||
"schema": {
|
||||
"$ref": "#/definitions/io.k8s.api.coordination.v1beta1.LeaseCandidateList"
|
||||
}
|
||||
},
|
||||
"401": {
|
||||
"description": "Unauthorized"
|
||||
}
|
||||
},
|
||||
"schemes": [
|
||||
"https"
|
||||
],
|
||||
"tags": [
|
||||
"coordination_v1beta1"
|
||||
],
|
||||
"x-kubernetes-action": "list",
|
||||
"x-kubernetes-group-version-kind": {
|
||||
"group": "coordination.k8s.io",
|
||||
"kind": "LeaseCandidate",
|
||||
"version": "v1beta1"
|
||||
}
|
||||
},
|
||||
"parameters": [
|
||||
{
|
||||
"$ref": "#/parameters/namespace-vgWSWtn3"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/pretty-tJGM1-ng"
|
||||
}
|
||||
],
|
||||
"post": {
|
||||
"consumes": [
|
||||
"*/*"
|
||||
],
|
||||
"description": "create a LeaseCandidate",
|
||||
"operationId": "createCoordinationV1beta1NamespacedLeaseCandidate",
|
||||
"parameters": [
|
||||
{
|
||||
"in": "body",
|
||||
"name": "body",
|
||||
"required": true,
|
||||
"schema": {
|
||||
"$ref": "#/definitions/io.k8s.api.coordination.v1beta1.LeaseCandidate"
|
||||
}
|
||||
},
|
||||
{
|
||||
"description": "When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed",
|
||||
"in": "query",
|
||||
"name": "dryRun",
|
||||
"type": "string",
|
||||
"uniqueItems": true
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/fieldManager-Qy4HdaTW"
|
||||
},
|
||||
{
|
||||
"description": "fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.",
|
||||
"in": "query",
|
||||
"name": "fieldValidation",
|
||||
"type": "string",
|
||||
"uniqueItems": true
|
||||
}
|
||||
],
|
||||
"produces": [
|
||||
"application/json",
|
||||
"application/yaml",
|
||||
"application/vnd.kubernetes.protobuf",
|
||||
"application/cbor"
|
||||
],
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "OK",
|
||||
"schema": {
|
||||
"$ref": "#/definitions/io.k8s.api.coordination.v1beta1.LeaseCandidate"
|
||||
}
|
||||
},
|
||||
"201": {
|
||||
"description": "Created",
|
||||
"schema": {
|
||||
"$ref": "#/definitions/io.k8s.api.coordination.v1beta1.LeaseCandidate"
|
||||
}
|
||||
},
|
||||
"202": {
|
||||
"description": "Accepted",
|
||||
"schema": {
|
||||
"$ref": "#/definitions/io.k8s.api.coordination.v1beta1.LeaseCandidate"
|
||||
}
|
||||
},
|
||||
"401": {
|
||||
"description": "Unauthorized"
|
||||
}
|
||||
},
|
||||
"schemes": [
|
||||
"https"
|
||||
],
|
||||
"tags": [
|
||||
"coordination_v1beta1"
|
||||
],
|
||||
"x-kubernetes-action": "post",
|
||||
"x-kubernetes-group-version-kind": {
|
||||
"group": "coordination.k8s.io",
|
||||
"kind": "LeaseCandidate",
|
||||
"version": "v1beta1"
|
||||
}
|
||||
}
|
||||
},
|
||||
"/apis/coordination.k8s.io/v1beta1/namespaces/{namespace}/leasecandidates/{name}": {
|
||||
"delete": {
|
||||
"consumes": [
|
||||
"*/*"
|
||||
],
|
||||
"description": "delete a LeaseCandidate",
|
||||
"operationId": "deleteCoordinationV1beta1NamespacedLeaseCandidate",
|
||||
"parameters": [
|
||||
{
|
||||
"$ref": "#/parameters/body-2Y1dVQaQ"
|
||||
},
|
||||
{
|
||||
"description": "When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed",
|
||||
"in": "query",
|
||||
"name": "dryRun",
|
||||
"type": "string",
|
||||
"uniqueItems": true
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/gracePeriodSeconds--K5HaBOS"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/ignoreStoreReadErrorWithClusterBreakingPotential-QbNkfIqj"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/orphanDependents-uRB25kX5"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/propagationPolicy-6jk3prlO"
|
||||
}
|
||||
],
|
||||
"produces": [
|
||||
"application/json",
|
||||
"application/yaml",
|
||||
"application/vnd.kubernetes.protobuf",
|
||||
"application/cbor"
|
||||
],
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "OK",
|
||||
"schema": {
|
||||
"$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.Status"
|
||||
}
|
||||
},
|
||||
"202": {
|
||||
"description": "Accepted",
|
||||
"schema": {
|
||||
"$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.Status"
|
||||
}
|
||||
},
|
||||
"401": {
|
||||
"description": "Unauthorized"
|
||||
}
|
||||
},
|
||||
"schemes": [
|
||||
"https"
|
||||
],
|
||||
"tags": [
|
||||
"coordination_v1beta1"
|
||||
],
|
||||
"x-kubernetes-action": "delete",
|
||||
"x-kubernetes-group-version-kind": {
|
||||
"group": "coordination.k8s.io",
|
||||
"kind": "LeaseCandidate",
|
||||
"version": "v1beta1"
|
||||
}
|
||||
},
|
||||
"get": {
|
||||
"consumes": [
|
||||
"*/*"
|
||||
],
|
||||
"description": "read the specified LeaseCandidate",
|
||||
"operationId": "readCoordinationV1beta1NamespacedLeaseCandidate",
|
||||
"produces": [
|
||||
"application/json",
|
||||
"application/yaml",
|
||||
"application/vnd.kubernetes.protobuf",
|
||||
"application/cbor"
|
||||
],
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "OK",
|
||||
"schema": {
|
||||
"$ref": "#/definitions/io.k8s.api.coordination.v1beta1.LeaseCandidate"
|
||||
}
|
||||
},
|
||||
"401": {
|
||||
"description": "Unauthorized"
|
||||
}
|
||||
},
|
||||
"schemes": [
|
||||
"https"
|
||||
],
|
||||
"tags": [
|
||||
"coordination_v1beta1"
|
||||
],
|
||||
"x-kubernetes-action": "get",
|
||||
"x-kubernetes-group-version-kind": {
|
||||
"group": "coordination.k8s.io",
|
||||
"kind": "LeaseCandidate",
|
||||
"version": "v1beta1"
|
||||
}
|
||||
},
|
||||
"parameters": [
|
||||
{
|
||||
"description": "name of the LeaseCandidate",
|
||||
"in": "path",
|
||||
"name": "name",
|
||||
"required": true,
|
||||
"type": "string",
|
||||
"uniqueItems": true
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/namespace-vgWSWtn3"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/pretty-tJGM1-ng"
|
||||
}
|
||||
],
|
||||
"patch": {
|
||||
"consumes": [
|
||||
"application/json-patch+json",
|
||||
"application/merge-patch+json",
|
||||
"application/strategic-merge-patch+json",
|
||||
"application/apply-patch+yaml",
|
||||
"application/apply-patch+cbor"
|
||||
],
|
||||
"description": "partially update the specified LeaseCandidate",
|
||||
"operationId": "patchCoordinationV1beta1NamespacedLeaseCandidate",
|
||||
"parameters": [
|
||||
{
|
||||
"$ref": "#/parameters/body-78PwaGsr"
|
||||
},
|
||||
{
|
||||
"description": "When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed",
|
||||
"in": "query",
|
||||
"name": "dryRun",
|
||||
"type": "string",
|
||||
"uniqueItems": true
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/fieldManager-7c6nTn1T"
|
||||
},
|
||||
{
|
||||
"description": "fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.",
|
||||
"in": "query",
|
||||
"name": "fieldValidation",
|
||||
"type": "string",
|
||||
"uniqueItems": true
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/force-tOGGb0Yi"
|
||||
}
|
||||
],
|
||||
"produces": [
|
||||
"application/json",
|
||||
"application/yaml",
|
||||
"application/vnd.kubernetes.protobuf",
|
||||
"application/cbor"
|
||||
],
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "OK",
|
||||
"schema": {
|
||||
"$ref": "#/definitions/io.k8s.api.coordination.v1beta1.LeaseCandidate"
|
||||
}
|
||||
},
|
||||
"201": {
|
||||
"description": "Created",
|
||||
"schema": {
|
||||
"$ref": "#/definitions/io.k8s.api.coordination.v1beta1.LeaseCandidate"
|
||||
}
|
||||
},
|
||||
"401": {
|
||||
"description": "Unauthorized"
|
||||
}
|
||||
},
|
||||
"schemes": [
|
||||
"https"
|
||||
],
|
||||
"tags": [
|
||||
"coordination_v1beta1"
|
||||
],
|
||||
"x-kubernetes-action": "patch",
|
||||
"x-kubernetes-group-version-kind": {
|
||||
"group": "coordination.k8s.io",
|
||||
"kind": "LeaseCandidate",
|
||||
"version": "v1beta1"
|
||||
}
|
||||
},
|
||||
"put": {
|
||||
"consumes": [
|
||||
"*/*"
|
||||
],
|
||||
"description": "replace the specified LeaseCandidate",
|
||||
"operationId": "replaceCoordinationV1beta1NamespacedLeaseCandidate",
|
||||
"parameters": [
|
||||
{
|
||||
"in": "body",
|
||||
"name": "body",
|
||||
"required": true,
|
||||
"schema": {
|
||||
"$ref": "#/definitions/io.k8s.api.coordination.v1beta1.LeaseCandidate"
|
||||
}
|
||||
},
|
||||
{
|
||||
"description": "When present, indicates that modifications should not be persisted. An invalid or unrecognized dryRun directive will result in an error response and no further processing of the request. Valid values are: - All: all dry run stages will be processed",
|
||||
"in": "query",
|
||||
"name": "dryRun",
|
||||
"type": "string",
|
||||
"uniqueItems": true
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/fieldManager-Qy4HdaTW"
|
||||
},
|
||||
{
|
||||
"description": "fieldValidation instructs the server on how to handle objects in the request (POST/PUT/PATCH) containing unknown or duplicate fields. Valid values are: - Ignore: This will ignore any unknown fields that are silently dropped from the object, and will ignore all but the last duplicate field that the decoder encounters. This is the default behavior prior to v1.23. - Warn: This will send a warning via the standard warning response header for each unknown field that is dropped from the object, and for each duplicate field that is encountered. The request will still succeed if there are no other errors, and will only persist the last of any duplicate fields. This is the default in v1.23+ - Strict: This will fail the request with a BadRequest error if any unknown fields would be dropped from the object, or if any duplicate fields are present. The error returned from the server will contain all unknown and duplicate fields encountered.",
|
||||
"in": "query",
|
||||
"name": "fieldValidation",
|
||||
"type": "string",
|
||||
"uniqueItems": true
|
||||
}
|
||||
],
|
||||
"produces": [
|
||||
"application/json",
|
||||
"application/yaml",
|
||||
"application/vnd.kubernetes.protobuf",
|
||||
"application/cbor"
|
||||
],
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "OK",
|
||||
"schema": {
|
||||
"$ref": "#/definitions/io.k8s.api.coordination.v1beta1.LeaseCandidate"
|
||||
}
|
||||
},
|
||||
"201": {
|
||||
"description": "Created",
|
||||
"schema": {
|
||||
"$ref": "#/definitions/io.k8s.api.coordination.v1beta1.LeaseCandidate"
|
||||
}
|
||||
},
|
||||
"401": {
|
||||
"description": "Unauthorized"
|
||||
}
|
||||
},
|
||||
"schemes": [
|
||||
"https"
|
||||
],
|
||||
"tags": [
|
||||
"coordination_v1beta1"
|
||||
],
|
||||
"x-kubernetes-action": "put",
|
||||
"x-kubernetes-group-version-kind": {
|
||||
"group": "coordination.k8s.io",
|
||||
"kind": "LeaseCandidate",
|
||||
"version": "v1beta1"
|
||||
}
|
||||
}
|
||||
},
|
||||
"/apis/coordination.k8s.io/v1beta1/watch/leasecandidates": {
|
||||
"get": {
|
||||
"consumes": [
|
||||
"*/*"
|
||||
],
|
||||
"description": "watch individual changes to a list of LeaseCandidate. deprecated: use the 'watch' parameter with a list operation instead.",
|
||||
"operationId": "watchCoordinationV1beta1LeaseCandidateListForAllNamespaces",
|
||||
"produces": [
|
||||
"application/json",
|
||||
"application/yaml",
|
||||
"application/vnd.kubernetes.protobuf",
|
||||
"application/cbor",
|
||||
"application/json;stream=watch",
|
||||
"application/vnd.kubernetes.protobuf;stream=watch",
|
||||
"application/cbor-seq"
|
||||
],
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "OK",
|
||||
"schema": {
|
||||
"$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.WatchEvent"
|
||||
}
|
||||
},
|
||||
"401": {
|
||||
"description": "Unauthorized"
|
||||
}
|
||||
},
|
||||
"schemes": [
|
||||
"https"
|
||||
],
|
||||
"tags": [
|
||||
"coordination_v1beta1"
|
||||
],
|
||||
"x-kubernetes-action": "watchlist",
|
||||
"x-kubernetes-group-version-kind": {
|
||||
"group": "coordination.k8s.io",
|
||||
"kind": "LeaseCandidate",
|
||||
"version": "v1beta1"
|
||||
}
|
||||
},
|
||||
"parameters": [
|
||||
{
|
||||
"$ref": "#/parameters/allowWatchBookmarks-HC2hJt-J"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/continue-QfD61s0i"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/fieldSelector-xIcQKXFG"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/labelSelector-5Zw57w4C"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/limit-1NfNmdNH"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/pretty-tJGM1-ng"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/resourceVersion-5WAnf1kx"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/resourceVersionMatch-t8XhRHeC"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/sendInitialEvents-rLXlEK_k"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/timeoutSeconds-yvYezaOC"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/watch-XNNPZGbK"
|
||||
}
|
||||
]
|
||||
},
|
||||
"/apis/coordination.k8s.io/v1beta1/watch/namespaces/{namespace}/leasecandidates": {
|
||||
"get": {
|
||||
"consumes": [
|
||||
"*/*"
|
||||
],
|
||||
"description": "watch individual changes to a list of LeaseCandidate. deprecated: use the 'watch' parameter with a list operation instead.",
|
||||
"operationId": "watchCoordinationV1beta1NamespacedLeaseCandidateList",
|
||||
"produces": [
|
||||
"application/json",
|
||||
"application/yaml",
|
||||
"application/vnd.kubernetes.protobuf",
|
||||
"application/cbor",
|
||||
"application/json;stream=watch",
|
||||
"application/vnd.kubernetes.protobuf;stream=watch",
|
||||
"application/cbor-seq"
|
||||
],
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "OK",
|
||||
"schema": {
|
||||
"$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.WatchEvent"
|
||||
}
|
||||
},
|
||||
"401": {
|
||||
"description": "Unauthorized"
|
||||
}
|
||||
},
|
||||
"schemes": [
|
||||
"https"
|
||||
],
|
||||
"tags": [
|
||||
"coordination_v1beta1"
|
||||
],
|
||||
"x-kubernetes-action": "watchlist",
|
||||
"x-kubernetes-group-version-kind": {
|
||||
"group": "coordination.k8s.io",
|
||||
"kind": "LeaseCandidate",
|
||||
"version": "v1beta1"
|
||||
}
|
||||
},
|
||||
"parameters": [
|
||||
{
|
||||
"$ref": "#/parameters/allowWatchBookmarks-HC2hJt-J"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/continue-QfD61s0i"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/fieldSelector-xIcQKXFG"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/labelSelector-5Zw57w4C"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/limit-1NfNmdNH"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/namespace-vgWSWtn3"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/pretty-tJGM1-ng"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/resourceVersion-5WAnf1kx"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/resourceVersionMatch-t8XhRHeC"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/sendInitialEvents-rLXlEK_k"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/timeoutSeconds-yvYezaOC"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/watch-XNNPZGbK"
|
||||
}
|
||||
]
|
||||
},
|
||||
"/apis/coordination.k8s.io/v1beta1/watch/namespaces/{namespace}/leasecandidates/{name}": {
|
||||
"get": {
|
||||
"consumes": [
|
||||
"*/*"
|
||||
],
|
||||
"description": "watch changes to an object of kind LeaseCandidate. deprecated: use the 'watch' parameter with a list operation instead, filtered to a single item with the 'fieldSelector' parameter.",
|
||||
"operationId": "watchCoordinationV1beta1NamespacedLeaseCandidate",
|
||||
"produces": [
|
||||
"application/json",
|
||||
"application/yaml",
|
||||
"application/vnd.kubernetes.protobuf",
|
||||
"application/cbor",
|
||||
"application/json;stream=watch",
|
||||
"application/vnd.kubernetes.protobuf;stream=watch",
|
||||
"application/cbor-seq"
|
||||
],
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "OK",
|
||||
"schema": {
|
||||
"$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.WatchEvent"
|
||||
}
|
||||
},
|
||||
"401": {
|
||||
"description": "Unauthorized"
|
||||
}
|
||||
},
|
||||
"schemes": [
|
||||
"https"
|
||||
],
|
||||
"tags": [
|
||||
"coordination_v1beta1"
|
||||
],
|
||||
"x-kubernetes-action": "watch",
|
||||
"x-kubernetes-group-version-kind": {
|
||||
"group": "coordination.k8s.io",
|
||||
"kind": "LeaseCandidate",
|
||||
"version": "v1beta1"
|
||||
}
|
||||
},
|
||||
"parameters": [
|
||||
{
|
||||
"$ref": "#/parameters/allowWatchBookmarks-HC2hJt-J"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/continue-QfD61s0i"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/fieldSelector-xIcQKXFG"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/labelSelector-5Zw57w4C"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/limit-1NfNmdNH"
|
||||
},
|
||||
{
|
||||
"description": "name of the LeaseCandidate",
|
||||
"in": "path",
|
||||
"name": "name",
|
||||
"required": true,
|
||||
"type": "string",
|
||||
"uniqueItems": true
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/namespace-vgWSWtn3"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/pretty-tJGM1-ng"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/resourceVersion-5WAnf1kx"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/resourceVersionMatch-t8XhRHeC"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/sendInitialEvents-rLXlEK_k"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/timeoutSeconds-yvYezaOC"
|
||||
},
|
||||
{
|
||||
"$ref": "#/parameters/watch-XNNPZGbK"
|
||||
}
|
||||
]
|
||||
},
|
||||
"/apis/discovery.k8s.io/": {
|
||||
"get": {
|
||||
"consumes": [
|
||||
|
2949
api/openapi-spec/v3/apis__coordination.k8s.io__v1beta1_openapi.json
generated
Normal file
2949
api/openapi-spec/v3/apis__coordination.k8s.io__v1beta1_openapi.json
generated
Normal file
File diff suppressed because it is too large
Load Diff
108
pkg/apis/coordination/v1beta1/zz_generated.conversion.go
generated
108
pkg/apis/coordination/v1beta1/zz_generated.conversion.go
generated
@ -49,6 +49,36 @@ func RegisterConversions(s *runtime.Scheme) error {
|
||||
}); err != nil {
|
||||
return err
|
||||
}
|
||||
if err := s.AddGeneratedConversionFunc((*coordinationv1beta1.LeaseCandidate)(nil), (*coordination.LeaseCandidate)(nil), func(a, b interface{}, scope conversion.Scope) error {
|
||||
return Convert_v1beta1_LeaseCandidate_To_coordination_LeaseCandidate(a.(*coordinationv1beta1.LeaseCandidate), b.(*coordination.LeaseCandidate), scope)
|
||||
}); err != nil {
|
||||
return err
|
||||
}
|
||||
if err := s.AddGeneratedConversionFunc((*coordination.LeaseCandidate)(nil), (*coordinationv1beta1.LeaseCandidate)(nil), func(a, b interface{}, scope conversion.Scope) error {
|
||||
return Convert_coordination_LeaseCandidate_To_v1beta1_LeaseCandidate(a.(*coordination.LeaseCandidate), b.(*coordinationv1beta1.LeaseCandidate), scope)
|
||||
}); err != nil {
|
||||
return err
|
||||
}
|
||||
if err := s.AddGeneratedConversionFunc((*coordinationv1beta1.LeaseCandidateList)(nil), (*coordination.LeaseCandidateList)(nil), func(a, b interface{}, scope conversion.Scope) error {
|
||||
return Convert_v1beta1_LeaseCandidateList_To_coordination_LeaseCandidateList(a.(*coordinationv1beta1.LeaseCandidateList), b.(*coordination.LeaseCandidateList), scope)
|
||||
}); err != nil {
|
||||
return err
|
||||
}
|
||||
if err := s.AddGeneratedConversionFunc((*coordination.LeaseCandidateList)(nil), (*coordinationv1beta1.LeaseCandidateList)(nil), func(a, b interface{}, scope conversion.Scope) error {
|
||||
return Convert_coordination_LeaseCandidateList_To_v1beta1_LeaseCandidateList(a.(*coordination.LeaseCandidateList), b.(*coordinationv1beta1.LeaseCandidateList), scope)
|
||||
}); err != nil {
|
||||
return err
|
||||
}
|
||||
if err := s.AddGeneratedConversionFunc((*coordinationv1beta1.LeaseCandidateSpec)(nil), (*coordination.LeaseCandidateSpec)(nil), func(a, b interface{}, scope conversion.Scope) error {
|
||||
return Convert_v1beta1_LeaseCandidateSpec_To_coordination_LeaseCandidateSpec(a.(*coordinationv1beta1.LeaseCandidateSpec), b.(*coordination.LeaseCandidateSpec), scope)
|
||||
}); err != nil {
|
||||
return err
|
||||
}
|
||||
if err := s.AddGeneratedConversionFunc((*coordination.LeaseCandidateSpec)(nil), (*coordinationv1beta1.LeaseCandidateSpec)(nil), func(a, b interface{}, scope conversion.Scope) error {
|
||||
return Convert_coordination_LeaseCandidateSpec_To_v1beta1_LeaseCandidateSpec(a.(*coordination.LeaseCandidateSpec), b.(*coordinationv1beta1.LeaseCandidateSpec), scope)
|
||||
}); err != nil {
|
||||
return err
|
||||
}
|
||||
if err := s.AddGeneratedConversionFunc((*coordinationv1beta1.LeaseList)(nil), (*coordination.LeaseList)(nil), func(a, b interface{}, scope conversion.Scope) error {
|
||||
return Convert_v1beta1_LeaseList_To_coordination_LeaseList(a.(*coordinationv1beta1.LeaseList), b.(*coordination.LeaseList), scope)
|
||||
}); err != nil {
|
||||
@ -98,6 +128,84 @@ func Convert_coordination_Lease_To_v1beta1_Lease(in *coordination.Lease, out *co
|
||||
return autoConvert_coordination_Lease_To_v1beta1_Lease(in, out, s)
|
||||
}
|
||||
|
||||
func autoConvert_v1beta1_LeaseCandidate_To_coordination_LeaseCandidate(in *coordinationv1beta1.LeaseCandidate, out *coordination.LeaseCandidate, s conversion.Scope) error {
|
||||
out.ObjectMeta = in.ObjectMeta
|
||||
if err := Convert_v1beta1_LeaseCandidateSpec_To_coordination_LeaseCandidateSpec(&in.Spec, &out.Spec, s); err != nil {
|
||||
return err
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// Convert_v1beta1_LeaseCandidate_To_coordination_LeaseCandidate is an autogenerated conversion function.
|
||||
func Convert_v1beta1_LeaseCandidate_To_coordination_LeaseCandidate(in *coordinationv1beta1.LeaseCandidate, out *coordination.LeaseCandidate, s conversion.Scope) error {
|
||||
return autoConvert_v1beta1_LeaseCandidate_To_coordination_LeaseCandidate(in, out, s)
|
||||
}
|
||||
|
||||
func autoConvert_coordination_LeaseCandidate_To_v1beta1_LeaseCandidate(in *coordination.LeaseCandidate, out *coordinationv1beta1.LeaseCandidate, s conversion.Scope) error {
|
||||
out.ObjectMeta = in.ObjectMeta
|
||||
if err := Convert_coordination_LeaseCandidateSpec_To_v1beta1_LeaseCandidateSpec(&in.Spec, &out.Spec, s); err != nil {
|
||||
return err
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// Convert_coordination_LeaseCandidate_To_v1beta1_LeaseCandidate is an autogenerated conversion function.
|
||||
func Convert_coordination_LeaseCandidate_To_v1beta1_LeaseCandidate(in *coordination.LeaseCandidate, out *coordinationv1beta1.LeaseCandidate, s conversion.Scope) error {
|
||||
return autoConvert_coordination_LeaseCandidate_To_v1beta1_LeaseCandidate(in, out, s)
|
||||
}
|
||||
|
||||
func autoConvert_v1beta1_LeaseCandidateList_To_coordination_LeaseCandidateList(in *coordinationv1beta1.LeaseCandidateList, out *coordination.LeaseCandidateList, s conversion.Scope) error {
|
||||
out.ListMeta = in.ListMeta
|
||||
out.Items = *(*[]coordination.LeaseCandidate)(unsafe.Pointer(&in.Items))
|
||||
return nil
|
||||
}
|
||||
|
||||
// Convert_v1beta1_LeaseCandidateList_To_coordination_LeaseCandidateList is an autogenerated conversion function.
|
||||
func Convert_v1beta1_LeaseCandidateList_To_coordination_LeaseCandidateList(in *coordinationv1beta1.LeaseCandidateList, out *coordination.LeaseCandidateList, s conversion.Scope) error {
|
||||
return autoConvert_v1beta1_LeaseCandidateList_To_coordination_LeaseCandidateList(in, out, s)
|
||||
}
|
||||
|
||||
func autoConvert_coordination_LeaseCandidateList_To_v1beta1_LeaseCandidateList(in *coordination.LeaseCandidateList, out *coordinationv1beta1.LeaseCandidateList, s conversion.Scope) error {
|
||||
out.ListMeta = in.ListMeta
|
||||
out.Items = *(*[]coordinationv1beta1.LeaseCandidate)(unsafe.Pointer(&in.Items))
|
||||
return nil
|
||||
}
|
||||
|
||||
// Convert_coordination_LeaseCandidateList_To_v1beta1_LeaseCandidateList is an autogenerated conversion function.
|
||||
func Convert_coordination_LeaseCandidateList_To_v1beta1_LeaseCandidateList(in *coordination.LeaseCandidateList, out *coordinationv1beta1.LeaseCandidateList, s conversion.Scope) error {
|
||||
return autoConvert_coordination_LeaseCandidateList_To_v1beta1_LeaseCandidateList(in, out, s)
|
||||
}
|
||||
|
||||
func autoConvert_v1beta1_LeaseCandidateSpec_To_coordination_LeaseCandidateSpec(in *coordinationv1beta1.LeaseCandidateSpec, out *coordination.LeaseCandidateSpec, s conversion.Scope) error {
|
||||
out.LeaseName = in.LeaseName
|
||||
out.PingTime = (*v1.MicroTime)(unsafe.Pointer(in.PingTime))
|
||||
out.RenewTime = (*v1.MicroTime)(unsafe.Pointer(in.RenewTime))
|
||||
out.BinaryVersion = in.BinaryVersion
|
||||
out.EmulationVersion = in.EmulationVersion
|
||||
out.Strategy = coordination.CoordinatedLeaseStrategy(in.Strategy)
|
||||
return nil
|
||||
}
|
||||
|
||||
// Convert_v1beta1_LeaseCandidateSpec_To_coordination_LeaseCandidateSpec is an autogenerated conversion function.
|
||||
func Convert_v1beta1_LeaseCandidateSpec_To_coordination_LeaseCandidateSpec(in *coordinationv1beta1.LeaseCandidateSpec, out *coordination.LeaseCandidateSpec, s conversion.Scope) error {
|
||||
return autoConvert_v1beta1_LeaseCandidateSpec_To_coordination_LeaseCandidateSpec(in, out, s)
|
||||
}
|
||||
|
||||
func autoConvert_coordination_LeaseCandidateSpec_To_v1beta1_LeaseCandidateSpec(in *coordination.LeaseCandidateSpec, out *coordinationv1beta1.LeaseCandidateSpec, s conversion.Scope) error {
|
||||
out.LeaseName = in.LeaseName
|
||||
out.PingTime = (*v1.MicroTime)(unsafe.Pointer(in.PingTime))
|
||||
out.RenewTime = (*v1.MicroTime)(unsafe.Pointer(in.RenewTime))
|
||||
out.BinaryVersion = in.BinaryVersion
|
||||
out.EmulationVersion = in.EmulationVersion
|
||||
out.Strategy = coordinationv1.CoordinatedLeaseStrategy(in.Strategy)
|
||||
return nil
|
||||
}
|
||||
|
||||
// Convert_coordination_LeaseCandidateSpec_To_v1beta1_LeaseCandidateSpec is an autogenerated conversion function.
|
||||
func Convert_coordination_LeaseCandidateSpec_To_v1beta1_LeaseCandidateSpec(in *coordination.LeaseCandidateSpec, out *coordinationv1beta1.LeaseCandidateSpec, s conversion.Scope) error {
|
||||
return autoConvert_coordination_LeaseCandidateSpec_To_v1beta1_LeaseCandidateSpec(in, out, s)
|
||||
}
|
||||
|
||||
func autoConvert_v1beta1_LeaseList_To_coordination_LeaseList(in *coordinationv1beta1.LeaseList, out *coordination.LeaseList, s conversion.Scope) error {
|
||||
out.ListMeta = in.ListMeta
|
||||
out.Items = *(*[]coordination.Lease)(unsafe.Pointer(&in.Items))
|
||||
|
155
pkg/generated/openapi/zz_generated.openapi.go
generated
155
pkg/generated/openapi/zz_generated.openapi.go
generated
@ -389,6 +389,9 @@ func GetOpenAPIDefinitions(ref common.ReferenceCallback) map[string]common.OpenA
|
||||
"k8s.io/api/coordination/v1alpha2.LeaseCandidateList": schema_k8sio_api_coordination_v1alpha2_LeaseCandidateList(ref),
|
||||
"k8s.io/api/coordination/v1alpha2.LeaseCandidateSpec": schema_k8sio_api_coordination_v1alpha2_LeaseCandidateSpec(ref),
|
||||
"k8s.io/api/coordination/v1beta1.Lease": schema_k8sio_api_coordination_v1beta1_Lease(ref),
|
||||
"k8s.io/api/coordination/v1beta1.LeaseCandidate": schema_k8sio_api_coordination_v1beta1_LeaseCandidate(ref),
|
||||
"k8s.io/api/coordination/v1beta1.LeaseCandidateList": schema_k8sio_api_coordination_v1beta1_LeaseCandidateList(ref),
|
||||
"k8s.io/api/coordination/v1beta1.LeaseCandidateSpec": schema_k8sio_api_coordination_v1beta1_LeaseCandidateSpec(ref),
|
||||
"k8s.io/api/coordination/v1beta1.LeaseList": schema_k8sio_api_coordination_v1beta1_LeaseList(ref),
|
||||
"k8s.io/api/coordination/v1beta1.LeaseSpec": schema_k8sio_api_coordination_v1beta1_LeaseSpec(ref),
|
||||
"k8s.io/api/core/v1.AWSElasticBlockStoreVolumeSource": schema_k8sio_api_core_v1_AWSElasticBlockStoreVolumeSource(ref),
|
||||
@ -19588,6 +19591,158 @@ func schema_k8sio_api_coordination_v1beta1_Lease(ref common.ReferenceCallback) c
|
||||
}
|
||||
}
|
||||
|
||||
func schema_k8sio_api_coordination_v1beta1_LeaseCandidate(ref common.ReferenceCallback) common.OpenAPIDefinition {
|
||||
return common.OpenAPIDefinition{
|
||||
Schema: spec.Schema{
|
||||
SchemaProps: spec.SchemaProps{
|
||||
Description: "LeaseCandidate defines a candidate for a Lease object. Candidates are created such that coordinated leader election will pick the best leader from the list of candidates.",
|
||||
Type: []string{"object"},
|
||||
Properties: map[string]spec.Schema{
|
||||
"kind": {
|
||||
SchemaProps: spec.SchemaProps{
|
||||
Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds",
|
||||
Type: []string{"string"},
|
||||
Format: "",
|
||||
},
|
||||
},
|
||||
"apiVersion": {
|
||||
SchemaProps: spec.SchemaProps{
|
||||
Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources",
|
||||
Type: []string{"string"},
|
||||
Format: "",
|
||||
},
|
||||
},
|
||||
"metadata": {
|
||||
SchemaProps: spec.SchemaProps{
|
||||
Description: "More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata",
|
||||
Default: map[string]interface{}{},
|
||||
Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"),
|
||||
},
|
||||
},
|
||||
"spec": {
|
||||
SchemaProps: spec.SchemaProps{
|
||||
Description: "spec contains the specification of the Lease. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status",
|
||||
Default: map[string]interface{}{},
|
||||
Ref: ref("k8s.io/api/coordination/v1beta1.LeaseCandidateSpec"),
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
Dependencies: []string{
|
||||
"k8s.io/api/coordination/v1beta1.LeaseCandidateSpec", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"},
|
||||
}
|
||||
}
|
||||
|
||||
func schema_k8sio_api_coordination_v1beta1_LeaseCandidateList(ref common.ReferenceCallback) common.OpenAPIDefinition {
|
||||
return common.OpenAPIDefinition{
|
||||
Schema: spec.Schema{
|
||||
SchemaProps: spec.SchemaProps{
|
||||
Description: "LeaseCandidateList is a list of Lease objects.",
|
||||
Type: []string{"object"},
|
||||
Properties: map[string]spec.Schema{
|
||||
"kind": {
|
||||
SchemaProps: spec.SchemaProps{
|
||||
Description: "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds",
|
||||
Type: []string{"string"},
|
||||
Format: "",
|
||||
},
|
||||
},
|
||||
"apiVersion": {
|
||||
SchemaProps: spec.SchemaProps{
|
||||
Description: "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources",
|
||||
Type: []string{"string"},
|
||||
Format: "",
|
||||
},
|
||||
},
|
||||
"metadata": {
|
||||
SchemaProps: spec.SchemaProps{
|
||||
Description: "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata",
|
||||
Default: map[string]interface{}{},
|
||||
Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"),
|
||||
},
|
||||
},
|
||||
"items": {
|
||||
SchemaProps: spec.SchemaProps{
|
||||
Description: "items is a list of schema objects.",
|
||||
Type: []string{"array"},
|
||||
Items: &spec.SchemaOrArray{
|
||||
Schema: &spec.Schema{
|
||||
SchemaProps: spec.SchemaProps{
|
||||
Default: map[string]interface{}{},
|
||||
Ref: ref("k8s.io/api/coordination/v1beta1.LeaseCandidate"),
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
Required: []string{"items"},
|
||||
},
|
||||
},
|
||||
Dependencies: []string{
|
||||
"k8s.io/api/coordination/v1beta1.LeaseCandidate", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"},
|
||||
}
|
||||
}
|
||||
|
||||
func schema_k8sio_api_coordination_v1beta1_LeaseCandidateSpec(ref common.ReferenceCallback) common.OpenAPIDefinition {
|
||||
return common.OpenAPIDefinition{
|
||||
Schema: spec.Schema{
|
||||
SchemaProps: spec.SchemaProps{
|
||||
Description: "LeaseCandidateSpec is a specification of a Lease.",
|
||||
Type: []string{"object"},
|
||||
Properties: map[string]spec.Schema{
|
||||
"leaseName": {
|
||||
SchemaProps: spec.SchemaProps{
|
||||
Description: "LeaseName is the name of the lease for which this candidate is contending. The limits on this field are the same as on Lease.name. Multiple lease candidates may reference the same Lease.name. This field is immutable.",
|
||||
Default: "",
|
||||
Type: []string{"string"},
|
||||
Format: "",
|
||||
},
|
||||
},
|
||||
"pingTime": {
|
||||
SchemaProps: spec.SchemaProps{
|
||||
Description: "PingTime is the last time that the server has requested the LeaseCandidate to renew. It is only done during leader election to check if any LeaseCandidates have become ineligible. When PingTime is updated, the LeaseCandidate will respond by updating RenewTime.",
|
||||
Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.MicroTime"),
|
||||
},
|
||||
},
|
||||
"renewTime": {
|
||||
SchemaProps: spec.SchemaProps{
|
||||
Description: "RenewTime is the time that the LeaseCandidate was last updated. Any time a Lease needs to do leader election, the PingTime field is updated to signal to the LeaseCandidate that they should update the RenewTime. Old LeaseCandidate objects are also garbage collected if it has been hours since the last renew. The PingTime field is updated regularly to prevent garbage collection for still active LeaseCandidates.",
|
||||
Ref: ref("k8s.io/apimachinery/pkg/apis/meta/v1.MicroTime"),
|
||||
},
|
||||
},
|
||||
"binaryVersion": {
|
||||
SchemaProps: spec.SchemaProps{
|
||||
Description: "BinaryVersion is the binary version. It must be in a semver format without leading `v`. This field is required.",
|
||||
Default: "",
|
||||
Type: []string{"string"},
|
||||
Format: "",
|
||||
},
|
||||
},
|
||||
"emulationVersion": {
|
||||
SchemaProps: spec.SchemaProps{
|
||||
Description: "EmulationVersion is the emulation version. It must be in a semver format without leading `v`. EmulationVersion must be less than or equal to BinaryVersion. This field is required when strategy is \"OldestEmulationVersion\"",
|
||||
Type: []string{"string"},
|
||||
Format: "",
|
||||
},
|
||||
},
|
||||
"strategy": {
|
||||
SchemaProps: spec.SchemaProps{
|
||||
Description: "Strategy is the strategy that coordinated leader election will use for picking the leader. If multiple candidates for the same Lease return different strategies, the strategy provided by the candidate with the latest BinaryVersion will be used. If there is still conflict, this is a user error and coordinated leader election will not operate the Lease until resolved.",
|
||||
Type: []string{"string"},
|
||||
Format: "",
|
||||
},
|
||||
},
|
||||
},
|
||||
Required: []string{"leaseName", "binaryVersion", "strategy"},
|
||||
},
|
||||
},
|
||||
Dependencies: []string{
|
||||
"k8s.io/apimachinery/pkg/apis/meta/v1.MicroTime"},
|
||||
}
|
||||
}
|
||||
|
||||
func schema_k8sio_api_coordination_v1beta1_LeaseList(ref common.ReferenceCallback) common.OpenAPIDefinition {
|
||||
return common.OpenAPIDefinition{
|
||||
Schema: spec.Schema{
|
||||
|
@ -74,10 +74,94 @@ func (m *Lease) XXX_DiscardUnknown() {
|
||||
|
||||
var xxx_messageInfo_Lease proto.InternalMessageInfo
|
||||
|
||||
func (m *LeaseCandidate) Reset() { *m = LeaseCandidate{} }
|
||||
func (*LeaseCandidate) ProtoMessage() {}
|
||||
func (*LeaseCandidate) Descriptor() ([]byte, []int) {
|
||||
return fileDescriptor_8d4e223b8bb23da3, []int{1}
|
||||
}
|
||||
func (m *LeaseCandidate) XXX_Unmarshal(b []byte) error {
|
||||
return m.Unmarshal(b)
|
||||
}
|
||||
func (m *LeaseCandidate) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
|
||||
b = b[:cap(b)]
|
||||
n, err := m.MarshalToSizedBuffer(b)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return b[:n], nil
|
||||
}
|
||||
func (m *LeaseCandidate) XXX_Merge(src proto.Message) {
|
||||
xxx_messageInfo_LeaseCandidate.Merge(m, src)
|
||||
}
|
||||
func (m *LeaseCandidate) XXX_Size() int {
|
||||
return m.Size()
|
||||
}
|
||||
func (m *LeaseCandidate) XXX_DiscardUnknown() {
|
||||
xxx_messageInfo_LeaseCandidate.DiscardUnknown(m)
|
||||
}
|
||||
|
||||
var xxx_messageInfo_LeaseCandidate proto.InternalMessageInfo
|
||||
|
||||
func (m *LeaseCandidateList) Reset() { *m = LeaseCandidateList{} }
|
||||
func (*LeaseCandidateList) ProtoMessage() {}
|
||||
func (*LeaseCandidateList) Descriptor() ([]byte, []int) {
|
||||
return fileDescriptor_8d4e223b8bb23da3, []int{2}
|
||||
}
|
||||
func (m *LeaseCandidateList) XXX_Unmarshal(b []byte) error {
|
||||
return m.Unmarshal(b)
|
||||
}
|
||||
func (m *LeaseCandidateList) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
|
||||
b = b[:cap(b)]
|
||||
n, err := m.MarshalToSizedBuffer(b)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return b[:n], nil
|
||||
}
|
||||
func (m *LeaseCandidateList) XXX_Merge(src proto.Message) {
|
||||
xxx_messageInfo_LeaseCandidateList.Merge(m, src)
|
||||
}
|
||||
func (m *LeaseCandidateList) XXX_Size() int {
|
||||
return m.Size()
|
||||
}
|
||||
func (m *LeaseCandidateList) XXX_DiscardUnknown() {
|
||||
xxx_messageInfo_LeaseCandidateList.DiscardUnknown(m)
|
||||
}
|
||||
|
||||
var xxx_messageInfo_LeaseCandidateList proto.InternalMessageInfo
|
||||
|
||||
func (m *LeaseCandidateSpec) Reset() { *m = LeaseCandidateSpec{} }
|
||||
func (*LeaseCandidateSpec) ProtoMessage() {}
|
||||
func (*LeaseCandidateSpec) Descriptor() ([]byte, []int) {
|
||||
return fileDescriptor_8d4e223b8bb23da3, []int{3}
|
||||
}
|
||||
func (m *LeaseCandidateSpec) XXX_Unmarshal(b []byte) error {
|
||||
return m.Unmarshal(b)
|
||||
}
|
||||
func (m *LeaseCandidateSpec) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
|
||||
b = b[:cap(b)]
|
||||
n, err := m.MarshalToSizedBuffer(b)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return b[:n], nil
|
||||
}
|
||||
func (m *LeaseCandidateSpec) XXX_Merge(src proto.Message) {
|
||||
xxx_messageInfo_LeaseCandidateSpec.Merge(m, src)
|
||||
}
|
||||
func (m *LeaseCandidateSpec) XXX_Size() int {
|
||||
return m.Size()
|
||||
}
|
||||
func (m *LeaseCandidateSpec) XXX_DiscardUnknown() {
|
||||
xxx_messageInfo_LeaseCandidateSpec.DiscardUnknown(m)
|
||||
}
|
||||
|
||||
var xxx_messageInfo_LeaseCandidateSpec proto.InternalMessageInfo
|
||||
|
||||
func (m *LeaseList) Reset() { *m = LeaseList{} }
|
||||
func (*LeaseList) ProtoMessage() {}
|
||||
func (*LeaseList) Descriptor() ([]byte, []int) {
|
||||
return fileDescriptor_8d4e223b8bb23da3, []int{1}
|
||||
return fileDescriptor_8d4e223b8bb23da3, []int{4}
|
||||
}
|
||||
func (m *LeaseList) XXX_Unmarshal(b []byte) error {
|
||||
return m.Unmarshal(b)
|
||||
@ -105,7 +189,7 @@ var xxx_messageInfo_LeaseList proto.InternalMessageInfo
|
||||
func (m *LeaseSpec) Reset() { *m = LeaseSpec{} }
|
||||
func (*LeaseSpec) ProtoMessage() {}
|
||||
func (*LeaseSpec) Descriptor() ([]byte, []int) {
|
||||
return fileDescriptor_8d4e223b8bb23da3, []int{2}
|
||||
return fileDescriptor_8d4e223b8bb23da3, []int{5}
|
||||
}
|
||||
func (m *LeaseSpec) XXX_Unmarshal(b []byte) error {
|
||||
return m.Unmarshal(b)
|
||||
@ -132,6 +216,9 @@ var xxx_messageInfo_LeaseSpec proto.InternalMessageInfo
|
||||
|
||||
func init() {
|
||||
proto.RegisterType((*Lease)(nil), "k8s.io.api.coordination.v1beta1.Lease")
|
||||
proto.RegisterType((*LeaseCandidate)(nil), "k8s.io.api.coordination.v1beta1.LeaseCandidate")
|
||||
proto.RegisterType((*LeaseCandidateList)(nil), "k8s.io.api.coordination.v1beta1.LeaseCandidateList")
|
||||
proto.RegisterType((*LeaseCandidateSpec)(nil), "k8s.io.api.coordination.v1beta1.LeaseCandidateSpec")
|
||||
proto.RegisterType((*LeaseList)(nil), "k8s.io.api.coordination.v1beta1.LeaseList")
|
||||
proto.RegisterType((*LeaseSpec)(nil), "k8s.io.api.coordination.v1beta1.LeaseSpec")
|
||||
}
|
||||
@ -141,45 +228,54 @@ func init() {
|
||||
}
|
||||
|
||||
var fileDescriptor_8d4e223b8bb23da3 = []byte{
|
||||
// 600 bytes of a gzipped FileDescriptorProto
|
||||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x94, 0xdf, 0x4e, 0xd4, 0x4e,
|
||||
0x14, 0xc7, 0xb7, 0xb0, 0xfb, 0xfb, 0xb1, 0xb3, 0xf2, 0x27, 0x23, 0x17, 0x0d, 0x17, 0x2d, 0xe1,
|
||||
0xc2, 0x10, 0x12, 0xa7, 0x82, 0xc6, 0x18, 0x13, 0x13, 0x2d, 0x9a, 0x48, 0x2c, 0xd1, 0x14, 0xae,
|
||||
0x0c, 0x89, 0xce, 0xb6, 0x87, 0xee, 0x08, 0xed, 0xd4, 0x99, 0x59, 0x0c, 0x77, 0x3e, 0x82, 0x4f,
|
||||
0xa3, 0xf1, 0x0d, 0xb8, 0xe4, 0x92, 0xab, 0x46, 0xc6, 0xb7, 0xf0, 0xca, 0xcc, 0x6c, 0x61, 0x61,
|
||||
0x81, 0xb0, 0xf1, 0x6e, 0xe7, 0x9c, 0xf3, 0xfd, 0x9c, 0xef, 0x9c, 0xb3, 0x53, 0x14, 0xec, 0x3d,
|
||||
0x91, 0x84, 0xf1, 0x80, 0x96, 0x2c, 0x48, 0x38, 0x17, 0x29, 0x2b, 0xa8, 0x62, 0xbc, 0x08, 0x0e,
|
||||
0x56, 0xbb, 0xa0, 0xe8, 0x6a, 0x90, 0x41, 0x01, 0x82, 0x2a, 0x48, 0x49, 0x29, 0xb8, 0xe2, 0xd8,
|
||||
0x1f, 0x08, 0x08, 0x2d, 0x19, 0xb9, 0x28, 0x20, 0xb5, 0x60, 0xe1, 0x7e, 0xc6, 0x54, 0xaf, 0xdf,
|
||||
0x25, 0x09, 0xcf, 0x83, 0x8c, 0x67, 0x3c, 0xb0, 0xba, 0x6e, 0x7f, 0xd7, 0x9e, 0xec, 0xc1, 0xfe,
|
||||
0x1a, 0xf0, 0x16, 0x56, 0x6e, 0x36, 0x30, 0xda, 0x7b, 0xe1, 0xd1, 0xb0, 0x36, 0xa7, 0x49, 0x8f,
|
||||
0x15, 0x20, 0x0e, 0x83, 0x72, 0x2f, 0x33, 0x01, 0x19, 0xe4, 0xa0, 0xe8, 0x75, 0xaa, 0xe0, 0x26,
|
||||
0x95, 0xe8, 0x17, 0x8a, 0xe5, 0x70, 0x45, 0xf0, 0xf8, 0x36, 0x81, 0x4c, 0x7a, 0x90, 0xd3, 0x51,
|
||||
0xdd, 0xd2, 0x0f, 0x07, 0xb5, 0x22, 0xa0, 0x12, 0xf0, 0x47, 0x34, 0x65, 0xdc, 0xa4, 0x54, 0x51,
|
||||
0xd7, 0x59, 0x74, 0x96, 0x3b, 0x6b, 0x0f, 0xc8, 0x70, 0x6e, 0xe7, 0x50, 0x52, 0xee, 0x65, 0x26,
|
||||
0x20, 0x89, 0xa9, 0x26, 0x07, 0xab, 0xe4, 0x6d, 0xf7, 0x13, 0x24, 0x6a, 0x13, 0x14, 0x0d, 0xf1,
|
||||
0x51, 0xe5, 0x37, 0x74, 0xe5, 0xa3, 0x61, 0x2c, 0x3e, 0xa7, 0xe2, 0x08, 0x35, 0x65, 0x09, 0x89,
|
||||
0x3b, 0x61, 0xe9, 0x2b, 0xe4, 0x96, 0xad, 0x10, 0xeb, 0x6b, 0xab, 0x84, 0x24, 0xbc, 0x53, 0x73,
|
||||
0x9b, 0xe6, 0x14, 0x5b, 0xca, 0xd2, 0x77, 0x07, 0xb5, 0x6d, 0x45, 0xc4, 0xa4, 0xc2, 0x3b, 0x57,
|
||||
0xdc, 0x93, 0xf1, 0xdc, 0x1b, 0xb5, 0xf5, 0x3e, 0x57, 0xf7, 0x98, 0x3a, 0x8b, 0x5c, 0x70, 0xfe,
|
||||
0x06, 0xb5, 0x98, 0x82, 0x5c, 0xba, 0x13, 0x8b, 0x93, 0xcb, 0x9d, 0xb5, 0x7b, 0xe3, 0x59, 0x0f,
|
||||
0xa7, 0x6b, 0x64, 0x6b, 0xc3, 0x88, 0xe3, 0x01, 0x63, 0xe9, 0x67, 0xb3, 0x36, 0x6e, 0x2e, 0x83,
|
||||
0x9f, 0xa2, 0x99, 0x1e, 0xdf, 0x4f, 0x41, 0x6c, 0xa4, 0x50, 0x28, 0xa6, 0x0e, 0xad, 0xfd, 0x76,
|
||||
0x88, 0x75, 0xe5, 0xcf, 0xbc, 0xbe, 0x94, 0x89, 0x47, 0x2a, 0x71, 0x84, 0xe6, 0xf7, 0x0d, 0xe8,
|
||||
0x65, 0x5f, 0xd8, 0xf6, 0x5b, 0x90, 0xf0, 0x22, 0x95, 0x76, 0xc0, 0xad, 0xd0, 0xd5, 0x95, 0x3f,
|
||||
0x1f, 0x5d, 0x93, 0x8f, 0xaf, 0x55, 0xe1, 0x2e, 0xea, 0xd0, 0xe4, 0x73, 0x9f, 0x09, 0xd8, 0x66,
|
||||
0x39, 0xb8, 0x93, 0x76, 0x8a, 0xc1, 0x78, 0x53, 0xdc, 0x64, 0x89, 0xe0, 0x46, 0x16, 0xce, 0xea,
|
||||
0xca, 0xef, 0xbc, 0x18, 0x72, 0xe2, 0x8b, 0x50, 0xbc, 0x83, 0xda, 0x02, 0x0a, 0xf8, 0x62, 0x3b,
|
||||
0x34, 0xff, 0xad, 0xc3, 0xb4, 0xae, 0xfc, 0x76, 0x7c, 0x46, 0x89, 0x87, 0x40, 0xfc, 0x1c, 0xcd,
|
||||
0xd9, 0x9b, 0x6d, 0x0b, 0x5a, 0x48, 0x66, 0xee, 0x26, 0xdd, 0x96, 0x9d, 0xc5, 0xbc, 0xae, 0xfc,
|
||||
0xb9, 0x68, 0x24, 0x17, 0x5f, 0xa9, 0xc6, 0x1f, 0xd0, 0x94, 0x54, 0xe6, 0x7d, 0x64, 0x87, 0xee,
|
||||
0x7f, 0x76, 0x0f, 0xeb, 0xe6, 0x2f, 0xb1, 0x55, 0xc7, 0xfe, 0x54, 0xfe, 0xc3, 0x9b, 0xdf, 0x3e,
|
||||
0x59, 0x3f, 0x3b, 0x43, 0x3a, 0x58, 0x70, 0x2d, 0x8b, 0xcf, 0xa1, 0xf8, 0x19, 0x9a, 0x2d, 0x05,
|
||||
0xec, 0x82, 0x10, 0x90, 0x0e, 0xb6, 0xeb, 0xfe, 0x6f, 0xfb, 0xdc, 0xd5, 0x95, 0x3f, 0xfb, 0xee,
|
||||
0x72, 0x2a, 0x1e, 0xad, 0x0d, 0x5f, 0x1d, 0x9d, 0x7a, 0x8d, 0xe3, 0x53, 0xaf, 0x71, 0x72, 0xea,
|
||||
0x35, 0xbe, 0x6a, 0xcf, 0x39, 0xd2, 0x9e, 0x73, 0xac, 0x3d, 0xe7, 0x44, 0x7b, 0xce, 0x2f, 0xed,
|
||||
0x39, 0xdf, 0x7e, 0x7b, 0x8d, 0xf7, 0xfe, 0x2d, 0x1f, 0xc8, 0xbf, 0x01, 0x00, 0x00, 0xff, 0xff,
|
||||
0x57, 0x93, 0xf3, 0xef, 0x42, 0x05, 0x00, 0x00,
|
||||
// 750 bytes of a gzipped FileDescriptorProto
|
||||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xbc, 0x56, 0xdd, 0x4e, 0x1b, 0x39,
|
||||
0x18, 0xcd, 0x40, 0xb2, 0x9b, 0x38, 0x04, 0xb2, 0x5e, 0x56, 0x1a, 0x71, 0x31, 0x83, 0x72, 0xb1,
|
||||
0x42, 0x48, 0xeb, 0x59, 0x60, 0xb5, 0x5a, 0x6d, 0x55, 0xa9, 0x1d, 0x40, 0x2d, 0x6a, 0x68, 0x91,
|
||||
0xa1, 0x95, 0x5a, 0x21, 0xb5, 0xce, 0x8c, 0x99, 0xb8, 0x30, 0x3f, 0xf5, 0x38, 0x54, 0xb9, 0xeb,
|
||||
0x23, 0xf4, 0x69, 0x5a, 0xf5, 0x0d, 0xd2, 0x3b, 0x2e, 0xb9, 0x8a, 0xca, 0x54, 0xea, 0x43, 0xf4,
|
||||
0xaa, 0xb2, 0x33, 0xf9, 0x27, 0x22, 0x6d, 0x11, 0x77, 0xf1, 0xf7, 0x9d, 0x73, 0xfc, 0x1d, 0xfb,
|
||||
0x38, 0x1a, 0x60, 0x1d, 0xff, 0x17, 0x23, 0x16, 0x5a, 0x24, 0x62, 0x96, 0x13, 0x86, 0xdc, 0x65,
|
||||
0x01, 0x11, 0x2c, 0x0c, 0xac, 0xd3, 0xb5, 0x1a, 0x15, 0x64, 0xcd, 0xf2, 0x68, 0x40, 0x39, 0x11,
|
||||
0xd4, 0x45, 0x11, 0x0f, 0x45, 0x08, 0xcd, 0x0e, 0x01, 0x91, 0x88, 0xa1, 0x41, 0x02, 0x4a, 0x09,
|
||||
0x4b, 0x7f, 0x79, 0x4c, 0xd4, 0x1b, 0x35, 0xe4, 0x84, 0xbe, 0xe5, 0x85, 0x5e, 0x68, 0x29, 0x5e,
|
||||
0xad, 0x71, 0xa4, 0x56, 0x6a, 0xa1, 0x7e, 0x75, 0xf4, 0x96, 0x56, 0x27, 0x0f, 0x30, 0xba, 0xf7,
|
||||
0xd2, 0x3f, 0x7d, 0xac, 0x4f, 0x9c, 0x3a, 0x0b, 0x28, 0x6f, 0x5a, 0xd1, 0xb1, 0x27, 0x0b, 0xb1,
|
||||
0xe5, 0x53, 0x41, 0x2e, 0x63, 0x59, 0x93, 0x58, 0xbc, 0x11, 0x08, 0xe6, 0xd3, 0x31, 0xc2, 0xbf,
|
||||
0x57, 0x11, 0x62, 0xa7, 0x4e, 0x7d, 0x32, 0xca, 0xab, 0xbc, 0xd7, 0x40, 0xae, 0x4a, 0x49, 0x4c,
|
||||
0xe1, 0x0b, 0x90, 0x97, 0xd3, 0xb8, 0x44, 0x10, 0x5d, 0x5b, 0xd6, 0x56, 0x8a, 0xeb, 0x7f, 0xa3,
|
||||
0xfe, 0xb9, 0xf5, 0x44, 0x51, 0x74, 0xec, 0xc9, 0x42, 0x8c, 0x24, 0x1a, 0x9d, 0xae, 0xa1, 0x47,
|
||||
0xb5, 0x97, 0xd4, 0x11, 0xbb, 0x54, 0x10, 0x1b, 0xb6, 0xda, 0x66, 0x26, 0x69, 0x9b, 0xa0, 0x5f,
|
||||
0xc3, 0x3d, 0x55, 0x58, 0x05, 0xd9, 0x38, 0xa2, 0x8e, 0x3e, 0xa3, 0xd4, 0x57, 0xd1, 0x15, 0xb7,
|
||||
0x82, 0xd4, 0x5c, 0xfb, 0x11, 0x75, 0xec, 0xb9, 0x54, 0x37, 0x2b, 0x57, 0x58, 0xa9, 0x54, 0x3e,
|
||||
0x6a, 0x60, 0x5e, 0x21, 0x36, 0x49, 0xe0, 0x32, 0x97, 0x88, 0x9b, 0xb0, 0xf0, 0x78, 0xc8, 0xc2,
|
||||
0xc6, 0x74, 0x16, 0x7a, 0x03, 0x4e, 0xf4, 0xd2, 0xd2, 0x00, 0x1c, 0x86, 0x56, 0x59, 0x2c, 0xe0,
|
||||
0xe1, 0x98, 0x1f, 0x34, 0x9d, 0x1f, 0xc9, 0x56, 0x6e, 0xca, 0xe9, 0x66, 0xf9, 0x6e, 0x65, 0xc0,
|
||||
0xcb, 0x01, 0xc8, 0x31, 0x41, 0xfd, 0x58, 0x9f, 0x59, 0x9e, 0x5d, 0x29, 0xae, 0x5b, 0xdf, 0x69,
|
||||
0xc6, 0x2e, 0xa5, 0xda, 0xb9, 0x1d, 0xa9, 0x82, 0x3b, 0x62, 0x95, 0x2f, 0xb3, 0xa3, 0x56, 0xa4,
|
||||
0x4f, 0x68, 0x81, 0xc2, 0x89, 0xac, 0x3e, 0x24, 0x3e, 0x55, 0x5e, 0x0a, 0xf6, 0x6f, 0x29, 0xbf,
|
||||
0x50, 0xed, 0x36, 0x70, 0x1f, 0x03, 0x9f, 0x82, 0x7c, 0xc4, 0x02, 0xef, 0x80, 0xf9, 0x34, 0x3d,
|
||||
0x6d, 0x6b, 0x3a, 0xef, 0xbb, 0xcc, 0xe1, 0xa1, 0xa4, 0xd9, 0x73, 0xd2, 0xf8, 0x5e, 0x2a, 0x82,
|
||||
0x7b, 0x72, 0xf0, 0x10, 0x14, 0x38, 0x0d, 0xe8, 0x6b, 0xa5, 0x3d, 0xfb, 0x63, 0xda, 0x25, 0x39,
|
||||
0x38, 0xee, 0xaa, 0xe0, 0xbe, 0x20, 0xbc, 0x05, 0x4a, 0x35, 0x16, 0x10, 0xde, 0x7c, 0x42, 0x79,
|
||||
0xcc, 0xc2, 0x40, 0xcf, 0x2a, 0xb7, 0x7f, 0xa4, 0x6e, 0x4b, 0xf6, 0x60, 0x13, 0x0f, 0x63, 0xe1,
|
||||
0x16, 0x28, 0x53, 0xbf, 0x71, 0xa2, 0xce, 0xbd, 0xcb, 0xcf, 0x29, 0xbe, 0x9e, 0xf2, 0xcb, 0xdb,
|
||||
0x23, 0x7d, 0x3c, 0xc6, 0x80, 0x0e, 0xc8, 0xc7, 0x42, 0xbe, 0x72, 0xaf, 0xa9, 0xff, 0xa2, 0xd8,
|
||||
0xf7, 0xba, 0x39, 0xd8, 0x4f, 0xeb, 0x5f, 0xdb, 0xe6, 0xc6, 0xe4, 0x7f, 0x31, 0xb4, 0xd9, 0x5d,
|
||||
0x53, 0xb7, 0xf3, 0x0a, 0x53, 0x1a, 0xee, 0x09, 0x57, 0xde, 0x69, 0xa0, 0x73, 0x73, 0x37, 0x10,
|
||||
0xd5, 0x07, 0xc3, 0x51, 0xfd, 0x73, 0xba, 0xa8, 0x4e, 0x48, 0xe8, 0x87, 0x6c, 0x3a, 0xb8, 0x0a,
|
||||
0xe6, 0xff, 0x60, 0xbe, 0x1e, 0x9e, 0xb8, 0x94, 0xef, 0xb8, 0x34, 0x10, 0x4c, 0x34, 0xd3, 0x74,
|
||||
0xc2, 0xa4, 0x6d, 0xce, 0xdf, 0x1f, 0xea, 0xe0, 0x11, 0x24, 0xac, 0x82, 0x45, 0x15, 0xd8, 0xad,
|
||||
0x06, 0x57, 0xdb, 0xef, 0x53, 0x27, 0x0c, 0xdc, 0x58, 0xe5, 0x35, 0x67, 0xeb, 0x49, 0xdb, 0x5c,
|
||||
0xac, 0x5e, 0xd2, 0xc7, 0x97, 0xb2, 0x60, 0x0d, 0x14, 0x89, 0xf3, 0xaa, 0xc1, 0x38, 0xfd, 0x99,
|
||||
0x60, 0x2e, 0x24, 0x6d, 0xb3, 0x78, 0xb7, 0xaf, 0x83, 0x07, 0x45, 0x87, 0xa3, 0x9f, 0xbd, 0xee,
|
||||
0xe8, 0xdf, 0x01, 0x65, 0xe5, 0xec, 0x80, 0x93, 0x20, 0x66, 0xd2, 0x5b, 0xac, 0xd2, 0x9b, 0xb3,
|
||||
0x17, 0x65, 0x72, 0xab, 0x23, 0x3d, 0x3c, 0x86, 0x86, 0xcf, 0xc7, 0x92, 0xbb, 0x79, 0xad, 0xa9,
|
||||
0x85, 0xb7, 0xc1, 0x42, 0xc4, 0xe9, 0x11, 0xe5, 0x9c, 0xba, 0x9d, 0xdb, 0xd5, 0x7f, 0x55, 0xfb,
|
||||
0xfc, 0x9e, 0xb4, 0xcd, 0x85, 0xbd, 0xe1, 0x16, 0x1e, 0xc5, 0xda, 0xdb, 0xad, 0x0b, 0x23, 0x73,
|
||||
0x76, 0x61, 0x64, 0xce, 0x2f, 0x8c, 0xcc, 0x9b, 0xc4, 0xd0, 0x5a, 0x89, 0xa1, 0x9d, 0x25, 0x86,
|
||||
0x76, 0x9e, 0x18, 0xda, 0xa7, 0xc4, 0xd0, 0xde, 0x7e, 0x36, 0x32, 0xcf, 0xcc, 0x2b, 0x3e, 0x50,
|
||||
0xbe, 0x05, 0x00, 0x00, 0xff, 0xff, 0xff, 0x56, 0x51, 0x57, 0xc2, 0x08, 0x00, 0x00,
|
||||
}
|
||||
|
||||
func (m *Lease) Marshal() (dAtA []byte, err error) {
|
||||
@ -225,6 +321,163 @@ func (m *Lease) MarshalToSizedBuffer(dAtA []byte) (int, error) {
|
||||
return len(dAtA) - i, nil
|
||||
}
|
||||
|
||||
func (m *LeaseCandidate) Marshal() (dAtA []byte, err error) {
|
||||
size := m.Size()
|
||||
dAtA = make([]byte, size)
|
||||
n, err := m.MarshalToSizedBuffer(dAtA[:size])
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return dAtA[:n], nil
|
||||
}
|
||||
|
||||
func (m *LeaseCandidate) MarshalTo(dAtA []byte) (int, error) {
|
||||
size := m.Size()
|
||||
return m.MarshalToSizedBuffer(dAtA[:size])
|
||||
}
|
||||
|
||||
func (m *LeaseCandidate) MarshalToSizedBuffer(dAtA []byte) (int, error) {
|
||||
i := len(dAtA)
|
||||
_ = i
|
||||
var l int
|
||||
_ = l
|
||||
{
|
||||
size, err := m.Spec.MarshalToSizedBuffer(dAtA[:i])
|
||||
if err != nil {
|
||||
return 0, err
|
||||
}
|
||||
i -= size
|
||||
i = encodeVarintGenerated(dAtA, i, uint64(size))
|
||||
}
|
||||
i--
|
||||
dAtA[i] = 0x12
|
||||
{
|
||||
size, err := m.ObjectMeta.MarshalToSizedBuffer(dAtA[:i])
|
||||
if err != nil {
|
||||
return 0, err
|
||||
}
|
||||
i -= size
|
||||
i = encodeVarintGenerated(dAtA, i, uint64(size))
|
||||
}
|
||||
i--
|
||||
dAtA[i] = 0xa
|
||||
return len(dAtA) - i, nil
|
||||
}
|
||||
|
||||
func (m *LeaseCandidateList) Marshal() (dAtA []byte, err error) {
|
||||
size := m.Size()
|
||||
dAtA = make([]byte, size)
|
||||
n, err := m.MarshalToSizedBuffer(dAtA[:size])
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return dAtA[:n], nil
|
||||
}
|
||||
|
||||
func (m *LeaseCandidateList) MarshalTo(dAtA []byte) (int, error) {
|
||||
size := m.Size()
|
||||
return m.MarshalToSizedBuffer(dAtA[:size])
|
||||
}
|
||||
|
||||
func (m *LeaseCandidateList) MarshalToSizedBuffer(dAtA []byte) (int, error) {
|
||||
i := len(dAtA)
|
||||
_ = i
|
||||
var l int
|
||||
_ = l
|
||||
if len(m.Items) > 0 {
|
||||
for iNdEx := len(m.Items) - 1; iNdEx >= 0; iNdEx-- {
|
||||
{
|
||||
size, err := m.Items[iNdEx].MarshalToSizedBuffer(dAtA[:i])
|
||||
if err != nil {
|
||||
return 0, err
|
||||
}
|
||||
i -= size
|
||||
i = encodeVarintGenerated(dAtA, i, uint64(size))
|
||||
}
|
||||
i--
|
||||
dAtA[i] = 0x12
|
||||
}
|
||||
}
|
||||
{
|
||||
size, err := m.ListMeta.MarshalToSizedBuffer(dAtA[:i])
|
||||
if err != nil {
|
||||
return 0, err
|
||||
}
|
||||
i -= size
|
||||
i = encodeVarintGenerated(dAtA, i, uint64(size))
|
||||
}
|
||||
i--
|
||||
dAtA[i] = 0xa
|
||||
return len(dAtA) - i, nil
|
||||
}
|
||||
|
||||
func (m *LeaseCandidateSpec) Marshal() (dAtA []byte, err error) {
|
||||
size := m.Size()
|
||||
dAtA = make([]byte, size)
|
||||
n, err := m.MarshalToSizedBuffer(dAtA[:size])
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return dAtA[:n], nil
|
||||
}
|
||||
|
||||
func (m *LeaseCandidateSpec) MarshalTo(dAtA []byte) (int, error) {
|
||||
size := m.Size()
|
||||
return m.MarshalToSizedBuffer(dAtA[:size])
|
||||
}
|
||||
|
||||
func (m *LeaseCandidateSpec) MarshalToSizedBuffer(dAtA []byte) (int, error) {
|
||||
i := len(dAtA)
|
||||
_ = i
|
||||
var l int
|
||||
_ = l
|
||||
i -= len(m.Strategy)
|
||||
copy(dAtA[i:], m.Strategy)
|
||||
i = encodeVarintGenerated(dAtA, i, uint64(len(m.Strategy)))
|
||||
i--
|
||||
dAtA[i] = 0x32
|
||||
i -= len(m.EmulationVersion)
|
||||
copy(dAtA[i:], m.EmulationVersion)
|
||||
i = encodeVarintGenerated(dAtA, i, uint64(len(m.EmulationVersion)))
|
||||
i--
|
||||
dAtA[i] = 0x2a
|
||||
i -= len(m.BinaryVersion)
|
||||
copy(dAtA[i:], m.BinaryVersion)
|
||||
i = encodeVarintGenerated(dAtA, i, uint64(len(m.BinaryVersion)))
|
||||
i--
|
||||
dAtA[i] = 0x22
|
||||
if m.RenewTime != nil {
|
||||
{
|
||||
size, err := m.RenewTime.MarshalToSizedBuffer(dAtA[:i])
|
||||
if err != nil {
|
||||
return 0, err
|
||||
}
|
||||
i -= size
|
||||
i = encodeVarintGenerated(dAtA, i, uint64(size))
|
||||
}
|
||||
i--
|
||||
dAtA[i] = 0x1a
|
||||
}
|
||||
if m.PingTime != nil {
|
||||
{
|
||||
size, err := m.PingTime.MarshalToSizedBuffer(dAtA[:i])
|
||||
if err != nil {
|
||||
return 0, err
|
||||
}
|
||||
i -= size
|
||||
i = encodeVarintGenerated(dAtA, i, uint64(size))
|
||||
}
|
||||
i--
|
||||
dAtA[i] = 0x12
|
||||
}
|
||||
i -= len(m.LeaseName)
|
||||
copy(dAtA[i:], m.LeaseName)
|
||||
i = encodeVarintGenerated(dAtA, i, uint64(len(m.LeaseName)))
|
||||
i--
|
||||
dAtA[i] = 0xa
|
||||
return len(dAtA) - i, nil
|
||||
}
|
||||
|
||||
func (m *LeaseList) Marshal() (dAtA []byte, err error) {
|
||||
size := m.Size()
|
||||
dAtA = make([]byte, size)
|
||||
@ -374,6 +627,61 @@ func (m *Lease) Size() (n int) {
|
||||
return n
|
||||
}
|
||||
|
||||
func (m *LeaseCandidate) Size() (n int) {
|
||||
if m == nil {
|
||||
return 0
|
||||
}
|
||||
var l int
|
||||
_ = l
|
||||
l = m.ObjectMeta.Size()
|
||||
n += 1 + l + sovGenerated(uint64(l))
|
||||
l = m.Spec.Size()
|
||||
n += 1 + l + sovGenerated(uint64(l))
|
||||
return n
|
||||
}
|
||||
|
||||
func (m *LeaseCandidateList) Size() (n int) {
|
||||
if m == nil {
|
||||
return 0
|
||||
}
|
||||
var l int
|
||||
_ = l
|
||||
l = m.ListMeta.Size()
|
||||
n += 1 + l + sovGenerated(uint64(l))
|
||||
if len(m.Items) > 0 {
|
||||
for _, e := range m.Items {
|
||||
l = e.Size()
|
||||
n += 1 + l + sovGenerated(uint64(l))
|
||||
}
|
||||
}
|
||||
return n
|
||||
}
|
||||
|
||||
func (m *LeaseCandidateSpec) Size() (n int) {
|
||||
if m == nil {
|
||||
return 0
|
||||
}
|
||||
var l int
|
||||
_ = l
|
||||
l = len(m.LeaseName)
|
||||
n += 1 + l + sovGenerated(uint64(l))
|
||||
if m.PingTime != nil {
|
||||
l = m.PingTime.Size()
|
||||
n += 1 + l + sovGenerated(uint64(l))
|
||||
}
|
||||
if m.RenewTime != nil {
|
||||
l = m.RenewTime.Size()
|
||||
n += 1 + l + sovGenerated(uint64(l))
|
||||
}
|
||||
l = len(m.BinaryVersion)
|
||||
n += 1 + l + sovGenerated(uint64(l))
|
||||
l = len(m.EmulationVersion)
|
||||
n += 1 + l + sovGenerated(uint64(l))
|
||||
l = len(m.Strategy)
|
||||
n += 1 + l + sovGenerated(uint64(l))
|
||||
return n
|
||||
}
|
||||
|
||||
func (m *LeaseList) Size() (n int) {
|
||||
if m == nil {
|
||||
return 0
|
||||
@ -443,6 +751,48 @@ func (this *Lease) String() string {
|
||||
}, "")
|
||||
return s
|
||||
}
|
||||
func (this *LeaseCandidate) String() string {
|
||||
if this == nil {
|
||||
return "nil"
|
||||
}
|
||||
s := strings.Join([]string{`&LeaseCandidate{`,
|
||||
`ObjectMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ObjectMeta), "ObjectMeta", "v1.ObjectMeta", 1), `&`, ``, 1) + `,`,
|
||||
`Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "LeaseCandidateSpec", "LeaseCandidateSpec", 1), `&`, ``, 1) + `,`,
|
||||
`}`,
|
||||
}, "")
|
||||
return s
|
||||
}
|
||||
func (this *LeaseCandidateList) String() string {
|
||||
if this == nil {
|
||||
return "nil"
|
||||
}
|
||||
repeatedStringForItems := "[]LeaseCandidate{"
|
||||
for _, f := range this.Items {
|
||||
repeatedStringForItems += strings.Replace(strings.Replace(f.String(), "LeaseCandidate", "LeaseCandidate", 1), `&`, ``, 1) + ","
|
||||
}
|
||||
repeatedStringForItems += "}"
|
||||
s := strings.Join([]string{`&LeaseCandidateList{`,
|
||||
`ListMeta:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ListMeta), "ListMeta", "v1.ListMeta", 1), `&`, ``, 1) + `,`,
|
||||
`Items:` + repeatedStringForItems + `,`,
|
||||
`}`,
|
||||
}, "")
|
||||
return s
|
||||
}
|
||||
func (this *LeaseCandidateSpec) String() string {
|
||||
if this == nil {
|
||||
return "nil"
|
||||
}
|
||||
s := strings.Join([]string{`&LeaseCandidateSpec{`,
|
||||
`LeaseName:` + fmt.Sprintf("%v", this.LeaseName) + `,`,
|
||||
`PingTime:` + strings.Replace(fmt.Sprintf("%v", this.PingTime), "MicroTime", "v1.MicroTime", 1) + `,`,
|
||||
`RenewTime:` + strings.Replace(fmt.Sprintf("%v", this.RenewTime), "MicroTime", "v1.MicroTime", 1) + `,`,
|
||||
`BinaryVersion:` + fmt.Sprintf("%v", this.BinaryVersion) + `,`,
|
||||
`EmulationVersion:` + fmt.Sprintf("%v", this.EmulationVersion) + `,`,
|
||||
`Strategy:` + fmt.Sprintf("%v", this.Strategy) + `,`,
|
||||
`}`,
|
||||
}, "")
|
||||
return s
|
||||
}
|
||||
func (this *LeaseList) String() string {
|
||||
if this == nil {
|
||||
return "nil"
|
||||
@ -599,6 +949,489 @@ func (m *Lease) Unmarshal(dAtA []byte) error {
|
||||
}
|
||||
return nil
|
||||
}
|
||||
func (m *LeaseCandidate) Unmarshal(dAtA []byte) error {
|
||||
l := len(dAtA)
|
||||
iNdEx := 0
|
||||
for iNdEx < l {
|
||||
preIndex := iNdEx
|
||||
var wire uint64
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return ErrIntOverflowGenerated
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
wire |= uint64(b&0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
fieldNum := int32(wire >> 3)
|
||||
wireType := int(wire & 0x7)
|
||||
if wireType == 4 {
|
||||
return fmt.Errorf("proto: LeaseCandidate: wiretype end group for non-group")
|
||||
}
|
||||
if fieldNum <= 0 {
|
||||
return fmt.Errorf("proto: LeaseCandidate: illegal tag %d (wire type %d)", fieldNum, wire)
|
||||
}
|
||||
switch fieldNum {
|
||||
case 1:
|
||||
if wireType != 2 {
|
||||
return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType)
|
||||
}
|
||||
var msglen int
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return ErrIntOverflowGenerated
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
msglen |= int(b&0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
if msglen < 0 {
|
||||
return ErrInvalidLengthGenerated
|
||||
}
|
||||
postIndex := iNdEx + msglen
|
||||
if postIndex < 0 {
|
||||
return ErrInvalidLengthGenerated
|
||||
}
|
||||
if postIndex > l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
|
||||
return err
|
||||
}
|
||||
iNdEx = postIndex
|
||||
case 2:
|
||||
if wireType != 2 {
|
||||
return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType)
|
||||
}
|
||||
var msglen int
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return ErrIntOverflowGenerated
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
msglen |= int(b&0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
if msglen < 0 {
|
||||
return ErrInvalidLengthGenerated
|
||||
}
|
||||
postIndex := iNdEx + msglen
|
||||
if postIndex < 0 {
|
||||
return ErrInvalidLengthGenerated
|
||||
}
|
||||
if postIndex > l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
|
||||
return err
|
||||
}
|
||||
iNdEx = postIndex
|
||||
default:
|
||||
iNdEx = preIndex
|
||||
skippy, err := skipGenerated(dAtA[iNdEx:])
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if (skippy < 0) || (iNdEx+skippy) < 0 {
|
||||
return ErrInvalidLengthGenerated
|
||||
}
|
||||
if (iNdEx + skippy) > l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
iNdEx += skippy
|
||||
}
|
||||
}
|
||||
|
||||
if iNdEx > l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
return nil
|
||||
}
|
||||
func (m *LeaseCandidateList) Unmarshal(dAtA []byte) error {
|
||||
l := len(dAtA)
|
||||
iNdEx := 0
|
||||
for iNdEx < l {
|
||||
preIndex := iNdEx
|
||||
var wire uint64
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return ErrIntOverflowGenerated
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
wire |= uint64(b&0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
fieldNum := int32(wire >> 3)
|
||||
wireType := int(wire & 0x7)
|
||||
if wireType == 4 {
|
||||
return fmt.Errorf("proto: LeaseCandidateList: wiretype end group for non-group")
|
||||
}
|
||||
if fieldNum <= 0 {
|
||||
return fmt.Errorf("proto: LeaseCandidateList: illegal tag %d (wire type %d)", fieldNum, wire)
|
||||
}
|
||||
switch fieldNum {
|
||||
case 1:
|
||||
if wireType != 2 {
|
||||
return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType)
|
||||
}
|
||||
var msglen int
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return ErrIntOverflowGenerated
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
msglen |= int(b&0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
if msglen < 0 {
|
||||
return ErrInvalidLengthGenerated
|
||||
}
|
||||
postIndex := iNdEx + msglen
|
||||
if postIndex < 0 {
|
||||
return ErrInvalidLengthGenerated
|
||||
}
|
||||
if postIndex > l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
|
||||
return err
|
||||
}
|
||||
iNdEx = postIndex
|
||||
case 2:
|
||||
if wireType != 2 {
|
||||
return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType)
|
||||
}
|
||||
var msglen int
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return ErrIntOverflowGenerated
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
msglen |= int(b&0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
if msglen < 0 {
|
||||
return ErrInvalidLengthGenerated
|
||||
}
|
||||
postIndex := iNdEx + msglen
|
||||
if postIndex < 0 {
|
||||
return ErrInvalidLengthGenerated
|
||||
}
|
||||
if postIndex > l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
m.Items = append(m.Items, LeaseCandidate{})
|
||||
if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
|
||||
return err
|
||||
}
|
||||
iNdEx = postIndex
|
||||
default:
|
||||
iNdEx = preIndex
|
||||
skippy, err := skipGenerated(dAtA[iNdEx:])
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if (skippy < 0) || (iNdEx+skippy) < 0 {
|
||||
return ErrInvalidLengthGenerated
|
||||
}
|
||||
if (iNdEx + skippy) > l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
iNdEx += skippy
|
||||
}
|
||||
}
|
||||
|
||||
if iNdEx > l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
return nil
|
||||
}
|
||||
func (m *LeaseCandidateSpec) Unmarshal(dAtA []byte) error {
|
||||
l := len(dAtA)
|
||||
iNdEx := 0
|
||||
for iNdEx < l {
|
||||
preIndex := iNdEx
|
||||
var wire uint64
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return ErrIntOverflowGenerated
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
wire |= uint64(b&0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
fieldNum := int32(wire >> 3)
|
||||
wireType := int(wire & 0x7)
|
||||
if wireType == 4 {
|
||||
return fmt.Errorf("proto: LeaseCandidateSpec: wiretype end group for non-group")
|
||||
}
|
||||
if fieldNum <= 0 {
|
||||
return fmt.Errorf("proto: LeaseCandidateSpec: illegal tag %d (wire type %d)", fieldNum, wire)
|
||||
}
|
||||
switch fieldNum {
|
||||
case 1:
|
||||
if wireType != 2 {
|
||||
return fmt.Errorf("proto: wrong wireType = %d for field LeaseName", wireType)
|
||||
}
|
||||
var stringLen uint64
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return ErrIntOverflowGenerated
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
stringLen |= uint64(b&0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
intStringLen := int(stringLen)
|
||||
if intStringLen < 0 {
|
||||
return ErrInvalidLengthGenerated
|
||||
}
|
||||
postIndex := iNdEx + intStringLen
|
||||
if postIndex < 0 {
|
||||
return ErrInvalidLengthGenerated
|
||||
}
|
||||
if postIndex > l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
m.LeaseName = string(dAtA[iNdEx:postIndex])
|
||||
iNdEx = postIndex
|
||||
case 2:
|
||||
if wireType != 2 {
|
||||
return fmt.Errorf("proto: wrong wireType = %d for field PingTime", wireType)
|
||||
}
|
||||
var msglen int
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return ErrIntOverflowGenerated
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
msglen |= int(b&0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
if msglen < 0 {
|
||||
return ErrInvalidLengthGenerated
|
||||
}
|
||||
postIndex := iNdEx + msglen
|
||||
if postIndex < 0 {
|
||||
return ErrInvalidLengthGenerated
|
||||
}
|
||||
if postIndex > l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
if m.PingTime == nil {
|
||||
m.PingTime = &v1.MicroTime{}
|
||||
}
|
||||
if err := m.PingTime.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
|
||||
return err
|
||||
}
|
||||
iNdEx = postIndex
|
||||
case 3:
|
||||
if wireType != 2 {
|
||||
return fmt.Errorf("proto: wrong wireType = %d for field RenewTime", wireType)
|
||||
}
|
||||
var msglen int
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return ErrIntOverflowGenerated
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
msglen |= int(b&0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
if msglen < 0 {
|
||||
return ErrInvalidLengthGenerated
|
||||
}
|
||||
postIndex := iNdEx + msglen
|
||||
if postIndex < 0 {
|
||||
return ErrInvalidLengthGenerated
|
||||
}
|
||||
if postIndex > l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
if m.RenewTime == nil {
|
||||
m.RenewTime = &v1.MicroTime{}
|
||||
}
|
||||
if err := m.RenewTime.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
|
||||
return err
|
||||
}
|
||||
iNdEx = postIndex
|
||||
case 4:
|
||||
if wireType != 2 {
|
||||
return fmt.Errorf("proto: wrong wireType = %d for field BinaryVersion", wireType)
|
||||
}
|
||||
var stringLen uint64
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return ErrIntOverflowGenerated
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
stringLen |= uint64(b&0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
intStringLen := int(stringLen)
|
||||
if intStringLen < 0 {
|
||||
return ErrInvalidLengthGenerated
|
||||
}
|
||||
postIndex := iNdEx + intStringLen
|
||||
if postIndex < 0 {
|
||||
return ErrInvalidLengthGenerated
|
||||
}
|
||||
if postIndex > l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
m.BinaryVersion = string(dAtA[iNdEx:postIndex])
|
||||
iNdEx = postIndex
|
||||
case 5:
|
||||
if wireType != 2 {
|
||||
return fmt.Errorf("proto: wrong wireType = %d for field EmulationVersion", wireType)
|
||||
}
|
||||
var stringLen uint64
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return ErrIntOverflowGenerated
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
stringLen |= uint64(b&0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
intStringLen := int(stringLen)
|
||||
if intStringLen < 0 {
|
||||
return ErrInvalidLengthGenerated
|
||||
}
|
||||
postIndex := iNdEx + intStringLen
|
||||
if postIndex < 0 {
|
||||
return ErrInvalidLengthGenerated
|
||||
}
|
||||
if postIndex > l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
m.EmulationVersion = string(dAtA[iNdEx:postIndex])
|
||||
iNdEx = postIndex
|
||||
case 6:
|
||||
if wireType != 2 {
|
||||
return fmt.Errorf("proto: wrong wireType = %d for field Strategy", wireType)
|
||||
}
|
||||
var stringLen uint64
|
||||
for shift := uint(0); ; shift += 7 {
|
||||
if shift >= 64 {
|
||||
return ErrIntOverflowGenerated
|
||||
}
|
||||
if iNdEx >= l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
b := dAtA[iNdEx]
|
||||
iNdEx++
|
||||
stringLen |= uint64(b&0x7F) << shift
|
||||
if b < 0x80 {
|
||||
break
|
||||
}
|
||||
}
|
||||
intStringLen := int(stringLen)
|
||||
if intStringLen < 0 {
|
||||
return ErrInvalidLengthGenerated
|
||||
}
|
||||
postIndex := iNdEx + intStringLen
|
||||
if postIndex < 0 {
|
||||
return ErrInvalidLengthGenerated
|
||||
}
|
||||
if postIndex > l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
m.Strategy = k8s_io_api_coordination_v1.CoordinatedLeaseStrategy(dAtA[iNdEx:postIndex])
|
||||
iNdEx = postIndex
|
||||
default:
|
||||
iNdEx = preIndex
|
||||
skippy, err := skipGenerated(dAtA[iNdEx:])
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if (skippy < 0) || (iNdEx+skippy) < 0 {
|
||||
return ErrInvalidLengthGenerated
|
||||
}
|
||||
if (iNdEx + skippy) > l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
iNdEx += skippy
|
||||
}
|
||||
}
|
||||
|
||||
if iNdEx > l {
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
return nil
|
||||
}
|
||||
func (m *LeaseList) Unmarshal(dAtA []byte) error {
|
||||
l := len(dAtA)
|
||||
iNdEx := 0
|
||||
|
@ -41,6 +41,75 @@ message Lease {
|
||||
optional LeaseSpec spec = 2;
|
||||
}
|
||||
|
||||
// LeaseCandidate defines a candidate for a Lease object.
|
||||
// Candidates are created such that coordinated leader election will pick the best leader from the list of candidates.
|
||||
message LeaseCandidate {
|
||||
// More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata
|
||||
// +optional
|
||||
optional .k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1;
|
||||
|
||||
// spec contains the specification of the Lease.
|
||||
// More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status
|
||||
// +optional
|
||||
optional LeaseCandidateSpec spec = 2;
|
||||
}
|
||||
|
||||
// LeaseCandidateList is a list of Lease objects.
|
||||
message LeaseCandidateList {
|
||||
// Standard list metadata.
|
||||
// More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata
|
||||
// +optional
|
||||
optional .k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1;
|
||||
|
||||
// items is a list of schema objects.
|
||||
repeated LeaseCandidate items = 2;
|
||||
}
|
||||
|
||||
// LeaseCandidateSpec is a specification of a Lease.
|
||||
message LeaseCandidateSpec {
|
||||
// LeaseName is the name of the lease for which this candidate is contending.
|
||||
// The limits on this field are the same as on Lease.name. Multiple lease candidates
|
||||
// may reference the same Lease.name.
|
||||
// This field is immutable.
|
||||
// +required
|
||||
optional string leaseName = 1;
|
||||
|
||||
// PingTime is the last time that the server has requested the LeaseCandidate
|
||||
// to renew. It is only done during leader election to check if any
|
||||
// LeaseCandidates have become ineligible. When PingTime is updated, the
|
||||
// LeaseCandidate will respond by updating RenewTime.
|
||||
// +optional
|
||||
optional .k8s.io.apimachinery.pkg.apis.meta.v1.MicroTime pingTime = 2;
|
||||
|
||||
// RenewTime is the time that the LeaseCandidate was last updated.
|
||||
// Any time a Lease needs to do leader election, the PingTime field
|
||||
// is updated to signal to the LeaseCandidate that they should update
|
||||
// the RenewTime.
|
||||
// Old LeaseCandidate objects are also garbage collected if it has been hours
|
||||
// since the last renew. The PingTime field is updated regularly to prevent
|
||||
// garbage collection for still active LeaseCandidates.
|
||||
// +optional
|
||||
optional .k8s.io.apimachinery.pkg.apis.meta.v1.MicroTime renewTime = 3;
|
||||
|
||||
// BinaryVersion is the binary version. It must be in a semver format without leading `v`.
|
||||
// This field is required.
|
||||
// +required
|
||||
optional string binaryVersion = 4;
|
||||
|
||||
// EmulationVersion is the emulation version. It must be in a semver format without leading `v`.
|
||||
// EmulationVersion must be less than or equal to BinaryVersion.
|
||||
// This field is required when strategy is "OldestEmulationVersion"
|
||||
// +optional
|
||||
optional string emulationVersion = 5;
|
||||
|
||||
// Strategy is the strategy that coordinated leader election will use for picking the leader.
|
||||
// If multiple candidates for the same Lease return different strategies, the strategy provided
|
||||
// by the candidate with the latest BinaryVersion will be used. If there is still conflict,
|
||||
// this is a user error and coordinated leader election will not operate the Lease until resolved.
|
||||
// +required
|
||||
optional string strategy = 6;
|
||||
}
|
||||
|
||||
// LeaseList is a list of Lease objects.
|
||||
message LeaseList {
|
||||
// Standard list metadata.
|
||||
|
@ -37,6 +37,40 @@ func (Lease) SwaggerDoc() map[string]string {
|
||||
return map_Lease
|
||||
}
|
||||
|
||||
var map_LeaseCandidate = map[string]string{
|
||||
"": "LeaseCandidate defines a candidate for a Lease object. Candidates are created such that coordinated leader election will pick the best leader from the list of candidates.",
|
||||
"metadata": "More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata",
|
||||
"spec": "spec contains the specification of the Lease. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status",
|
||||
}
|
||||
|
||||
func (LeaseCandidate) SwaggerDoc() map[string]string {
|
||||
return map_LeaseCandidate
|
||||
}
|
||||
|
||||
var map_LeaseCandidateList = map[string]string{
|
||||
"": "LeaseCandidateList is a list of Lease objects.",
|
||||
"metadata": "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata",
|
||||
"items": "items is a list of schema objects.",
|
||||
}
|
||||
|
||||
func (LeaseCandidateList) SwaggerDoc() map[string]string {
|
||||
return map_LeaseCandidateList
|
||||
}
|
||||
|
||||
var map_LeaseCandidateSpec = map[string]string{
|
||||
"": "LeaseCandidateSpec is a specification of a Lease.",
|
||||
"leaseName": "LeaseName is the name of the lease for which this candidate is contending. The limits on this field are the same as on Lease.name. Multiple lease candidates may reference the same Lease.name. This field is immutable.",
|
||||
"pingTime": "PingTime is the last time that the server has requested the LeaseCandidate to renew. It is only done during leader election to check if any LeaseCandidates have become ineligible. When PingTime is updated, the LeaseCandidate will respond by updating RenewTime.",
|
||||
"renewTime": "RenewTime is the time that the LeaseCandidate was last updated. Any time a Lease needs to do leader election, the PingTime field is updated to signal to the LeaseCandidate that they should update the RenewTime. Old LeaseCandidate objects are also garbage collected if it has been hours since the last renew. The PingTime field is updated regularly to prevent garbage collection for still active LeaseCandidates.",
|
||||
"binaryVersion": "BinaryVersion is the binary version. It must be in a semver format without leading `v`. This field is required.",
|
||||
"emulationVersion": "EmulationVersion is the emulation version. It must be in a semver format without leading `v`. EmulationVersion must be less than or equal to BinaryVersion. This field is required when strategy is \"OldestEmulationVersion\"",
|
||||
"strategy": "Strategy is the strategy that coordinated leader election will use for picking the leader. If multiple candidates for the same Lease return different strategies, the strategy provided by the candidate with the latest BinaryVersion will be used. If there is still conflict, this is a user error and coordinated leader election will not operate the Lease until resolved.",
|
||||
}
|
||||
|
||||
func (LeaseCandidateSpec) SwaggerDoc() map[string]string {
|
||||
return map_LeaseCandidateSpec
|
||||
}
|
||||
|
||||
var map_LeaseList = map[string]string{
|
||||
"": "LeaseList is a list of Lease objects.",
|
||||
"metadata": "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata",
|
||||
|
@ -53,6 +53,90 @@ func (in *Lease) DeepCopyObject() runtime.Object {
|
||||
return nil
|
||||
}
|
||||
|
||||
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
|
||||
func (in *LeaseCandidate) DeepCopyInto(out *LeaseCandidate) {
|
||||
*out = *in
|
||||
out.TypeMeta = in.TypeMeta
|
||||
in.ObjectMeta.DeepCopyInto(&out.ObjectMeta)
|
||||
in.Spec.DeepCopyInto(&out.Spec)
|
||||
return
|
||||
}
|
||||
|
||||
// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LeaseCandidate.
|
||||
func (in *LeaseCandidate) DeepCopy() *LeaseCandidate {
|
||||
if in == nil {
|
||||
return nil
|
||||
}
|
||||
out := new(LeaseCandidate)
|
||||
in.DeepCopyInto(out)
|
||||
return out
|
||||
}
|
||||
|
||||
// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
|
||||
func (in *LeaseCandidate) DeepCopyObject() runtime.Object {
|
||||
if c := in.DeepCopy(); c != nil {
|
||||
return c
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
|
||||
func (in *LeaseCandidateList) DeepCopyInto(out *LeaseCandidateList) {
|
||||
*out = *in
|
||||
out.TypeMeta = in.TypeMeta
|
||||
in.ListMeta.DeepCopyInto(&out.ListMeta)
|
||||
if in.Items != nil {
|
||||
in, out := &in.Items, &out.Items
|
||||
*out = make([]LeaseCandidate, len(*in))
|
||||
for i := range *in {
|
||||
(*in)[i].DeepCopyInto(&(*out)[i])
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LeaseCandidateList.
|
||||
func (in *LeaseCandidateList) DeepCopy() *LeaseCandidateList {
|
||||
if in == nil {
|
||||
return nil
|
||||
}
|
||||
out := new(LeaseCandidateList)
|
||||
in.DeepCopyInto(out)
|
||||
return out
|
||||
}
|
||||
|
||||
// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
|
||||
func (in *LeaseCandidateList) DeepCopyObject() runtime.Object {
|
||||
if c := in.DeepCopy(); c != nil {
|
||||
return c
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
|
||||
func (in *LeaseCandidateSpec) DeepCopyInto(out *LeaseCandidateSpec) {
|
||||
*out = *in
|
||||
if in.PingTime != nil {
|
||||
in, out := &in.PingTime, &out.PingTime
|
||||
*out = (*in).DeepCopy()
|
||||
}
|
||||
if in.RenewTime != nil {
|
||||
in, out := &in.RenewTime, &out.RenewTime
|
||||
*out = (*in).DeepCopy()
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LeaseCandidateSpec.
|
||||
func (in *LeaseCandidateSpec) DeepCopy() *LeaseCandidateSpec {
|
||||
if in == nil {
|
||||
return nil
|
||||
}
|
||||
out := new(LeaseCandidateSpec)
|
||||
in.DeepCopyInto(out)
|
||||
return out
|
||||
}
|
||||
|
||||
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
|
||||
func (in *LeaseList) DeepCopyInto(out *LeaseList) {
|
||||
*out = *in
|
||||
|
@ -49,6 +49,42 @@ func (in *Lease) APILifecycleRemoved() (major, minor int) {
|
||||
return 1, 22
|
||||
}
|
||||
|
||||
// APILifecycleIntroduced is an autogenerated function, returning the release in which the API struct was introduced as int versions of major and minor for comparison.
|
||||
// It is controlled by "k8s:prerelease-lifecycle-gen:introduced" tags in types.go.
|
||||
func (in *LeaseCandidate) APILifecycleIntroduced() (major, minor int) {
|
||||
return 1, 33
|
||||
}
|
||||
|
||||
// APILifecycleDeprecated is an autogenerated function, returning the release in which the API struct was or will be deprecated as int versions of major and minor for comparison.
|
||||
// It is controlled by "k8s:prerelease-lifecycle-gen:deprecated" tags in types.go or "k8s:prerelease-lifecycle-gen:introduced" plus three minor.
|
||||
func (in *LeaseCandidate) APILifecycleDeprecated() (major, minor int) {
|
||||
return 1, 36
|
||||
}
|
||||
|
||||
// APILifecycleRemoved is an autogenerated function, returning the release in which the API is no longer served as int versions of major and minor for comparison.
|
||||
// It is controlled by "k8s:prerelease-lifecycle-gen:removed" tags in types.go or "k8s:prerelease-lifecycle-gen:deprecated" plus three minor.
|
||||
func (in *LeaseCandidate) APILifecycleRemoved() (major, minor int) {
|
||||
return 1, 39
|
||||
}
|
||||
|
||||
// APILifecycleIntroduced is an autogenerated function, returning the release in which the API struct was introduced as int versions of major and minor for comparison.
|
||||
// It is controlled by "k8s:prerelease-lifecycle-gen:introduced" tags in types.go.
|
||||
func (in *LeaseCandidateList) APILifecycleIntroduced() (major, minor int) {
|
||||
return 1, 33
|
||||
}
|
||||
|
||||
// APILifecycleDeprecated is an autogenerated function, returning the release in which the API struct was or will be deprecated as int versions of major and minor for comparison.
|
||||
// It is controlled by "k8s:prerelease-lifecycle-gen:deprecated" tags in types.go or "k8s:prerelease-lifecycle-gen:introduced" plus three minor.
|
||||
func (in *LeaseCandidateList) APILifecycleDeprecated() (major, minor int) {
|
||||
return 1, 36
|
||||
}
|
||||
|
||||
// APILifecycleRemoved is an autogenerated function, returning the release in which the API is no longer served as int versions of major and minor for comparison.
|
||||
// It is controlled by "k8s:prerelease-lifecycle-gen:removed" tags in types.go or "k8s:prerelease-lifecycle-gen:deprecated" plus three minor.
|
||||
func (in *LeaseCandidateList) APILifecycleRemoved() (major, minor int) {
|
||||
return 1, 39
|
||||
}
|
||||
|
||||
// APILifecycleIntroduced is an autogenerated function, returning the release in which the API struct was introduced as int versions of major and minor for comparison.
|
||||
// It is controlled by "k8s:prerelease-lifecycle-gen:introduced" tags in types.go.
|
||||
func (in *LeaseList) APILifecycleIntroduced() (major, minor int) {
|
||||
|
54
staging/src/k8s.io/api/testdata/HEAD/coordination.k8s.io.v1beta1.LeaseCandidate.json
vendored
Normal file
54
staging/src/k8s.io/api/testdata/HEAD/coordination.k8s.io.v1beta1.LeaseCandidate.json
vendored
Normal file
@ -0,0 +1,54 @@
|
||||
{
|
||||
"kind": "LeaseCandidate",
|
||||
"apiVersion": "coordination.k8s.io/v1beta1",
|
||||
"metadata": {
|
||||
"name": "nameValue",
|
||||
"generateName": "generateNameValue",
|
||||
"namespace": "namespaceValue",
|
||||
"selfLink": "selfLinkValue",
|
||||
"uid": "uidValue",
|
||||
"resourceVersion": "resourceVersionValue",
|
||||
"generation": 7,
|
||||
"creationTimestamp": "2008-01-01T01:01:01Z",
|
||||
"deletionTimestamp": "2009-01-01T01:01:01Z",
|
||||
"deletionGracePeriodSeconds": 10,
|
||||
"labels": {
|
||||
"labelsKey": "labelsValue"
|
||||
},
|
||||
"annotations": {
|
||||
"annotationsKey": "annotationsValue"
|
||||
},
|
||||
"ownerReferences": [
|
||||
{
|
||||
"apiVersion": "apiVersionValue",
|
||||
"kind": "kindValue",
|
||||
"name": "nameValue",
|
||||
"uid": "uidValue",
|
||||
"controller": true,
|
||||
"blockOwnerDeletion": true
|
||||
}
|
||||
],
|
||||
"finalizers": [
|
||||
"finalizersValue"
|
||||
],
|
||||
"managedFields": [
|
||||
{
|
||||
"manager": "managerValue",
|
||||
"operation": "operationValue",
|
||||
"apiVersion": "apiVersionValue",
|
||||
"time": "2004-01-01T01:01:01Z",
|
||||
"fieldsType": "fieldsTypeValue",
|
||||
"fieldsV1": {},
|
||||
"subresource": "subresourceValue"
|
||||
}
|
||||
]
|
||||
},
|
||||
"spec": {
|
||||
"leaseName": "leaseNameValue",
|
||||
"pingTime": "2002-01-01T01:01:01.000002Z",
|
||||
"renewTime": "2003-01-01T01:01:01.000003Z",
|
||||
"binaryVersion": "binaryVersionValue",
|
||||
"emulationVersion": "emulationVersionValue",
|
||||
"strategy": "strategyValue"
|
||||
}
|
||||
}
|
BIN
staging/src/k8s.io/api/testdata/HEAD/coordination.k8s.io.v1beta1.LeaseCandidate.pb
vendored
Normal file
BIN
staging/src/k8s.io/api/testdata/HEAD/coordination.k8s.io.v1beta1.LeaseCandidate.pb
vendored
Normal file
Binary file not shown.
41
staging/src/k8s.io/api/testdata/HEAD/coordination.k8s.io.v1beta1.LeaseCandidate.yaml
vendored
Normal file
41
staging/src/k8s.io/api/testdata/HEAD/coordination.k8s.io.v1beta1.LeaseCandidate.yaml
vendored
Normal file
@ -0,0 +1,41 @@
|
||||
apiVersion: coordination.k8s.io/v1beta1
|
||||
kind: LeaseCandidate
|
||||
metadata:
|
||||
annotations:
|
||||
annotationsKey: annotationsValue
|
||||
creationTimestamp: "2008-01-01T01:01:01Z"
|
||||
deletionGracePeriodSeconds: 10
|
||||
deletionTimestamp: "2009-01-01T01:01:01Z"
|
||||
finalizers:
|
||||
- finalizersValue
|
||||
generateName: generateNameValue
|
||||
generation: 7
|
||||
labels:
|
||||
labelsKey: labelsValue
|
||||
managedFields:
|
||||
- apiVersion: apiVersionValue
|
||||
fieldsType: fieldsTypeValue
|
||||
fieldsV1: {}
|
||||
manager: managerValue
|
||||
operation: operationValue
|
||||
subresource: subresourceValue
|
||||
time: "2004-01-01T01:01:01Z"
|
||||
name: nameValue
|
||||
namespace: namespaceValue
|
||||
ownerReferences:
|
||||
- apiVersion: apiVersionValue
|
||||
blockOwnerDeletion: true
|
||||
controller: true
|
||||
kind: kindValue
|
||||
name: nameValue
|
||||
uid: uidValue
|
||||
resourceVersion: resourceVersionValue
|
||||
selfLink: selfLinkValue
|
||||
uid: uidValue
|
||||
spec:
|
||||
binaryVersion: binaryVersionValue
|
||||
emulationVersion: emulationVersionValue
|
||||
leaseName: leaseNameValue
|
||||
pingTime: "2002-01-01T01:01:01.000002Z"
|
||||
renewTime: "2003-01-01T01:01:01.000003Z"
|
||||
strategy: strategyValue
|
@ -0,0 +1,255 @@
|
||||
/*
|
||||
Copyright The Kubernetes Authors.
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
*/
|
||||
|
||||
// Code generated by applyconfiguration-gen. DO NOT EDIT.
|
||||
|
||||
package v1beta1
|
||||
|
||||
import (
|
||||
coordinationv1beta1 "k8s.io/api/coordination/v1beta1"
|
||||
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
types "k8s.io/apimachinery/pkg/types"
|
||||
managedfields "k8s.io/apimachinery/pkg/util/managedfields"
|
||||
internal "k8s.io/client-go/applyconfigurations/internal"
|
||||
v1 "k8s.io/client-go/applyconfigurations/meta/v1"
|
||||
)
|
||||
|
||||
// LeaseCandidateApplyConfiguration represents a declarative configuration of the LeaseCandidate type for use
|
||||
// with apply.
|
||||
type LeaseCandidateApplyConfiguration struct {
|
||||
v1.TypeMetaApplyConfiguration `json:",inline"`
|
||||
*v1.ObjectMetaApplyConfiguration `json:"metadata,omitempty"`
|
||||
Spec *LeaseCandidateSpecApplyConfiguration `json:"spec,omitempty"`
|
||||
}
|
||||
|
||||
// LeaseCandidate constructs a declarative configuration of the LeaseCandidate type for use with
|
||||
// apply.
|
||||
func LeaseCandidate(name, namespace string) *LeaseCandidateApplyConfiguration {
|
||||
b := &LeaseCandidateApplyConfiguration{}
|
||||
b.WithName(name)
|
||||
b.WithNamespace(namespace)
|
||||
b.WithKind("LeaseCandidate")
|
||||
b.WithAPIVersion("coordination.k8s.io/v1beta1")
|
||||
return b
|
||||
}
|
||||
|
||||
// ExtractLeaseCandidate extracts the applied configuration owned by fieldManager from
|
||||
// leaseCandidate. If no managedFields are found in leaseCandidate for fieldManager, a
|
||||
// LeaseCandidateApplyConfiguration is returned with only the Name, Namespace (if applicable),
|
||||
// APIVersion and Kind populated. It is possible that no managed fields were found for because other
|
||||
// field managers have taken ownership of all the fields previously owned by fieldManager, or because
|
||||
// the fieldManager never owned fields any fields.
|
||||
// leaseCandidate must be a unmodified LeaseCandidate API object that was retrieved from the Kubernetes API.
|
||||
// ExtractLeaseCandidate provides a way to perform a extract/modify-in-place/apply workflow.
|
||||
// Note that an extracted apply configuration will contain fewer fields than what the fieldManager previously
|
||||
// applied if another fieldManager has updated or force applied any of the previously applied fields.
|
||||
// Experimental!
|
||||
func ExtractLeaseCandidate(leaseCandidate *coordinationv1beta1.LeaseCandidate, fieldManager string) (*LeaseCandidateApplyConfiguration, error) {
|
||||
return extractLeaseCandidate(leaseCandidate, fieldManager, "")
|
||||
}
|
||||
|
||||
// ExtractLeaseCandidateStatus is the same as ExtractLeaseCandidate except
|
||||
// that it extracts the status subresource applied configuration.
|
||||
// Experimental!
|
||||
func ExtractLeaseCandidateStatus(leaseCandidate *coordinationv1beta1.LeaseCandidate, fieldManager string) (*LeaseCandidateApplyConfiguration, error) {
|
||||
return extractLeaseCandidate(leaseCandidate, fieldManager, "status")
|
||||
}
|
||||
|
||||
func extractLeaseCandidate(leaseCandidate *coordinationv1beta1.LeaseCandidate, fieldManager string, subresource string) (*LeaseCandidateApplyConfiguration, error) {
|
||||
b := &LeaseCandidateApplyConfiguration{}
|
||||
err := managedfields.ExtractInto(leaseCandidate, internal.Parser().Type("io.k8s.api.coordination.v1beta1.LeaseCandidate"), fieldManager, b, subresource)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
b.WithName(leaseCandidate.Name)
|
||||
b.WithNamespace(leaseCandidate.Namespace)
|
||||
|
||||
b.WithKind("LeaseCandidate")
|
||||
b.WithAPIVersion("coordination.k8s.io/v1beta1")
|
||||
return b, nil
|
||||
}
|
||||
|
||||
// WithKind sets the Kind field in the declarative configuration to the given value
|
||||
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||
// If called multiple times, the Kind field is set to the value of the last call.
|
||||
func (b *LeaseCandidateApplyConfiguration) WithKind(value string) *LeaseCandidateApplyConfiguration {
|
||||
b.TypeMetaApplyConfiguration.Kind = &value
|
||||
return b
|
||||
}
|
||||
|
||||
// WithAPIVersion sets the APIVersion field in the declarative configuration to the given value
|
||||
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||
// If called multiple times, the APIVersion field is set to the value of the last call.
|
||||
func (b *LeaseCandidateApplyConfiguration) WithAPIVersion(value string) *LeaseCandidateApplyConfiguration {
|
||||
b.TypeMetaApplyConfiguration.APIVersion = &value
|
||||
return b
|
||||
}
|
||||
|
||||
// WithName sets the Name field in the declarative configuration to the given value
|
||||
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||
// If called multiple times, the Name field is set to the value of the last call.
|
||||
func (b *LeaseCandidateApplyConfiguration) WithName(value string) *LeaseCandidateApplyConfiguration {
|
||||
b.ensureObjectMetaApplyConfigurationExists()
|
||||
b.ObjectMetaApplyConfiguration.Name = &value
|
||||
return b
|
||||
}
|
||||
|
||||
// WithGenerateName sets the GenerateName field in the declarative configuration to the given value
|
||||
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||
// If called multiple times, the GenerateName field is set to the value of the last call.
|
||||
func (b *LeaseCandidateApplyConfiguration) WithGenerateName(value string) *LeaseCandidateApplyConfiguration {
|
||||
b.ensureObjectMetaApplyConfigurationExists()
|
||||
b.ObjectMetaApplyConfiguration.GenerateName = &value
|
||||
return b
|
||||
}
|
||||
|
||||
// WithNamespace sets the Namespace field in the declarative configuration to the given value
|
||||
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||
// If called multiple times, the Namespace field is set to the value of the last call.
|
||||
func (b *LeaseCandidateApplyConfiguration) WithNamespace(value string) *LeaseCandidateApplyConfiguration {
|
||||
b.ensureObjectMetaApplyConfigurationExists()
|
||||
b.ObjectMetaApplyConfiguration.Namespace = &value
|
||||
return b
|
||||
}
|
||||
|
||||
// WithUID sets the UID field in the declarative configuration to the given value
|
||||
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||
// If called multiple times, the UID field is set to the value of the last call.
|
||||
func (b *LeaseCandidateApplyConfiguration) WithUID(value types.UID) *LeaseCandidateApplyConfiguration {
|
||||
b.ensureObjectMetaApplyConfigurationExists()
|
||||
b.ObjectMetaApplyConfiguration.UID = &value
|
||||
return b
|
||||
}
|
||||
|
||||
// WithResourceVersion sets the ResourceVersion field in the declarative configuration to the given value
|
||||
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||
// If called multiple times, the ResourceVersion field is set to the value of the last call.
|
||||
func (b *LeaseCandidateApplyConfiguration) WithResourceVersion(value string) *LeaseCandidateApplyConfiguration {
|
||||
b.ensureObjectMetaApplyConfigurationExists()
|
||||
b.ObjectMetaApplyConfiguration.ResourceVersion = &value
|
||||
return b
|
||||
}
|
||||
|
||||
// WithGeneration sets the Generation field in the declarative configuration to the given value
|
||||
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||
// If called multiple times, the Generation field is set to the value of the last call.
|
||||
func (b *LeaseCandidateApplyConfiguration) WithGeneration(value int64) *LeaseCandidateApplyConfiguration {
|
||||
b.ensureObjectMetaApplyConfigurationExists()
|
||||
b.ObjectMetaApplyConfiguration.Generation = &value
|
||||
return b
|
||||
}
|
||||
|
||||
// WithCreationTimestamp sets the CreationTimestamp field in the declarative configuration to the given value
|
||||
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||
// If called multiple times, the CreationTimestamp field is set to the value of the last call.
|
||||
func (b *LeaseCandidateApplyConfiguration) WithCreationTimestamp(value metav1.Time) *LeaseCandidateApplyConfiguration {
|
||||
b.ensureObjectMetaApplyConfigurationExists()
|
||||
b.ObjectMetaApplyConfiguration.CreationTimestamp = &value
|
||||
return b
|
||||
}
|
||||
|
||||
// WithDeletionTimestamp sets the DeletionTimestamp field in the declarative configuration to the given value
|
||||
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||
// If called multiple times, the DeletionTimestamp field is set to the value of the last call.
|
||||
func (b *LeaseCandidateApplyConfiguration) WithDeletionTimestamp(value metav1.Time) *LeaseCandidateApplyConfiguration {
|
||||
b.ensureObjectMetaApplyConfigurationExists()
|
||||
b.ObjectMetaApplyConfiguration.DeletionTimestamp = &value
|
||||
return b
|
||||
}
|
||||
|
||||
// WithDeletionGracePeriodSeconds sets the DeletionGracePeriodSeconds field in the declarative configuration to the given value
|
||||
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||
// If called multiple times, the DeletionGracePeriodSeconds field is set to the value of the last call.
|
||||
func (b *LeaseCandidateApplyConfiguration) WithDeletionGracePeriodSeconds(value int64) *LeaseCandidateApplyConfiguration {
|
||||
b.ensureObjectMetaApplyConfigurationExists()
|
||||
b.ObjectMetaApplyConfiguration.DeletionGracePeriodSeconds = &value
|
||||
return b
|
||||
}
|
||||
|
||||
// WithLabels puts the entries into the Labels field in the declarative configuration
|
||||
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||
// If called multiple times, the entries provided by each call will be put on the Labels field,
|
||||
// overwriting an existing map entries in Labels field with the same key.
|
||||
func (b *LeaseCandidateApplyConfiguration) WithLabels(entries map[string]string) *LeaseCandidateApplyConfiguration {
|
||||
b.ensureObjectMetaApplyConfigurationExists()
|
||||
if b.ObjectMetaApplyConfiguration.Labels == nil && len(entries) > 0 {
|
||||
b.ObjectMetaApplyConfiguration.Labels = make(map[string]string, len(entries))
|
||||
}
|
||||
for k, v := range entries {
|
||||
b.ObjectMetaApplyConfiguration.Labels[k] = v
|
||||
}
|
||||
return b
|
||||
}
|
||||
|
||||
// WithAnnotations puts the entries into the Annotations field in the declarative configuration
|
||||
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||
// If called multiple times, the entries provided by each call will be put on the Annotations field,
|
||||
// overwriting an existing map entries in Annotations field with the same key.
|
||||
func (b *LeaseCandidateApplyConfiguration) WithAnnotations(entries map[string]string) *LeaseCandidateApplyConfiguration {
|
||||
b.ensureObjectMetaApplyConfigurationExists()
|
||||
if b.ObjectMetaApplyConfiguration.Annotations == nil && len(entries) > 0 {
|
||||
b.ObjectMetaApplyConfiguration.Annotations = make(map[string]string, len(entries))
|
||||
}
|
||||
for k, v := range entries {
|
||||
b.ObjectMetaApplyConfiguration.Annotations[k] = v
|
||||
}
|
||||
return b
|
||||
}
|
||||
|
||||
// WithOwnerReferences adds the given value to the OwnerReferences field in the declarative configuration
|
||||
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||
// If called multiple times, values provided by each call will be appended to the OwnerReferences field.
|
||||
func (b *LeaseCandidateApplyConfiguration) WithOwnerReferences(values ...*v1.OwnerReferenceApplyConfiguration) *LeaseCandidateApplyConfiguration {
|
||||
b.ensureObjectMetaApplyConfigurationExists()
|
||||
for i := range values {
|
||||
if values[i] == nil {
|
||||
panic("nil value passed to WithOwnerReferences")
|
||||
}
|
||||
b.ObjectMetaApplyConfiguration.OwnerReferences = append(b.ObjectMetaApplyConfiguration.OwnerReferences, *values[i])
|
||||
}
|
||||
return b
|
||||
}
|
||||
|
||||
// WithFinalizers adds the given value to the Finalizers field in the declarative configuration
|
||||
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
|
||||
// If called multiple times, values provided by each call will be appended to the Finalizers field.
|
||||
func (b *LeaseCandidateApplyConfiguration) WithFinalizers(values ...string) *LeaseCandidateApplyConfiguration {
|
||||
b.ensureObjectMetaApplyConfigurationExists()
|
||||
for i := range values {
|
||||
b.ObjectMetaApplyConfiguration.Finalizers = append(b.ObjectMetaApplyConfiguration.Finalizers, values[i])
|
||||
}
|
||||
return b
|
||||
}
|
||||
|
||||
func (b *LeaseCandidateApplyConfiguration) ensureObjectMetaApplyConfigurationExists() {
|
||||
if b.ObjectMetaApplyConfiguration == nil {
|
||||
b.ObjectMetaApplyConfiguration = &v1.ObjectMetaApplyConfiguration{}
|
||||
}
|
||||
}
|
||||
|
||||
// WithSpec sets the Spec field in the declarative configuration to the given value
|
||||
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||
// If called multiple times, the Spec field is set to the value of the last call.
|
||||
func (b *LeaseCandidateApplyConfiguration) WithSpec(value *LeaseCandidateSpecApplyConfiguration) *LeaseCandidateApplyConfiguration {
|
||||
b.Spec = value
|
||||
return b
|
||||
}
|
||||
|
||||
// GetName retrieves the value of the Name field in the declarative configuration.
|
||||
func (b *LeaseCandidateApplyConfiguration) GetName() *string {
|
||||
b.ensureObjectMetaApplyConfigurationExists()
|
||||
return b.ObjectMetaApplyConfiguration.Name
|
||||
}
|
@ -0,0 +1,89 @@
|
||||
/*
|
||||
Copyright The Kubernetes Authors.
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
*/
|
||||
|
||||
// Code generated by applyconfiguration-gen. DO NOT EDIT.
|
||||
|
||||
package v1beta1
|
||||
|
||||
import (
|
||||
coordinationv1 "k8s.io/api/coordination/v1"
|
||||
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
)
|
||||
|
||||
// LeaseCandidateSpecApplyConfiguration represents a declarative configuration of the LeaseCandidateSpec type for use
|
||||
// with apply.
|
||||
type LeaseCandidateSpecApplyConfiguration struct {
|
||||
LeaseName *string `json:"leaseName,omitempty"`
|
||||
PingTime *v1.MicroTime `json:"pingTime,omitempty"`
|
||||
RenewTime *v1.MicroTime `json:"renewTime,omitempty"`
|
||||
BinaryVersion *string `json:"binaryVersion,omitempty"`
|
||||
EmulationVersion *string `json:"emulationVersion,omitempty"`
|
||||
Strategy *coordinationv1.CoordinatedLeaseStrategy `json:"strategy,omitempty"`
|
||||
}
|
||||
|
||||
// LeaseCandidateSpecApplyConfiguration constructs a declarative configuration of the LeaseCandidateSpec type for use with
|
||||
// apply.
|
||||
func LeaseCandidateSpec() *LeaseCandidateSpecApplyConfiguration {
|
||||
return &LeaseCandidateSpecApplyConfiguration{}
|
||||
}
|
||||
|
||||
// WithLeaseName sets the LeaseName field in the declarative configuration to the given value
|
||||
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||
// If called multiple times, the LeaseName field is set to the value of the last call.
|
||||
func (b *LeaseCandidateSpecApplyConfiguration) WithLeaseName(value string) *LeaseCandidateSpecApplyConfiguration {
|
||||
b.LeaseName = &value
|
||||
return b
|
||||
}
|
||||
|
||||
// WithPingTime sets the PingTime field in the declarative configuration to the given value
|
||||
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||
// If called multiple times, the PingTime field is set to the value of the last call.
|
||||
func (b *LeaseCandidateSpecApplyConfiguration) WithPingTime(value v1.MicroTime) *LeaseCandidateSpecApplyConfiguration {
|
||||
b.PingTime = &value
|
||||
return b
|
||||
}
|
||||
|
||||
// WithRenewTime sets the RenewTime field in the declarative configuration to the given value
|
||||
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||
// If called multiple times, the RenewTime field is set to the value of the last call.
|
||||
func (b *LeaseCandidateSpecApplyConfiguration) WithRenewTime(value v1.MicroTime) *LeaseCandidateSpecApplyConfiguration {
|
||||
b.RenewTime = &value
|
||||
return b
|
||||
}
|
||||
|
||||
// WithBinaryVersion sets the BinaryVersion field in the declarative configuration to the given value
|
||||
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||
// If called multiple times, the BinaryVersion field is set to the value of the last call.
|
||||
func (b *LeaseCandidateSpecApplyConfiguration) WithBinaryVersion(value string) *LeaseCandidateSpecApplyConfiguration {
|
||||
b.BinaryVersion = &value
|
||||
return b
|
||||
}
|
||||
|
||||
// WithEmulationVersion sets the EmulationVersion field in the declarative configuration to the given value
|
||||
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||
// If called multiple times, the EmulationVersion field is set to the value of the last call.
|
||||
func (b *LeaseCandidateSpecApplyConfiguration) WithEmulationVersion(value string) *LeaseCandidateSpecApplyConfiguration {
|
||||
b.EmulationVersion = &value
|
||||
return b
|
||||
}
|
||||
|
||||
// WithStrategy sets the Strategy field in the declarative configuration to the given value
|
||||
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
|
||||
// If called multiple times, the Strategy field is set to the value of the last call.
|
||||
func (b *LeaseCandidateSpecApplyConfiguration) WithStrategy(value coordinationv1.CoordinatedLeaseStrategy) *LeaseCandidateSpecApplyConfiguration {
|
||||
b.Strategy = &value
|
||||
return b
|
||||
}
|
@ -4543,6 +4543,46 @@ var schemaYAML = typed.YAMLObject(`types:
|
||||
type:
|
||||
namedType: io.k8s.api.coordination.v1beta1.LeaseSpec
|
||||
default: {}
|
||||
- name: io.k8s.api.coordination.v1beta1.LeaseCandidate
|
||||
map:
|
||||
fields:
|
||||
- name: apiVersion
|
||||
type:
|
||||
scalar: string
|
||||
- name: kind
|
||||
type:
|
||||
scalar: string
|
||||
- name: metadata
|
||||
type:
|
||||
namedType: io.k8s.apimachinery.pkg.apis.meta.v1.ObjectMeta
|
||||
default: {}
|
||||
- name: spec
|
||||
type:
|
||||
namedType: io.k8s.api.coordination.v1beta1.LeaseCandidateSpec
|
||||
default: {}
|
||||
- name: io.k8s.api.coordination.v1beta1.LeaseCandidateSpec
|
||||
map:
|
||||
fields:
|
||||
- name: binaryVersion
|
||||
type:
|
||||
scalar: string
|
||||
default: ""
|
||||
- name: emulationVersion
|
||||
type:
|
||||
scalar: string
|
||||
- name: leaseName
|
||||
type:
|
||||
scalar: string
|
||||
default: ""
|
||||
- name: pingTime
|
||||
type:
|
||||
namedType: io.k8s.apimachinery.pkg.apis.meta.v1.MicroTime
|
||||
- name: renewTime
|
||||
type:
|
||||
namedType: io.k8s.apimachinery.pkg.apis.meta.v1.MicroTime
|
||||
- name: strategy
|
||||
type:
|
||||
scalar: string
|
||||
- name: io.k8s.api.coordination.v1beta1.LeaseSpec
|
||||
map:
|
||||
fields:
|
||||
|
@ -640,6 +640,10 @@ func ForKind(kind schema.GroupVersionKind) interface{} {
|
||||
// Group=coordination.k8s.io, Version=v1beta1
|
||||
case coordinationv1beta1.SchemeGroupVersion.WithKind("Lease"):
|
||||
return &applyconfigurationscoordinationv1beta1.LeaseApplyConfiguration{}
|
||||
case coordinationv1beta1.SchemeGroupVersion.WithKind("LeaseCandidate"):
|
||||
return &applyconfigurationscoordinationv1beta1.LeaseCandidateApplyConfiguration{}
|
||||
case coordinationv1beta1.SchemeGroupVersion.WithKind("LeaseCandidateSpec"):
|
||||
return &applyconfigurationscoordinationv1beta1.LeaseCandidateSpecApplyConfiguration{}
|
||||
case coordinationv1beta1.SchemeGroupVersion.WithKind("LeaseSpec"):
|
||||
return &applyconfigurationscoordinationv1beta1.LeaseSpecApplyConfiguration{}
|
||||
|
||||
|
@ -26,6 +26,8 @@ import (
|
||||
type Interface interface {
|
||||
// Leases returns a LeaseInformer.
|
||||
Leases() LeaseInformer
|
||||
// LeaseCandidates returns a LeaseCandidateInformer.
|
||||
LeaseCandidates() LeaseCandidateInformer
|
||||
}
|
||||
|
||||
type version struct {
|
||||
@ -43,3 +45,8 @@ func New(f internalinterfaces.SharedInformerFactory, namespace string, tweakList
|
||||
func (v *version) Leases() LeaseInformer {
|
||||
return &leaseInformer{factory: v.factory, namespace: v.namespace, tweakListOptions: v.tweakListOptions}
|
||||
}
|
||||
|
||||
// LeaseCandidates returns a LeaseCandidateInformer.
|
||||
func (v *version) LeaseCandidates() LeaseCandidateInformer {
|
||||
return &leaseCandidateInformer{factory: v.factory, namespace: v.namespace, tweakListOptions: v.tweakListOptions}
|
||||
}
|
||||
|
@ -0,0 +1,102 @@
|
||||
/*
|
||||
Copyright The Kubernetes Authors.
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
*/
|
||||
|
||||
// Code generated by informer-gen. DO NOT EDIT.
|
||||
|
||||
package v1beta1
|
||||
|
||||
import (
|
||||
context "context"
|
||||
time "time"
|
||||
|
||||
apicoordinationv1beta1 "k8s.io/api/coordination/v1beta1"
|
||||
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
runtime "k8s.io/apimachinery/pkg/runtime"
|
||||
watch "k8s.io/apimachinery/pkg/watch"
|
||||
internalinterfaces "k8s.io/client-go/informers/internalinterfaces"
|
||||
kubernetes "k8s.io/client-go/kubernetes"
|
||||
coordinationv1beta1 "k8s.io/client-go/listers/coordination/v1beta1"
|
||||
cache "k8s.io/client-go/tools/cache"
|
||||
)
|
||||
|
||||
// LeaseCandidateInformer provides access to a shared informer and lister for
|
||||
// LeaseCandidates.
|
||||
type LeaseCandidateInformer interface {
|
||||
Informer() cache.SharedIndexInformer
|
||||
Lister() coordinationv1beta1.LeaseCandidateLister
|
||||
}
|
||||
|
||||
type leaseCandidateInformer struct {
|
||||
factory internalinterfaces.SharedInformerFactory
|
||||
tweakListOptions internalinterfaces.TweakListOptionsFunc
|
||||
namespace string
|
||||
}
|
||||
|
||||
// NewLeaseCandidateInformer constructs a new informer for LeaseCandidate type.
|
||||
// Always prefer using an informer factory to get a shared informer instead of getting an independent
|
||||
// one. This reduces memory footprint and number of connections to the server.
|
||||
func NewLeaseCandidateInformer(client kubernetes.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers) cache.SharedIndexInformer {
|
||||
return NewFilteredLeaseCandidateInformer(client, namespace, resyncPeriod, indexers, nil)
|
||||
}
|
||||
|
||||
// NewFilteredLeaseCandidateInformer constructs a new informer for LeaseCandidate type.
|
||||
// Always prefer using an informer factory to get a shared informer instead of getting an independent
|
||||
// one. This reduces memory footprint and number of connections to the server.
|
||||
func NewFilteredLeaseCandidateInformer(client kubernetes.Interface, namespace string, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) cache.SharedIndexInformer {
|
||||
return cache.NewSharedIndexInformer(
|
||||
&cache.ListWatch{
|
||||
ListFunc: func(options v1.ListOptions) (runtime.Object, error) {
|
||||
if tweakListOptions != nil {
|
||||
tweakListOptions(&options)
|
||||
}
|
||||
return client.CoordinationV1beta1().LeaseCandidates(namespace).List(context.Background(), options)
|
||||
},
|
||||
WatchFunc: func(options v1.ListOptions) (watch.Interface, error) {
|
||||
if tweakListOptions != nil {
|
||||
tweakListOptions(&options)
|
||||
}
|
||||
return client.CoordinationV1beta1().LeaseCandidates(namespace).Watch(context.Background(), options)
|
||||
},
|
||||
ListWithContextFunc: func(ctx context.Context, options v1.ListOptions) (runtime.Object, error) {
|
||||
if tweakListOptions != nil {
|
||||
tweakListOptions(&options)
|
||||
}
|
||||
return client.CoordinationV1beta1().LeaseCandidates(namespace).List(ctx, options)
|
||||
},
|
||||
WatchFuncWithContext: func(ctx context.Context, options v1.ListOptions) (watch.Interface, error) {
|
||||
if tweakListOptions != nil {
|
||||
tweakListOptions(&options)
|
||||
}
|
||||
return client.CoordinationV1beta1().LeaseCandidates(namespace).Watch(ctx, options)
|
||||
},
|
||||
},
|
||||
&apicoordinationv1beta1.LeaseCandidate{},
|
||||
resyncPeriod,
|
||||
indexers,
|
||||
)
|
||||
}
|
||||
|
||||
func (f *leaseCandidateInformer) defaultInformer(client kubernetes.Interface, resyncPeriod time.Duration) cache.SharedIndexInformer {
|
||||
return NewFilteredLeaseCandidateInformer(client, f.namespace, resyncPeriod, cache.Indexers{cache.NamespaceIndex: cache.MetaNamespaceIndexFunc}, f.tweakListOptions)
|
||||
}
|
||||
|
||||
func (f *leaseCandidateInformer) Informer() cache.SharedIndexInformer {
|
||||
return f.factory.InformerFor(&apicoordinationv1beta1.LeaseCandidate{}, f.defaultInformer)
|
||||
}
|
||||
|
||||
func (f *leaseCandidateInformer) Lister() coordinationv1beta1.LeaseCandidateLister {
|
||||
return coordinationv1beta1.NewLeaseCandidateLister(f.Informer().GetIndexer())
|
||||
}
|
@ -211,6 +211,8 @@ func (f *sharedInformerFactory) ForResource(resource schema.GroupVersionResource
|
||||
// Group=coordination.k8s.io, Version=v1beta1
|
||||
case coordinationv1beta1.SchemeGroupVersion.WithResource("leases"):
|
||||
return &genericInformer{resource: resource.GroupResource(), informer: f.Coordination().V1beta1().Leases().Informer()}, nil
|
||||
case coordinationv1beta1.SchemeGroupVersion.WithResource("leasecandidates"):
|
||||
return &genericInformer{resource: resource.GroupResource(), informer: f.Coordination().V1beta1().LeaseCandidates().Informer()}, nil
|
||||
|
||||
// Group=core, Version=v1
|
||||
case corev1.SchemeGroupVersion.WithResource("componentstatuses"):
|
||||
|
@ -29,6 +29,7 @@ import (
|
||||
type CoordinationV1beta1Interface interface {
|
||||
RESTClient() rest.Interface
|
||||
LeasesGetter
|
||||
LeaseCandidatesGetter
|
||||
}
|
||||
|
||||
// CoordinationV1beta1Client is used to interact with features provided by the coordination.k8s.io group.
|
||||
@ -40,6 +41,10 @@ func (c *CoordinationV1beta1Client) Leases(namespace string) LeaseInterface {
|
||||
return newLeases(c, namespace)
|
||||
}
|
||||
|
||||
func (c *CoordinationV1beta1Client) LeaseCandidates(namespace string) LeaseCandidateInterface {
|
||||
return newLeaseCandidates(c, namespace)
|
||||
}
|
||||
|
||||
// NewForConfig creates a new CoordinationV1beta1Client for the given config.
|
||||
// NewForConfig is equivalent to NewForConfigAndClient(c, httpClient),
|
||||
// where httpClient was generated with rest.HTTPClientFor(c).
|
||||
|
@ -32,6 +32,10 @@ func (c *FakeCoordinationV1beta1) Leases(namespace string) v1beta1.LeaseInterfac
|
||||
return newFakeLeases(c, namespace)
|
||||
}
|
||||
|
||||
func (c *FakeCoordinationV1beta1) LeaseCandidates(namespace string) v1beta1.LeaseCandidateInterface {
|
||||
return newFakeLeaseCandidates(c, namespace)
|
||||
}
|
||||
|
||||
// RESTClient returns a RESTClient that is used to communicate
|
||||
// with API server by this client implementation.
|
||||
func (c *FakeCoordinationV1beta1) RESTClient() rest.Interface {
|
||||
|
@ -0,0 +1,53 @@
|
||||
/*
|
||||
Copyright The Kubernetes Authors.
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
*/
|
||||
|
||||
// Code generated by client-gen. DO NOT EDIT.
|
||||
|
||||
package fake
|
||||
|
||||
import (
|
||||
v1beta1 "k8s.io/api/coordination/v1beta1"
|
||||
coordinationv1beta1 "k8s.io/client-go/applyconfigurations/coordination/v1beta1"
|
||||
gentype "k8s.io/client-go/gentype"
|
||||
typedcoordinationv1beta1 "k8s.io/client-go/kubernetes/typed/coordination/v1beta1"
|
||||
)
|
||||
|
||||
// fakeLeaseCandidates implements LeaseCandidateInterface
|
||||
type fakeLeaseCandidates struct {
|
||||
*gentype.FakeClientWithListAndApply[*v1beta1.LeaseCandidate, *v1beta1.LeaseCandidateList, *coordinationv1beta1.LeaseCandidateApplyConfiguration]
|
||||
Fake *FakeCoordinationV1beta1
|
||||
}
|
||||
|
||||
func newFakeLeaseCandidates(fake *FakeCoordinationV1beta1, namespace string) typedcoordinationv1beta1.LeaseCandidateInterface {
|
||||
return &fakeLeaseCandidates{
|
||||
gentype.NewFakeClientWithListAndApply[*v1beta1.LeaseCandidate, *v1beta1.LeaseCandidateList, *coordinationv1beta1.LeaseCandidateApplyConfiguration](
|
||||
fake.Fake,
|
||||
namespace,
|
||||
v1beta1.SchemeGroupVersion.WithResource("leasecandidates"),
|
||||
v1beta1.SchemeGroupVersion.WithKind("LeaseCandidate"),
|
||||
func() *v1beta1.LeaseCandidate { return &v1beta1.LeaseCandidate{} },
|
||||
func() *v1beta1.LeaseCandidateList { return &v1beta1.LeaseCandidateList{} },
|
||||
func(dst, src *v1beta1.LeaseCandidateList) { dst.ListMeta = src.ListMeta },
|
||||
func(list *v1beta1.LeaseCandidateList) []*v1beta1.LeaseCandidate {
|
||||
return gentype.ToPointerSlice(list.Items)
|
||||
},
|
||||
func(list *v1beta1.LeaseCandidateList, items []*v1beta1.LeaseCandidate) {
|
||||
list.Items = gentype.FromPointerSlice(items)
|
||||
},
|
||||
),
|
||||
fake,
|
||||
}
|
||||
}
|
@ -19,3 +19,5 @@ limitations under the License.
|
||||
package v1beta1
|
||||
|
||||
type LeaseExpansion interface{}
|
||||
|
||||
type LeaseCandidateExpansion interface{}
|
||||
|
@ -0,0 +1,71 @@
|
||||
/*
|
||||
Copyright The Kubernetes Authors.
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
*/
|
||||
|
||||
// Code generated by client-gen. DO NOT EDIT.
|
||||
|
||||
package v1beta1
|
||||
|
||||
import (
|
||||
context "context"
|
||||
|
||||
coordinationv1beta1 "k8s.io/api/coordination/v1beta1"
|
||||
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
types "k8s.io/apimachinery/pkg/types"
|
||||
watch "k8s.io/apimachinery/pkg/watch"
|
||||
applyconfigurationscoordinationv1beta1 "k8s.io/client-go/applyconfigurations/coordination/v1beta1"
|
||||
gentype "k8s.io/client-go/gentype"
|
||||
scheme "k8s.io/client-go/kubernetes/scheme"
|
||||
)
|
||||
|
||||
// LeaseCandidatesGetter has a method to return a LeaseCandidateInterface.
|
||||
// A group's client should implement this interface.
|
||||
type LeaseCandidatesGetter interface {
|
||||
LeaseCandidates(namespace string) LeaseCandidateInterface
|
||||
}
|
||||
|
||||
// LeaseCandidateInterface has methods to work with LeaseCandidate resources.
|
||||
type LeaseCandidateInterface interface {
|
||||
Create(ctx context.Context, leaseCandidate *coordinationv1beta1.LeaseCandidate, opts v1.CreateOptions) (*coordinationv1beta1.LeaseCandidate, error)
|
||||
Update(ctx context.Context, leaseCandidate *coordinationv1beta1.LeaseCandidate, opts v1.UpdateOptions) (*coordinationv1beta1.LeaseCandidate, error)
|
||||
Delete(ctx context.Context, name string, opts v1.DeleteOptions) error
|
||||
DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error
|
||||
Get(ctx context.Context, name string, opts v1.GetOptions) (*coordinationv1beta1.LeaseCandidate, error)
|
||||
List(ctx context.Context, opts v1.ListOptions) (*coordinationv1beta1.LeaseCandidateList, error)
|
||||
Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error)
|
||||
Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *coordinationv1beta1.LeaseCandidate, err error)
|
||||
Apply(ctx context.Context, leaseCandidate *applyconfigurationscoordinationv1beta1.LeaseCandidateApplyConfiguration, opts v1.ApplyOptions) (result *coordinationv1beta1.LeaseCandidate, err error)
|
||||
LeaseCandidateExpansion
|
||||
}
|
||||
|
||||
// leaseCandidates implements LeaseCandidateInterface
|
||||
type leaseCandidates struct {
|
||||
*gentype.ClientWithListAndApply[*coordinationv1beta1.LeaseCandidate, *coordinationv1beta1.LeaseCandidateList, *applyconfigurationscoordinationv1beta1.LeaseCandidateApplyConfiguration]
|
||||
}
|
||||
|
||||
// newLeaseCandidates returns a LeaseCandidates
|
||||
func newLeaseCandidates(c *CoordinationV1beta1Client, namespace string) *leaseCandidates {
|
||||
return &leaseCandidates{
|
||||
gentype.NewClientWithListAndApply[*coordinationv1beta1.LeaseCandidate, *coordinationv1beta1.LeaseCandidateList, *applyconfigurationscoordinationv1beta1.LeaseCandidateApplyConfiguration](
|
||||
"leasecandidates",
|
||||
c.RESTClient(),
|
||||
scheme.ParameterCodec,
|
||||
namespace,
|
||||
func() *coordinationv1beta1.LeaseCandidate { return &coordinationv1beta1.LeaseCandidate{} },
|
||||
func() *coordinationv1beta1.LeaseCandidateList { return &coordinationv1beta1.LeaseCandidateList{} },
|
||||
gentype.PrefersProtobuf[*coordinationv1beta1.LeaseCandidate](),
|
||||
),
|
||||
}
|
||||
}
|
@ -25,3 +25,11 @@ type LeaseListerExpansion interface{}
|
||||
// LeaseNamespaceListerExpansion allows custom methods to be added to
|
||||
// LeaseNamespaceLister.
|
||||
type LeaseNamespaceListerExpansion interface{}
|
||||
|
||||
// LeaseCandidateListerExpansion allows custom methods to be added to
|
||||
// LeaseCandidateLister.
|
||||
type LeaseCandidateListerExpansion interface{}
|
||||
|
||||
// LeaseCandidateNamespaceListerExpansion allows custom methods to be added to
|
||||
// LeaseCandidateNamespaceLister.
|
||||
type LeaseCandidateNamespaceListerExpansion interface{}
|
||||
|
@ -0,0 +1,70 @@
|
||||
/*
|
||||
Copyright The Kubernetes Authors.
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
*/
|
||||
|
||||
// Code generated by lister-gen. DO NOT EDIT.
|
||||
|
||||
package v1beta1
|
||||
|
||||
import (
|
||||
coordinationv1beta1 "k8s.io/api/coordination/v1beta1"
|
||||
labels "k8s.io/apimachinery/pkg/labels"
|
||||
listers "k8s.io/client-go/listers"
|
||||
cache "k8s.io/client-go/tools/cache"
|
||||
)
|
||||
|
||||
// LeaseCandidateLister helps list LeaseCandidates.
|
||||
// All objects returned here must be treated as read-only.
|
||||
type LeaseCandidateLister interface {
|
||||
// List lists all LeaseCandidates in the indexer.
|
||||
// Objects returned here must be treated as read-only.
|
||||
List(selector labels.Selector) (ret []*coordinationv1beta1.LeaseCandidate, err error)
|
||||
// LeaseCandidates returns an object that can list and get LeaseCandidates.
|
||||
LeaseCandidates(namespace string) LeaseCandidateNamespaceLister
|
||||
LeaseCandidateListerExpansion
|
||||
}
|
||||
|
||||
// leaseCandidateLister implements the LeaseCandidateLister interface.
|
||||
type leaseCandidateLister struct {
|
||||
listers.ResourceIndexer[*coordinationv1beta1.LeaseCandidate]
|
||||
}
|
||||
|
||||
// NewLeaseCandidateLister returns a new LeaseCandidateLister.
|
||||
func NewLeaseCandidateLister(indexer cache.Indexer) LeaseCandidateLister {
|
||||
return &leaseCandidateLister{listers.New[*coordinationv1beta1.LeaseCandidate](indexer, coordinationv1beta1.Resource("leasecandidate"))}
|
||||
}
|
||||
|
||||
// LeaseCandidates returns an object that can list and get LeaseCandidates.
|
||||
func (s *leaseCandidateLister) LeaseCandidates(namespace string) LeaseCandidateNamespaceLister {
|
||||
return leaseCandidateNamespaceLister{listers.NewNamespaced[*coordinationv1beta1.LeaseCandidate](s.ResourceIndexer, namespace)}
|
||||
}
|
||||
|
||||
// LeaseCandidateNamespaceLister helps list and get LeaseCandidates.
|
||||
// All objects returned here must be treated as read-only.
|
||||
type LeaseCandidateNamespaceLister interface {
|
||||
// List lists all LeaseCandidates in the indexer for a given namespace.
|
||||
// Objects returned here must be treated as read-only.
|
||||
List(selector labels.Selector) (ret []*coordinationv1beta1.LeaseCandidate, err error)
|
||||
// Get retrieves the LeaseCandidate from the indexer for a given namespace and name.
|
||||
// Objects returned here must be treated as read-only.
|
||||
Get(name string) (*coordinationv1beta1.LeaseCandidate, error)
|
||||
LeaseCandidateNamespaceListerExpansion
|
||||
}
|
||||
|
||||
// leaseCandidateNamespaceLister implements the LeaseCandidateNamespaceLister
|
||||
// interface.
|
||||
type leaseCandidateNamespaceLister struct {
|
||||
listers.ResourceIndexer[*coordinationv1beta1.LeaseCandidate]
|
||||
}
|
Loading…
Reference in New Issue
Block a user