Show / Hide Table of Contents

Class V1LeaseSpec

LeaseSpec is a specification of a Lease.

Inheritance
object
V1LeaseSpec
Implements
IEquatable<V1LeaseSpec>
Inherited Members
object.GetType()
object.MemberwiseClone()
object.Equals(object, object)
object.ReferenceEquals(object, object)
Namespace: k8s.Models
Assembly: KubernetesClient.dll
Syntax
public record V1LeaseSpec : IEquatable<V1LeaseSpec>

Constructors

View Source

V1LeaseSpec()

Declaration
public V1LeaseSpec()
View Source

V1LeaseSpec(V1LeaseSpec)

Declaration
protected V1LeaseSpec(V1LeaseSpec original)
Parameters
Type Name Description
V1LeaseSpec original

Properties

View Source

AcquireTime

acquireTime is a time when the current lease was acquired.

Declaration
[JsonPropertyName("acquireTime")]
public DateTime? AcquireTime { get; set; }
Property Value
Type Description
DateTime?
View Source

EqualityContract

Declaration
protected virtual Type EqualityContract { get; }
Property Value
Type Description
Type
View Source

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.

Declaration
[JsonPropertyName("holderIdentity")]
public string HolderIdentity { get; set; }
Property Value
Type Description
string
View Source

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.

Declaration
[JsonPropertyName("leaseDurationSeconds")]
public int? LeaseDurationSeconds { get; set; }
Property Value
Type Description
int?
View Source

LeaseTransitions

leaseTransitions is the number of transitions of a lease between holders.

Declaration
[JsonPropertyName("leaseTransitions")]
public int? LeaseTransitions { get; set; }
Property Value
Type Description
int?
View Source

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.

Declaration
[JsonPropertyName("preferredHolder")]
public string PreferredHolder { get; set; }
Property Value
Type Description
string
View Source

RenewTime

renewTime is a time when the current holder of a lease has last updated the lease.

Declaration
[JsonPropertyName("renewTime")]
public DateTime? RenewTime { get; set; }
Property Value
Type Description
DateTime?
View Source

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.

Declaration
[JsonPropertyName("strategy")]
public string Strategy { get; set; }
Property Value
Type Description
string

Methods

View Source

Equals(object?)

Declaration
public override bool Equals(object? obj)
Parameters
Type Name Description
object obj
Returns
Type Description
bool
Overrides
object.Equals(object)
View Source

Equals(V1LeaseSpec?)

Declaration
public virtual bool Equals(V1LeaseSpec? other)
Parameters
Type Name Description
V1LeaseSpec other
Returns
Type Description
bool
View Source

GetHashCode()

Declaration
public override int GetHashCode()
Returns
Type Description
int
Overrides
object.GetHashCode()
View Source

PrintMembers(StringBuilder)

Declaration
protected virtual bool PrintMembers(StringBuilder builder)
Parameters
Type Name Description
StringBuilder builder
Returns
Type Description
bool
View Source

ToString()

Declaration
public override string ToString()
Returns
Type Description
string
Overrides
object.ToString()

Operators

View Source

operator ==(V1LeaseSpec?, V1LeaseSpec?)

Declaration
public static bool operator ==(V1LeaseSpec? left, V1LeaseSpec? right)
Parameters
Type Name Description
V1LeaseSpec left
V1LeaseSpec right
Returns
Type Description
bool
View Source

operator !=(V1LeaseSpec?, V1LeaseSpec?)

Declaration
public static bool operator !=(V1LeaseSpec? left, V1LeaseSpec? right)
Parameters
Type Name Description
V1LeaseSpec left
V1LeaseSpec right
Returns
Type Description
bool

Implements

IEquatable<T>
  • View Source
In this article
Back to top Generated by DocFX