mirror of
https://github.com/ceph/ceph-csi.git
synced 2025-06-13 10:33:35 +00:00
rebase: update kubernetes to latest
updating the kubernetes release to the latest in main go.mod Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
This commit is contained in:
committed by
mergify[bot]
parent
63c4c05b35
commit
5a66991bb3
1
vendor/k8s.io/api/coordination/v1/doc.go
generated
vendored
1
vendor/k8s.io/api/coordination/v1/doc.go
generated
vendored
@ -17,6 +17,7 @@ limitations under the License.
|
||||
// +k8s:deepcopy-gen=package
|
||||
// +k8s:protobuf-gen=package
|
||||
// +k8s:openapi-gen=true
|
||||
// +k8s:prerelease-lifecycle-gen=true
|
||||
|
||||
// +groupName=coordination.k8s.io
|
||||
|
||||
|
162
vendor/k8s.io/api/coordination/v1/generated.pb.go
generated
vendored
162
vendor/k8s.io/api/coordination/v1/generated.pb.go
generated
vendored
@ -139,40 +139,44 @@ func init() {
|
||||
}
|
||||
|
||||
var fileDescriptor_239d5a4df3139dce = []byte{
|
||||
// 524 bytes of a gzipped FileDescriptorProto
|
||||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x94, 0x4f, 0x6f, 0xd3, 0x30,
|
||||
0x18, 0xc6, 0x9b, 0xb5, 0x95, 0x56, 0x97, 0x8d, 0x2a, 0xea, 0x21, 0xea, 0x21, 0x19, 0x95, 0x90,
|
||||
0x26, 0x24, 0x1c, 0x3a, 0x21, 0x84, 0x38, 0x8d, 0x08, 0x01, 0x93, 0x3a, 0x21, 0x65, 0x3b, 0xa1,
|
||||
0x1d, 0x70, 0x93, 0x97, 0xd4, 0x74, 0x89, 0x83, 0xed, 0x16, 0xed, 0xc6, 0x47, 0xe0, 0xca, 0xc7,
|
||||
0x80, 0x4f, 0xd1, 0xe3, 0x8e, 0x3b, 0x45, 0xd4, 0x7c, 0x11, 0x64, 0xb7, 0x5b, 0x4b, 0xff, 0x68,
|
||||
0xd3, 0x6e, 0xf1, 0xeb, 0xe7, 0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||
0x32, 0xf8, 0x66, 0x36, 0x54, 0xee, 0xb7, 0x61, 0x47, 0x15, 0x5e, 0x2d, 0xbc, 0xa6, 0x84, 0x73,
|
||||
0xa0, 0x7d, 0x88, 0x1a, 0xe6, 0x65, 0xa7, 0x9c, 0x64, 0x82, 0xea, 0xb7, 0x09, 0xa7, 0x6a, 0xba,
|
||||
0x68, 0xaa, 0xc2, 0x6b, 0x74, 0x97, 0xee, 0xc2, 0x15, 0x75, 0x70, 0x38, 0x9e, 0xb8, 0xa5, 0xcb,
|
||||
0x89, 0x5b, 0xba, 0x9a, 0xb8, 0xa5, 0xef, 0xca, 0xb5, 0xc6, 0xca, 0xb5, 0x2e, 0x95, 0x6b, 0x5d,
|
||||
0x29, 0xd7, 0xfa, 0xa3, 0x5c, 0xeb, 0xc7, 0x5f, 0xb7, 0xf4, 0xb1, 0xb5, 0xf9, 0x07, 0xf2, 0x2f,
|
||||
0x00, 0x00, 0xff, 0xff, 0xb0, 0xb0, 0x3a, 0x46, 0x5d, 0x04, 0x00, 0x00,
|
||||
// 588 bytes of a gzipped FileDescriptorProto
|
||||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x94, 0xdf, 0x4e, 0xd4, 0x40,
|
||||
0x14, 0xc6, 0xb7, 0xb0, 0xab, 0xec, 0xac, 0xfc, 0xc9, 0xc8, 0x45, 0xb3, 0x17, 0x2d, 0x92, 0x98,
|
||||
0x10, 0x13, 0xa7, 0x42, 0x8c, 0x31, 0x26, 0x26, 0x58, 0x89, 0x4a, 0xb2, 0x44, 0x53, 0xb8, 0x32,
|
||||
0x5c, 0x38, 0xdb, 0x1e, 0xba, 0x23, 0xb4, 0x53, 0x67, 0x66, 0x31, 0xdc, 0xf9, 0x08, 0x3e, 0x81,
|
||||
0xef, 0xa0, 0x4f, 0xc1, 0x25, 0x97, 0x5c, 0x35, 0x32, 0xbe, 0x85, 0x57, 0x66, 0x66, 0x0b, 0x0b,
|
||||
0xcb, 0x6e, 0x20, 0xde, 0x75, 0xce, 0x39, 0xdf, 0xef, 0x7c, 0x73, 0x4e, 0x5b, 0xf4, 0x68, 0xff,
|
||||
0xb9, 0x24, 0x8c, 0x07, 0xb4, 0x60, 0x41, 0xcc, 0xb9, 0x48, 0x58, 0x4e, 0x15, 0xe3, 0x79, 0x70,
|
||||
0xb8, 0x1a, 0xa4, 0x90, 0x83, 0xa0, 0x0a, 0x12, 0x52, 0x08, 0xae, 0x38, 0x6e, 0x0f, 0x6a, 0x09,
|
||||
0x2d, 0x18, 0xb9, 0x5c, 0x4b, 0x0e, 0x57, 0xdb, 0x8f, 0x53, 0xa6, 0x7a, 0xfd, 0x2e, 0x89, 0x79,
|
||||
0x16, 0xa4, 0x3c, 0xe5, 0x81, 0x95, 0x74, 0xfb, 0x7b, 0xf6, 0x64, 0x0f, 0xf6, 0x69, 0x80, 0x6a,
|
||||
0x3f, 0x1d, 0xb6, 0xcd, 0x68, 0xdc, 0x63, 0x39, 0x88, 0xa3, 0xa0, 0xd8, 0x4f, 0x4d, 0x40, 0x06,
|
||||
0x19, 0x28, 0x3a, 0xc6, 0x40, 0x3b, 0x98, 0xa4, 0x12, 0xfd, 0x5c, 0xb1, 0x0c, 0xae, 0x09, 0x9e,
|
||||
0xdd, 0x24, 0x90, 0x71, 0x0f, 0x32, 0x3a, 0xaa, 0x5b, 0xfe, 0xe5, 0xa0, 0x46, 0x07, 0xa8, 0x04,
|
||||
0xfc, 0x09, 0xcd, 0x18, 0x37, 0x09, 0x55, 0xd4, 0x75, 0x96, 0x9c, 0x95, 0xd6, 0xda, 0x13, 0x32,
|
||||
0x1c, 0xc3, 0x05, 0x94, 0x14, 0xfb, 0xa9, 0x09, 0x48, 0x62, 0xaa, 0xc9, 0xe1, 0x2a, 0x79, 0xdf,
|
||||
0xfd, 0x0c, 0xb1, 0xda, 0x02, 0x45, 0x43, 0x7c, 0x5c, 0xfa, 0x35, 0x5d, 0xfa, 0x68, 0x18, 0x8b,
|
||||
0x2e, 0xa8, 0xf8, 0x2d, 0xaa, 0xcb, 0x02, 0x62, 0x77, 0xca, 0xd2, 0x1f, 0x92, 0xc9, 0x43, 0x26,
|
||||
0xd6, 0xd2, 0x76, 0x01, 0x71, 0x78, 0xaf, 0x42, 0xd6, 0xcd, 0x29, 0xb2, 0x80, 0xe5, 0x9f, 0x0e,
|
||||
0x6a, 0xda, 0x8a, 0x0e, 0x93, 0x0a, 0xef, 0x5e, 0x33, 0x4e, 0x6e, 0x67, 0xdc, 0xa8, 0xad, 0xed,
|
||||
0x85, 0xaa, 0xc7, 0xcc, 0x79, 0xe4, 0x92, 0xe9, 0x37, 0xa8, 0xc1, 0x14, 0x64, 0xd2, 0x9d, 0x5a,
|
||||
0x9a, 0x5e, 0x69, 0xad, 0x3d, 0xb8, 0xd1, 0x75, 0x38, 0x5b, 0xd1, 0x1a, 0x9b, 0x46, 0x17, 0x0d,
|
||||
0xe4, 0xcb, 0x3f, 0xea, 0x95, 0x67, 0x73, 0x0f, 0xfc, 0x02, 0xcd, 0xf5, 0xf8, 0x41, 0x02, 0x62,
|
||||
0x33, 0x81, 0x5c, 0x31, 0x75, 0x64, 0x9d, 0x37, 0x43, 0xac, 0x4b, 0x7f, 0xee, 0xdd, 0x95, 0x4c,
|
||||
0x34, 0x52, 0x89, 0x3b, 0x68, 0xf1, 0xc0, 0x80, 0x36, 0xfa, 0xc2, 0x76, 0xde, 0x86, 0x98, 0xe7,
|
||||
0x89, 0xb4, 0x63, 0x6d, 0x84, 0xae, 0x2e, 0xfd, 0xc5, 0xce, 0x98, 0x7c, 0x34, 0x56, 0x85, 0xbb,
|
||||
0xa8, 0x45, 0xe3, 0x2f, 0x7d, 0x26, 0x60, 0x87, 0x65, 0xe0, 0x4e, 0xdb, 0x01, 0x06, 0xb7, 0x1b,
|
||||
0xe0, 0x16, 0x8b, 0x05, 0x37, 0xb2, 0x70, 0x5e, 0x97, 0x7e, 0xeb, 0xd5, 0x90, 0x13, 0x5d, 0x86,
|
||||
0xe2, 0x5d, 0xd4, 0x14, 0x90, 0xc3, 0x57, 0xdb, 0xa1, 0xfe, 0x7f, 0x1d, 0x66, 0x75, 0xe9, 0x37,
|
||||
0xa3, 0x73, 0x4a, 0x34, 0x04, 0xe2, 0x75, 0xb4, 0x60, 0x6f, 0xb6, 0x23, 0x68, 0x2e, 0x99, 0xb9,
|
||||
0x9b, 0x74, 0x1b, 0x76, 0x16, 0x8b, 0xba, 0xf4, 0x17, 0x3a, 0x23, 0xb9, 0xe8, 0x5a, 0x35, 0xde,
|
||||
0x40, 0x33, 0x52, 0x99, 0xaf, 0x22, 0x3d, 0x72, 0xef, 0xd8, 0x3d, 0xac, 0x98, 0xb7, 0x61, 0xbb,
|
||||
0x8a, 0xfd, 0x2d, 0x7d, 0xf7, 0xf5, 0xf9, 0xaa, 0x21, 0x19, 0x6c, 0xb1, 0xca, 0x45, 0x17, 0x4a,
|
||||
0xfc, 0x12, 0xcd, 0x17, 0x02, 0xf6, 0x40, 0x08, 0x48, 0x06, 0x2b, 0x74, 0xef, 0x5a, 0xd8, 0x7d,
|
||||
0x5d, 0xfa, 0xf3, 0x1f, 0xae, 0xa6, 0xa2, 0xd1, 0xda, 0x70, 0xfd, 0xf8, 0xcc, 0xab, 0x9d, 0x9c,
|
||||
0x79, 0xb5, 0xd3, 0x33, 0xaf, 0xf6, 0x4d, 0x7b, 0xce, 0xb1, 0xf6, 0x9c, 0x13, 0xed, 0x39, 0xa7,
|
||||
0xda, 0x73, 0x7e, 0x6b, 0xcf, 0xf9, 0xfe, 0xc7, 0xab, 0x7d, 0x6c, 0x4f, 0xfe, 0x8b, 0xfd, 0x0b,
|
||||
0x00, 0x00, 0xff, 0xff, 0xf8, 0xf4, 0xd4, 0x78, 0xe2, 0x04, 0x00, 0x00,
|
||||
}
|
||||
|
||||
func (m *Lease) Marshal() (dAtA []byte, err error) {
|
||||
@ -285,6 +289,20 @@ func (m *LeaseSpec) MarshalToSizedBuffer(dAtA []byte) (int, error) {
|
||||
_ = i
|
||||
var l int
|
||||
_ = l
|
||||
if m.PreferredHolder != nil {
|
||||
i -= len(*m.PreferredHolder)
|
||||
copy(dAtA[i:], *m.PreferredHolder)
|
||||
i = encodeVarintGenerated(dAtA, i, uint64(len(*m.PreferredHolder)))
|
||||
i--
|
||||
dAtA[i] = 0x3a
|
||||
}
|
||||
if m.Strategy != nil {
|
||||
i -= len(*m.Strategy)
|
||||
copy(dAtA[i:], *m.Strategy)
|
||||
i = encodeVarintGenerated(dAtA, i, uint64(len(*m.Strategy)))
|
||||
i--
|
||||
dAtA[i] = 0x32
|
||||
}
|
||||
if m.LeaseTransitions != nil {
|
||||
i = encodeVarintGenerated(dAtA, i, uint64(*m.LeaseTransitions))
|
||||
i--
|
||||
@ -394,6 +412,14 @@ func (m *LeaseSpec) Size() (n int) {
|
||||
if m.LeaseTransitions != nil {
|
||||
n += 1 + sovGenerated(uint64(*m.LeaseTransitions))
|
||||
}
|
||||
if m.Strategy != nil {
|
||||
l = len(*m.Strategy)
|
||||
n += 1 + l + sovGenerated(uint64(l))
|
||||
}
|
||||
if m.PreferredHolder != nil {
|
||||
l = len(*m.PreferredHolder)
|
||||
n += 1 + l + sovGenerated(uint64(l))
|
||||
}
|
||||
return n
|
||||
}
|
||||
|
||||
@ -440,6 +466,8 @@ func (this *LeaseSpec) String() string {
|
||||
`AcquireTime:` + strings.Replace(fmt.Sprintf("%v", this.AcquireTime), "MicroTime", "v1.MicroTime", 1) + `,`,
|
||||
`RenewTime:` + strings.Replace(fmt.Sprintf("%v", this.RenewTime), "MicroTime", "v1.MicroTime", 1) + `,`,
|
||||
`LeaseTransitions:` + valueToStringGenerated(this.LeaseTransitions) + `,`,
|
||||
`Strategy:` + valueToStringGenerated(this.Strategy) + `,`,
|
||||
`PreferredHolder:` + valueToStringGenerated(this.PreferredHolder) + `,`,
|
||||
`}`,
|
||||
}, "")
|
||||
return s
|
||||
@ -859,6 +887,72 @@ func (m *LeaseSpec) Unmarshal(dAtA []byte) error {
|
||||
}
|
||||
}
|
||||
m.LeaseTransitions = &v
|
||||
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
|
||||
}
|
||||
s := CoordinatedLeaseStrategy(dAtA[iNdEx:postIndex])
|
||||
m.Strategy = &s
|
||||
iNdEx = postIndex
|
||||
case 7:
|
||||
if wireType != 2 {
|
||||
return fmt.Errorf("proto: wrong wireType = %d for field PreferredHolder", 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
|
||||
}
|
||||
s := string(dAtA[iNdEx:postIndex])
|
||||
m.PreferredHolder = &s
|
||||
iNdEx = postIndex
|
||||
default:
|
||||
iNdEx = preIndex
|
||||
skippy, err := skipGenerated(dAtA[iNdEx:])
|
||||
|
26
vendor/k8s.io/api/coordination/v1/generated.proto
generated
vendored
26
vendor/k8s.io/api/coordination/v1/generated.proto
generated
vendored
@ -32,7 +32,7 @@ option go_package = "k8s.io/api/coordination/v1";
|
||||
message Lease {
|
||||
// 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;
|
||||
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
|
||||
@ -45,7 +45,7 @@ message LeaseList {
|
||||
// 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;
|
||||
optional .k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1;
|
||||
|
||||
// items is a list of schema objects.
|
||||
repeated Lease items = 2;
|
||||
@ -54,27 +54,43 @@ message LeaseList {
|
||||
// LeaseSpec is a specification of a Lease.
|
||||
message LeaseSpec {
|
||||
// holderIdentity contains the identity of the holder of a current lease.
|
||||
// If Coordinated Leader Election is used, the holder identity must be
|
||||
// equal to the elected LeaseCandidate.metadata.name field.
|
||||
// +optional
|
||||
optional string holderIdentity = 1;
|
||||
|
||||
// leaseDurationSeconds is a duration that candidates for a lease need
|
||||
// to wait to force acquire it. This is measure against time of last
|
||||
// to wait to force acquire it. This is measured against the time of last
|
||||
// observed renewTime.
|
||||
// +optional
|
||||
optional int32 leaseDurationSeconds = 2;
|
||||
|
||||
// acquireTime is a time when the current lease was acquired.
|
||||
// +optional
|
||||
optional k8s.io.apimachinery.pkg.apis.meta.v1.MicroTime acquireTime = 3;
|
||||
optional .k8s.io.apimachinery.pkg.apis.meta.v1.MicroTime acquireTime = 3;
|
||||
|
||||
// renewTime is a time when the current holder of a lease has last
|
||||
// updated the lease.
|
||||
// +optional
|
||||
optional k8s.io.apimachinery.pkg.apis.meta.v1.MicroTime renewTime = 4;
|
||||
optional .k8s.io.apimachinery.pkg.apis.meta.v1.MicroTime renewTime = 4;
|
||||
|
||||
// leaseTransitions is the number of transitions of a lease between
|
||||
// holders.
|
||||
// +optional
|
||||
optional int32 leaseTransitions = 5;
|
||||
|
||||
// Strategy indicates the strategy for picking the leader for coordinated leader election.
|
||||
// If the field is not specified, there is no active coordination for this lease.
|
||||
// (Alpha) Using this field requires the CoordinatedLeaderElection feature gate to be enabled.
|
||||
// +featureGate=CoordinatedLeaderElection
|
||||
// +optional
|
||||
optional string strategy = 6;
|
||||
|
||||
// PreferredHolder signals to a lease holder that the lease has a
|
||||
// more optimal holder and should be given up.
|
||||
// This field can only be set if Strategy is also set.
|
||||
// +featureGate=CoordinatedLeaderElection
|
||||
// +optional
|
||||
optional string preferredHolder = 7;
|
||||
}
|
||||
|
||||
|
30
vendor/k8s.io/api/coordination/v1/types.go
generated
vendored
30
vendor/k8s.io/api/coordination/v1/types.go
generated
vendored
@ -20,8 +20,21 @@ import (
|
||||
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
)
|
||||
|
||||
type CoordinatedLeaseStrategy string
|
||||
|
||||
// CoordinatedLeaseStrategy defines the strategy for picking the leader for coordinated leader election.
|
||||
const (
|
||||
// OldestEmulationVersion picks the oldest LeaseCandidate, where "oldest" is defined as follows
|
||||
// 1) Select the candidate(s) with the lowest emulation version
|
||||
// 2) If multiple candidates have the same emulation version, select the candidate(s) with the lowest binary version. (Note that binary version must be greater or equal to emulation version)
|
||||
// 3) If multiple candidates have the same binary version, select the candidate with the oldest creationTimestamp.
|
||||
// If a candidate does not specify the emulationVersion and binaryVersion fields, it will not be considered a candidate for the lease.
|
||||
OldestEmulationVersion CoordinatedLeaseStrategy = "OldestEmulationVersion"
|
||||
)
|
||||
|
||||
// +genclient
|
||||
// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
|
||||
// +k8s:prerelease-lifecycle-gen:introduced=1.14
|
||||
|
||||
// Lease defines a lease concept.
|
||||
type Lease struct {
|
||||
@ -39,10 +52,12 @@ type Lease struct {
|
||||
// LeaseSpec is a specification of a Lease.
|
||||
type LeaseSpec struct {
|
||||
// holderIdentity contains the identity of the holder of a current lease.
|
||||
// If Coordinated Leader Election is used, the holder identity must be
|
||||
// equal to the elected LeaseCandidate.metadata.name field.
|
||||
// +optional
|
||||
HolderIdentity *string `json:"holderIdentity,omitempty" protobuf:"bytes,1,opt,name=holderIdentity"`
|
||||
// leaseDurationSeconds is a duration that candidates for a lease need
|
||||
// to wait to force acquire it. This is measure against time of last
|
||||
// to wait to force acquire it. This is measured against the time of last
|
||||
// observed renewTime.
|
||||
// +optional
|
||||
LeaseDurationSeconds *int32 `json:"leaseDurationSeconds,omitempty" protobuf:"varint,2,opt,name=leaseDurationSeconds"`
|
||||
@ -57,9 +72,22 @@ type LeaseSpec struct {
|
||||
// holders.
|
||||
// +optional
|
||||
LeaseTransitions *int32 `json:"leaseTransitions,omitempty" protobuf:"varint,5,opt,name=leaseTransitions"`
|
||||
// Strategy indicates the strategy for picking the leader for coordinated leader election.
|
||||
// If the field is not specified, there is no active coordination for this lease.
|
||||
// (Alpha) Using this field requires the CoordinatedLeaderElection feature gate to be enabled.
|
||||
// +featureGate=CoordinatedLeaderElection
|
||||
// +optional
|
||||
Strategy *CoordinatedLeaseStrategy `json:"strategy,omitempty" protobuf:"bytes,6,opt,name=strategy"`
|
||||
// PreferredHolder signals to a lease holder that the lease has a
|
||||
// more optimal holder and should be given up.
|
||||
// This field can only be set if Strategy is also set.
|
||||
// +featureGate=CoordinatedLeaderElection
|
||||
// +optional
|
||||
PreferredHolder *string `json:"preferredHolder,omitempty" protobuf:"bytes,7,opt,name=preferredHolder"`
|
||||
}
|
||||
|
||||
// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
|
||||
// +k8s:prerelease-lifecycle-gen:introduced=1.19
|
||||
|
||||
// LeaseList is a list of Lease objects.
|
||||
type LeaseList struct {
|
||||
|
6
vendor/k8s.io/api/coordination/v1/types_swagger_doc_generated.go
generated
vendored
6
vendor/k8s.io/api/coordination/v1/types_swagger_doc_generated.go
generated
vendored
@ -49,11 +49,13 @@ func (LeaseList) SwaggerDoc() map[string]string {
|
||||
|
||||
var map_LeaseSpec = map[string]string{
|
||||
"": "LeaseSpec is a specification of a Lease.",
|
||||
"holderIdentity": "holderIdentity contains the identity of the holder of a current lease.",
|
||||
"leaseDurationSeconds": "leaseDurationSeconds is a duration that candidates for a lease need to wait to force acquire it. This is measure against time of last observed renewTime.",
|
||||
"holderIdentity": "holderIdentity contains the identity of the holder of a current lease. If Coordinated Leader Election is used, the holder identity must be equal to the elected LeaseCandidate.metadata.name field.",
|
||||
"leaseDurationSeconds": "leaseDurationSeconds is a duration that candidates for a lease need to wait to force acquire it. This is measured against the time of last observed renewTime.",
|
||||
"acquireTime": "acquireTime is a time when the current lease was acquired.",
|
||||
"renewTime": "renewTime is a time when the current holder of a lease has last updated the lease.",
|
||||
"leaseTransitions": "leaseTransitions is the number of transitions of a lease between holders.",
|
||||
"strategy": "Strategy indicates the strategy for picking the leader for coordinated leader election. If the field is not specified, there is no active coordination for this lease. (Alpha) Using this field requires the CoordinatedLeaderElection feature gate to be enabled.",
|
||||
"preferredHolder": "PreferredHolder signals to a lease holder that the lease has a more optimal holder and should be given up. This field can only be set if Strategy is also set.",
|
||||
}
|
||||
|
||||
func (LeaseSpec) SwaggerDoc() map[string]string {
|
||||
|
10
vendor/k8s.io/api/coordination/v1/zz_generated.deepcopy.go
generated
vendored
10
vendor/k8s.io/api/coordination/v1/zz_generated.deepcopy.go
generated
vendored
@ -111,6 +111,16 @@ func (in *LeaseSpec) DeepCopyInto(out *LeaseSpec) {
|
||||
*out = new(int32)
|
||||
**out = **in
|
||||
}
|
||||
if in.Strategy != nil {
|
||||
in, out := &in.Strategy, &out.Strategy
|
||||
*out = new(CoordinatedLeaseStrategy)
|
||||
**out = **in
|
||||
}
|
||||
if in.PreferredHolder != nil {
|
||||
in, out := &in.PreferredHolder, &out.PreferredHolder
|
||||
*out = new(string)
|
||||
**out = **in
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
34
vendor/k8s.io/api/coordination/v1/zz_generated.prerelease-lifecycle.go
generated
vendored
Normal file
34
vendor/k8s.io/api/coordination/v1/zz_generated.prerelease-lifecycle.go
generated
vendored
Normal file
@ -0,0 +1,34 @@
|
||||
//go:build !ignore_autogenerated
|
||||
// +build !ignore_autogenerated
|
||||
|
||||
/*
|
||||
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 prerelease-lifecycle-gen. DO NOT EDIT.
|
||||
|
||||
package v1
|
||||
|
||||
// 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 *Lease) APILifecycleIntroduced() (major, minor int) {
|
||||
return 1, 14
|
||||
}
|
||||
|
||||
// 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) {
|
||||
return 1, 19
|
||||
}
|
24
vendor/k8s.io/api/coordination/v1alpha1/doc.go
generated
vendored
Normal file
24
vendor/k8s.io/api/coordination/v1alpha1/doc.go
generated
vendored
Normal file
@ -0,0 +1,24 @@
|
||||
/*
|
||||
Copyright 2024 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.
|
||||
*/
|
||||
|
||||
// +k8s:deepcopy-gen=package
|
||||
// +k8s:protobuf-gen=package
|
||||
// +k8s:openapi-gen=true
|
||||
// +k8s:prerelease-lifecycle-gen=true
|
||||
|
||||
// +groupName=coordination.k8s.io
|
||||
|
||||
package v1alpha1 // import "k8s.io/api/coordination/v1alpha1"
|
1036
vendor/k8s.io/api/coordination/v1alpha1/generated.pb.go
generated
vendored
Normal file
1036
vendor/k8s.io/api/coordination/v1alpha1/generated.pb.go
generated
vendored
Normal file
File diff suppressed because it is too large
Load Diff
105
vendor/k8s.io/api/coordination/v1alpha1/generated.proto
generated
vendored
Normal file
105
vendor/k8s.io/api/coordination/v1alpha1/generated.proto
generated
vendored
Normal file
@ -0,0 +1,105 @@
|
||||
/*
|
||||
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.
|
||||
*/
|
||||
|
||||
|
||||
// This file was autogenerated by go-to-protobuf. Do not edit it manually!
|
||||
|
||||
syntax = "proto2";
|
||||
|
||||
package k8s.io.api.coordination.v1alpha1;
|
||||
|
||||
import "k8s.io/api/coordination/v1/generated.proto";
|
||||
import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto";
|
||||
import "k8s.io/apimachinery/pkg/runtime/generated.proto";
|
||||
import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto";
|
||||
|
||||
// Package-wide variables from generator "generated".
|
||||
option go_package = "k8s.io/api/coordination/v1alpha1";
|
||||
|
||||
// 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.
|
||||
// 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 when strategy is "OldestEmulationVersion"
|
||||
// +optional
|
||||
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;
|
||||
|
||||
// PreferredStrategies indicates the list of strategies for picking the leader for coordinated leader election.
|
||||
// The list is ordered, and the first strategy supersedes all other strategies. The list is used by coordinated
|
||||
// leader election to make a decision about the final election strategy. This follows as
|
||||
// - If all clients have strategy X as the first element in this list, strategy X will be used.
|
||||
// - If a candidate has strategy [X] and another candidate has strategy [Y, X], Y supersedes X and strategy Y
|
||||
// will be used.
|
||||
// - If a candidate has strategy [X, Y] and another candidate has strategy [Y, X], this is a user error and leader
|
||||
// election will not operate the Lease until resolved.
|
||||
// (Alpha) Using this field requires the CoordinatedLeaderElection feature gate to be enabled.
|
||||
// +featureGate=CoordinatedLeaderElection
|
||||
// +listType=atomic
|
||||
// +required
|
||||
repeated string preferredStrategies = 6;
|
||||
}
|
||||
|
53
vendor/k8s.io/api/coordination/v1alpha1/register.go
generated
vendored
Normal file
53
vendor/k8s.io/api/coordination/v1alpha1/register.go
generated
vendored
Normal file
@ -0,0 +1,53 @@
|
||||
/*
|
||||
Copyright 2018 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.
|
||||
*/
|
||||
|
||||
package v1alpha1
|
||||
|
||||
import (
|
||||
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
"k8s.io/apimachinery/pkg/runtime"
|
||||
"k8s.io/apimachinery/pkg/runtime/schema"
|
||||
)
|
||||
|
||||
// GroupName is the group name use in this package
|
||||
const GroupName = "coordination.k8s.io"
|
||||
|
||||
// SchemeGroupVersion is group version used to register these objects
|
||||
var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: "v1alpha1"}
|
||||
|
||||
// Resource takes an unqualified resource and returns a Group qualified GroupResource
|
||||
func Resource(resource string) schema.GroupResource {
|
||||
return SchemeGroupVersion.WithResource(resource).GroupResource()
|
||||
}
|
||||
|
||||
var (
|
||||
// TODO: move SchemeBuilder with zz_generated.deepcopy.go to k8s.io/api.
|
||||
// localSchemeBuilder and AddToScheme will stay in k8s.io/kubernetes.
|
||||
SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes)
|
||||
localSchemeBuilder = &SchemeBuilder
|
||||
AddToScheme = localSchemeBuilder.AddToScheme
|
||||
)
|
||||
|
||||
// Adds the list of known types to api.Scheme.
|
||||
func addKnownTypes(scheme *runtime.Scheme) error {
|
||||
scheme.AddKnownTypes(SchemeGroupVersion,
|
||||
&LeaseCandidate{},
|
||||
&LeaseCandidateList{},
|
||||
)
|
||||
|
||||
metav1.AddToGroupVersion(scheme, SchemeGroupVersion)
|
||||
return nil
|
||||
}
|
100
vendor/k8s.io/api/coordination/v1alpha1/types.go
generated
vendored
Normal file
100
vendor/k8s.io/api/coordination/v1alpha1/types.go
generated
vendored
Normal file
@ -0,0 +1,100 @@
|
||||
/*
|
||||
Copyright 2018 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.
|
||||
*/
|
||||
|
||||
package v1alpha1
|
||||
|
||||
import (
|
||||
v1 "k8s.io/api/coordination/v1"
|
||||
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
)
|
||||
|
||||
// +genclient
|
||||
// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
|
||||
// +k8s:prerelease-lifecycle-gen:introduced=1.31
|
||||
|
||||
// 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 LeaseCandidate struct {
|
||||
metav1.TypeMeta `json:",inline"`
|
||||
// More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata
|
||||
// +optional
|
||||
metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
|
||||
|
||||
// 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
|
||||
Spec LeaseCandidateSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"`
|
||||
}
|
||||
|
||||
// LeaseCandidateSpec is a specification of a Lease.
|
||||
type LeaseCandidateSpec struct {
|
||||
// LeaseName is the name of the lease for which this candidate is contending.
|
||||
// This field is immutable.
|
||||
// +required
|
||||
LeaseName string `json:"leaseName" protobuf:"bytes,1,name=leaseName"`
|
||||
// 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
|
||||
PingTime *metav1.MicroTime `json:"pingTime,omitempty" protobuf:"bytes,2,opt,name=pingTime"`
|
||||
// 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
|
||||
RenewTime *metav1.MicroTime `json:"renewTime,omitempty" protobuf:"bytes,3,opt,name=renewTime"`
|
||||
// BinaryVersion is the binary version. It must be in a semver format without leading `v`.
|
||||
// This field is required when strategy is "OldestEmulationVersion"
|
||||
// +optional
|
||||
BinaryVersion string `json:"binaryVersion,omitempty" protobuf:"bytes,4,opt,name=binaryVersion"`
|
||||
// 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
|
||||
EmulationVersion string `json:"emulationVersion,omitempty" protobuf:"bytes,5,opt,name=emulationVersion"`
|
||||
// PreferredStrategies indicates the list of strategies for picking the leader for coordinated leader election.
|
||||
// The list is ordered, and the first strategy supersedes all other strategies. The list is used by coordinated
|
||||
// leader election to make a decision about the final election strategy. This follows as
|
||||
// - If all clients have strategy X as the first element in this list, strategy X will be used.
|
||||
// - If a candidate has strategy [X] and another candidate has strategy [Y, X], Y supersedes X and strategy Y
|
||||
// will be used.
|
||||
// - If a candidate has strategy [X, Y] and another candidate has strategy [Y, X], this is a user error and leader
|
||||
// election will not operate the Lease until resolved.
|
||||
// (Alpha) Using this field requires the CoordinatedLeaderElection feature gate to be enabled.
|
||||
// +featureGate=CoordinatedLeaderElection
|
||||
// +listType=atomic
|
||||
// +required
|
||||
PreferredStrategies []v1.CoordinatedLeaseStrategy `json:"preferredStrategies,omitempty" protobuf:"bytes,6,opt,name=preferredStrategies"`
|
||||
}
|
||||
|
||||
// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
|
||||
// +k8s:prerelease-lifecycle-gen:introduced=1.31
|
||||
|
||||
// LeaseCandidateList is a list of Lease objects.
|
||||
type LeaseCandidateList struct {
|
||||
metav1.TypeMeta `json:",inline"`
|
||||
// Standard list metadata.
|
||||
// More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata
|
||||
// +optional
|
||||
metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
|
||||
|
||||
// items is a list of schema objects.
|
||||
Items []LeaseCandidate `json:"items" protobuf:"bytes,2,rep,name=items"`
|
||||
}
|
64
vendor/k8s.io/api/coordination/v1alpha1/types_swagger_doc_generated.go
generated
vendored
Normal file
64
vendor/k8s.io/api/coordination/v1alpha1/types_swagger_doc_generated.go
generated
vendored
Normal file
@ -0,0 +1,64 @@
|
||||
/*
|
||||
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.
|
||||
*/
|
||||
|
||||
package v1alpha1
|
||||
|
||||
// This file contains a collection of methods that can be used from go-restful to
|
||||
// generate Swagger API documentation for its models. Please read this PR for more
|
||||
// information on the implementation: https://github.com/emicklei/go-restful/pull/215
|
||||
//
|
||||
// TODOs are ignored from the parser (e.g. TODO(andronat):... || TODO:...) if and only if
|
||||
// they are on one line! For multiple line or blocks that you want to ignore use ---.
|
||||
// Any context after a --- is ignored.
|
||||
//
|
||||
// Those methods can be generated by using hack/update-codegen.sh
|
||||
|
||||
// AUTO-GENERATED FUNCTIONS START HERE. DO NOT EDIT.
|
||||
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. 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 when strategy is \"OldestEmulationVersion\"",
|
||||
"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\"",
|
||||
"preferredStrategies": "PreferredStrategies indicates the list of strategies for picking the leader for coordinated leader election. The list is ordered, and the first strategy supersedes all other strategies. The list is used by coordinated leader election to make a decision about the final election strategy. This follows as - If all clients have strategy X as the first element in this list, strategy X will be used. - If a candidate has strategy [X] and another candidate has strategy [Y, X], Y supersedes X and strategy Y\n will be used.\n- If a candidate has strategy [X, Y] and another candidate has strategy [Y, X], this is a user error and leader\n election will not operate the Lease until resolved.\n(Alpha) Using this field requires the CoordinatedLeaderElection feature gate to be enabled.",
|
||||
}
|
||||
|
||||
func (LeaseCandidateSpec) SwaggerDoc() map[string]string {
|
||||
return map_LeaseCandidateSpec
|
||||
}
|
||||
|
||||
// AUTO-GENERATED FUNCTIONS END HERE
|
116
vendor/k8s.io/api/coordination/v1alpha1/zz_generated.deepcopy.go
generated
vendored
Normal file
116
vendor/k8s.io/api/coordination/v1alpha1/zz_generated.deepcopy.go
generated
vendored
Normal file
@ -0,0 +1,116 @@
|
||||
//go:build !ignore_autogenerated
|
||||
// +build !ignore_autogenerated
|
||||
|
||||
/*
|
||||
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 deepcopy-gen. DO NOT EDIT.
|
||||
|
||||
package v1alpha1
|
||||
|
||||
import (
|
||||
v1 "k8s.io/api/coordination/v1"
|
||||
runtime "k8s.io/apimachinery/pkg/runtime"
|
||||
)
|
||||
|
||||
// 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()
|
||||
}
|
||||
if in.PreferredStrategies != nil {
|
||||
in, out := &in.PreferredStrategies, &out.PreferredStrategies
|
||||
*out = make([]v1.CoordinatedLeaseStrategy, len(*in))
|
||||
copy(*out, *in)
|
||||
}
|
||||
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
|
||||
}
|
58
vendor/k8s.io/api/coordination/v1alpha1/zz_generated.prerelease-lifecycle.go
generated
vendored
Normal file
58
vendor/k8s.io/api/coordination/v1alpha1/zz_generated.prerelease-lifecycle.go
generated
vendored
Normal file
@ -0,0 +1,58 @@
|
||||
//go:build !ignore_autogenerated
|
||||
// +build !ignore_autogenerated
|
||||
|
||||
/*
|
||||
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 prerelease-lifecycle-gen. DO NOT EDIT.
|
||||
|
||||
package v1alpha1
|
||||
|
||||
// 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, 31
|
||||
}
|
||||
|
||||
// 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, 34
|
||||
}
|
||||
|
||||
// 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, 37
|
||||
}
|
||||
|
||||
// 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, 31
|
||||
}
|
||||
|
||||
// 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, 34
|
||||
}
|
||||
|
||||
// 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, 37
|
||||
}
|
165
vendor/k8s.io/api/coordination/v1beta1/generated.pb.go
generated
vendored
165
vendor/k8s.io/api/coordination/v1beta1/generated.pb.go
generated
vendored
@ -25,6 +25,8 @@ import (
|
||||
io "io"
|
||||
|
||||
proto "github.com/gogo/protobuf/proto"
|
||||
|
||||
k8s_io_api_coordination_v1 "k8s.io/api/coordination/v1"
|
||||
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
|
||||
math "math"
|
||||
@ -139,40 +141,45 @@ func init() {
|
||||
}
|
||||
|
||||
var fileDescriptor_8d4e223b8bb23da3 = []byte{
|
||||
// 527 bytes of a gzipped FileDescriptorProto
|
||||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x94, 0x41, 0x6f, 0xd3, 0x30,
|
||||
0x14, 0xc7, 0x9b, 0xb5, 0x95, 0x56, 0x97, 0x8d, 0x2a, 0xea, 0x21, 0xea, 0x21, 0x99, 0x7a, 0x40,
|
||||
0x13, 0x12, 0x36, 0x9d, 0x10, 0x42, 0x9c, 0x20, 0x02, 0x89, 0x89, 0x4c, 0x48, 0xd9, 0x4e, 0x68,
|
||||
0x07, 0xdc, 0xe4, 0x91, 0x9a, 0x2e, 0x71, 0x88, 0xdd, 0xa2, 0xdd, 0xf8, 0x08, 0x5c, 0xf9, 0x22,
|
||||
0xf0, 0x15, 0x7a, 0xdc, 0x71, 0xa7, 0x88, 0x9a, 0x2f, 0x82, 0xec, 0x76, 0x6b, 0x69, 0x87, 0x5a,
|
||||
0x71, 0x8b, 0x9f, 0xdf, 0xef, 0xf7, 0xfe, 0x7e, 0x87, 0x20, 0x32, 0x7c, 0x26, 0x30, 0xe3, 0x84,
|
||||
0xe6, 0x8c, 0x44, 0x9c, 0x17, 0x31, 0xcb, 0xa8, 0x64, 0x3c, 0x23, 0xe3, 0x5e, 0x1f, 0x24, 0xed,
|
||||
0x91, 0x04, 0x32, 0x28, 0xa8, 0x84, 0x18, 0xe7, 0x05, 0x97, 0xdc, 0xf6, 0x66, 0x00, 0xa6, 0x39,
|
||||
0xc3, 0xcb, 0x00, 0x9e, 0x03, 0x9d, 0x47, 0x09, 0x93, 0x83, 0x51, 0x1f, 0x47, 0x3c, 0x25, 0x09,
|
||||
0x4f, 0x38, 0x31, 0x5c, 0x7f, 0xf4, 0xd1, 0x9c, 0xcc, 0xc1, 0x7c, 0xcd, 0x7c, 0x9d, 0x27, 0x8b,
|
||||
0x00, 0x29, 0x8d, 0x06, 0x2c, 0x83, 0xe2, 0x92, 0xe4, 0xc3, 0x44, 0x17, 0x04, 0x49, 0x41, 0x52,
|
||||
0x32, 0x5e, 0x4b, 0xd1, 0x21, 0xff, 0xa2, 0x8a, 0x51, 0x26, 0x59, 0x0a, 0x6b, 0xc0, 0xd3, 0x4d,
|
||||
0x80, 0x88, 0x06, 0x90, 0xd2, 0x55, 0xae, 0xfb, 0xd3, 0x42, 0xf5, 0x00, 0xa8, 0x00, 0xfb, 0x03,
|
||||
0xda, 0xd5, 0x69, 0x62, 0x2a, 0xa9, 0x63, 0x1d, 0x58, 0x87,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7, 0x0e, 0xee, 0xb8, 0x0f, 0xef, 0xa4, 0xec, 0x3e, 0x6a, 0xd2,
|
||||
0xe8, 0xf3, 0x88, 0x15, 0x70, 0xc6, 0x52, 0x70, 0xaa, 0x66, 0x8b, 0x64, 0xbb, 0x2d, 0x9e, 0xb0,
|
||||
0xa8, 0xe0, 0x1a, 0xf3, 0xef, 0xab, 0xd2, 0x6b, 0xbe, 0x5c, 0x78, 0xc2, 0x65, 0xa9, 0x7d, 0x8e,
|
||||
0x1a, 0x05, 0x64, 0xf0, 0xc5, 0x4c, 0xa8, 0xfd, 0xdf, 0x84, 0x3d, 0x55, 0x7a, 0x8d, 0xf0, 0xc6,
|
||||
0x12, 0x2e, 0x84, 0xf6, 0x0b, 0xd4, 0x32, 0x2f, 0x3b, 0x2b, 0x68, 0x26, 0x98, 0x7e, 0x9b, 0x70,
|
||||
0xea, 0x66, 0x17, 0x6d, 0x55, 0x7a, 0xad, 0x60, 0xe5, 0x2e, 0x5c, 0xeb, 0xf6, 0x5f, 0x4f, 0xa6,
|
||||
0x6e, 0xe5, 0x6a, 0xea, 0x56, 0xae, 0xa7, 0x6e, 0xe5, 0xab, 0x72, 0xad, 0x89, 0x72, 0xad, 0x2b,
|
||||
0xe5, 0x5a, 0xd7, 0xca, 0xb5, 0x7e, 0x29, 0xd7, 0xfa, 0xf6, 0xdb, 0xad, 0xbc, 0xf7, 0x36, 0xfc,
|
||||
0x54, 0xfe, 0x04, 0x00, 0x00, 0xff, 0xff, 0x5d, 0x81, 0x42, 0xfe, 0x76, 0x04, 0x00, 0x00,
|
||||
// 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, 0x0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af, 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,
|
||||
}
|
||||
|
||||
func (m *Lease) Marshal() (dAtA []byte, err error) {
|
||||
@ -285,6 +292,20 @@ func (m *LeaseSpec) MarshalToSizedBuffer(dAtA []byte) (int, error) {
|
||||
_ = i
|
||||
var l int
|
||||
_ = l
|
||||
if m.PreferredHolder != nil {
|
||||
i -= len(*m.PreferredHolder)
|
||||
copy(dAtA[i:], *m.PreferredHolder)
|
||||
i = encodeVarintGenerated(dAtA, i, uint64(len(*m.PreferredHolder)))
|
||||
i--
|
||||
dAtA[i] = 0x3a
|
||||
}
|
||||
if m.Strategy != nil {
|
||||
i -= len(*m.Strategy)
|
||||
copy(dAtA[i:], *m.Strategy)
|
||||
i = encodeVarintGenerated(dAtA, i, uint64(len(*m.Strategy)))
|
||||
i--
|
||||
dAtA[i] = 0x32
|
||||
}
|
||||
if m.LeaseTransitions != nil {
|
||||
i = encodeVarintGenerated(dAtA, i, uint64(*m.LeaseTransitions))
|
||||
i--
|
||||
@ -394,6 +415,14 @@ func (m *LeaseSpec) Size() (n int) {
|
||||
if m.LeaseTransitions != nil {
|
||||
n += 1 + sovGenerated(uint64(*m.LeaseTransitions))
|
||||
}
|
||||
if m.Strategy != nil {
|
||||
l = len(*m.Strategy)
|
||||
n += 1 + l + sovGenerated(uint64(l))
|
||||
}
|
||||
if m.PreferredHolder != nil {
|
||||
l = len(*m.PreferredHolder)
|
||||
n += 1 + l + sovGenerated(uint64(l))
|
||||
}
|
||||
return n
|
||||
}
|
||||
|
||||
@ -440,6 +469,8 @@ func (this *LeaseSpec) String() string {
|
||||
`AcquireTime:` + strings.Replace(fmt.Sprintf("%v", this.AcquireTime), "MicroTime", "v1.MicroTime", 1) + `,`,
|
||||
`RenewTime:` + strings.Replace(fmt.Sprintf("%v", this.RenewTime), "MicroTime", "v1.MicroTime", 1) + `,`,
|
||||
`LeaseTransitions:` + valueToStringGenerated(this.LeaseTransitions) + `,`,
|
||||
`Strategy:` + valueToStringGenerated(this.Strategy) + `,`,
|
||||
`PreferredHolder:` + valueToStringGenerated(this.PreferredHolder) + `,`,
|
||||
`}`,
|
||||
}, "")
|
||||
return s
|
||||
@ -859,6 +890,72 @@ func (m *LeaseSpec) Unmarshal(dAtA []byte) error {
|
||||
}
|
||||
}
|
||||
m.LeaseTransitions = &v
|
||||
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
|
||||
}
|
||||
s := k8s_io_api_coordination_v1.CoordinatedLeaseStrategy(dAtA[iNdEx:postIndex])
|
||||
m.Strategy = &s
|
||||
iNdEx = postIndex
|
||||
case 7:
|
||||
if wireType != 2 {
|
||||
return fmt.Errorf("proto: wrong wireType = %d for field PreferredHolder", 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
|
||||
}
|
||||
s := string(dAtA[iNdEx:postIndex])
|
||||
m.PreferredHolder = &s
|
||||
iNdEx = postIndex
|
||||
default:
|
||||
iNdEx = preIndex
|
||||
skippy, err := skipGenerated(dAtA[iNdEx:])
|
||||
|
23
vendor/k8s.io/api/coordination/v1beta1/generated.proto
generated
vendored
23
vendor/k8s.io/api/coordination/v1beta1/generated.proto
generated
vendored
@ -21,6 +21,7 @@ syntax = "proto2";
|
||||
|
||||
package k8s.io.api.coordination.v1beta1;
|
||||
|
||||
import "k8s.io/api/coordination/v1/generated.proto";
|
||||
import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto";
|
||||
import "k8s.io/apimachinery/pkg/runtime/generated.proto";
|
||||
import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto";
|
||||
@ -32,7 +33,7 @@ option go_package = "k8s.io/api/coordination/v1beta1";
|
||||
message Lease {
|
||||
// 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;
|
||||
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
|
||||
@ -45,7 +46,7 @@ message LeaseList {
|
||||
// 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;
|
||||
optional .k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1;
|
||||
|
||||
// items is a list of schema objects.
|
||||
repeated Lease items = 2;
|
||||
@ -54,6 +55,8 @@ message LeaseList {
|
||||
// LeaseSpec is a specification of a Lease.
|
||||
message LeaseSpec {
|
||||
// holderIdentity contains the identity of the holder of a current lease.
|
||||
// If Coordinated Leader Election is used, the holder identity must be
|
||||
// equal to the elected LeaseCandidate.metadata.name field.
|
||||
// +optional
|
||||
optional string holderIdentity = 1;
|
||||
|
||||
@ -65,16 +68,28 @@ message LeaseSpec {
|
||||
|
||||
// acquireTime is a time when the current lease was acquired.
|
||||
// +optional
|
||||
optional k8s.io.apimachinery.pkg.apis.meta.v1.MicroTime acquireTime = 3;
|
||||
optional .k8s.io.apimachinery.pkg.apis.meta.v1.MicroTime acquireTime = 3;
|
||||
|
||||
// renewTime is a time when the current holder of a lease has last
|
||||
// updated the lease.
|
||||
// +optional
|
||||
optional k8s.io.apimachinery.pkg.apis.meta.v1.MicroTime renewTime = 4;
|
||||
optional .k8s.io.apimachinery.pkg.apis.meta.v1.MicroTime renewTime = 4;
|
||||
|
||||
// leaseTransitions is the number of transitions of a lease between
|
||||
// holders.
|
||||
// +optional
|
||||
optional int32 leaseTransitions = 5;
|
||||
|
||||
// Strategy indicates the strategy for picking the leader for coordinated leader election
|
||||
// (Alpha) Using this field requires the CoordinatedLeaderElection feature gate to be enabled.
|
||||
// +featureGate=CoordinatedLeaderElection
|
||||
// +optional
|
||||
optional string strategy = 6;
|
||||
|
||||
// PreferredHolder signals to a lease holder that the lease has a
|
||||
// more optimal holder and should be given up.
|
||||
// +featureGate=CoordinatedLeaderElection
|
||||
// +optional
|
||||
optional string preferredHolder = 7;
|
||||
}
|
||||
|
||||
|
13
vendor/k8s.io/api/coordination/v1beta1/types.go
generated
vendored
13
vendor/k8s.io/api/coordination/v1beta1/types.go
generated
vendored
@ -17,6 +17,7 @@ limitations under the License.
|
||||
package v1beta1
|
||||
|
||||
import (
|
||||
v1 "k8s.io/api/coordination/v1"
|
||||
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
)
|
||||
|
||||
@ -42,6 +43,8 @@ type Lease struct {
|
||||
// LeaseSpec is a specification of a Lease.
|
||||
type LeaseSpec struct {
|
||||
// holderIdentity contains the identity of the holder of a current lease.
|
||||
// If Coordinated Leader Election is used, the holder identity must be
|
||||
// equal to the elected LeaseCandidate.metadata.name field.
|
||||
// +optional
|
||||
HolderIdentity *string `json:"holderIdentity,omitempty" protobuf:"bytes,1,opt,name=holderIdentity"`
|
||||
// leaseDurationSeconds is a duration that candidates for a lease need
|
||||
@ -60,6 +63,16 @@ type LeaseSpec struct {
|
||||
// holders.
|
||||
// +optional
|
||||
LeaseTransitions *int32 `json:"leaseTransitions,omitempty" protobuf:"varint,5,opt,name=leaseTransitions"`
|
||||
// Strategy indicates the strategy for picking the leader for coordinated leader election
|
||||
// (Alpha) Using this field requires the CoordinatedLeaderElection feature gate to be enabled.
|
||||
// +featureGate=CoordinatedLeaderElection
|
||||
// +optional
|
||||
Strategy *v1.CoordinatedLeaseStrategy `json:"strategy,omitempty" protobuf:"bytes,6,opt,name=strategy"`
|
||||
// PreferredHolder signals to a lease holder that the lease has a
|
||||
// more optimal holder and should be given up.
|
||||
// +featureGate=CoordinatedLeaderElection
|
||||
// +optional
|
||||
PreferredHolder *string `json:"preferredHolder,omitempty" protobuf:"bytes,7,opt,name=preferredHolder"`
|
||||
}
|
||||
|
||||
// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
|
||||
|
4
vendor/k8s.io/api/coordination/v1beta1/types_swagger_doc_generated.go
generated
vendored
4
vendor/k8s.io/api/coordination/v1beta1/types_swagger_doc_generated.go
generated
vendored
@ -49,11 +49,13 @@ func (LeaseList) SwaggerDoc() map[string]string {
|
||||
|
||||
var map_LeaseSpec = map[string]string{
|
||||
"": "LeaseSpec is a specification of a Lease.",
|
||||
"holderIdentity": "holderIdentity contains the identity of the holder of a current lease.",
|
||||
"holderIdentity": "holderIdentity contains the identity of the holder of a current lease. If Coordinated Leader Election is used, the holder identity must be equal to the elected LeaseCandidate.metadata.name field.",
|
||||
"leaseDurationSeconds": "leaseDurationSeconds is a duration that candidates for a lease need to wait to force acquire it. This is measure against time of last observed renewTime.",
|
||||
"acquireTime": "acquireTime is a time when the current lease was acquired.",
|
||||
"renewTime": "renewTime is a time when the current holder of a lease has last updated the lease.",
|
||||
"leaseTransitions": "leaseTransitions is the number of transitions of a lease between holders.",
|
||||
"strategy": "Strategy indicates the strategy for picking the leader for coordinated leader election (Alpha) Using this field requires the CoordinatedLeaderElection feature gate to be enabled.",
|
||||
"preferredHolder": "PreferredHolder signals to a lease holder that the lease has a more optimal holder and should be given up.",
|
||||
}
|
||||
|
||||
func (LeaseSpec) SwaggerDoc() map[string]string {
|
||||
|
11
vendor/k8s.io/api/coordination/v1beta1/zz_generated.deepcopy.go
generated
vendored
11
vendor/k8s.io/api/coordination/v1beta1/zz_generated.deepcopy.go
generated
vendored
@ -22,6 +22,7 @@ limitations under the License.
|
||||
package v1beta1
|
||||
|
||||
import (
|
||||
v1 "k8s.io/api/coordination/v1"
|
||||
runtime "k8s.io/apimachinery/pkg/runtime"
|
||||
)
|
||||
|
||||
@ -111,6 +112,16 @@ func (in *LeaseSpec) DeepCopyInto(out *LeaseSpec) {
|
||||
*out = new(int32)
|
||||
**out = **in
|
||||
}
|
||||
if in.Strategy != nil {
|
||||
in, out := &in.Strategy, &out.Strategy
|
||||
*out = new(v1.CoordinatedLeaseStrategy)
|
||||
**out = **in
|
||||
}
|
||||
if in.PreferredHolder != nil {
|
||||
in, out := &in.PreferredHolder, &out.PreferredHolder
|
||||
*out = new(string)
|
||||
**out = **in
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user