2017-10-19 19:53:02 +00:00
|
|
|
// <auto-generated>
|
|
|
|
|
// Code generated by Microsoft (R) AutoRest Code Generator.
|
|
|
|
|
// Changes may cause incorrect behavior and will be lost if the code is
|
|
|
|
|
// regenerated.
|
|
|
|
|
// </auto-generated>
|
|
|
|
|
|
|
|
|
|
namespace k8s.Models
|
|
|
|
|
{
|
|
|
|
|
using Newtonsoft.Json;
|
2018-01-27 04:25:58 +08:00
|
|
|
using System.Collections;
|
|
|
|
|
using System.Collections.Generic;
|
2017-10-19 19:53:02 +00:00
|
|
|
using System.Linq;
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// StatefulSetStatus represents the current state of a StatefulSet.
|
|
|
|
|
/// </summary>
|
2017-11-24 12:10:51 +08:00
|
|
|
public partial class V1beta1StatefulSetStatus
|
2017-10-19 19:53:02 +00:00
|
|
|
{
|
|
|
|
|
/// <summary>
|
2017-11-24 12:10:51 +08:00
|
|
|
/// Initializes a new instance of the V1beta1StatefulSetStatus class.
|
2017-10-19 19:53:02 +00:00
|
|
|
/// </summary>
|
2017-11-24 12:10:51 +08:00
|
|
|
public V1beta1StatefulSetStatus()
|
2017-10-19 19:53:02 +00:00
|
|
|
{
|
|
|
|
|
CustomInit();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
2017-11-24 12:10:51 +08:00
|
|
|
/// Initializes a new instance of the V1beta1StatefulSetStatus class.
|
2017-10-19 19:53:02 +00:00
|
|
|
/// </summary>
|
|
|
|
|
/// <param name="replicas">replicas is the number of Pods created by
|
|
|
|
|
/// the StatefulSet controller.</param>
|
|
|
|
|
/// <param name="collisionCount">collisionCount is the count of hash
|
|
|
|
|
/// collisions for the StatefulSet. The StatefulSet controller uses
|
|
|
|
|
/// this field as a collision avoidance mechanism when it needs to
|
|
|
|
|
/// create the name for the newest ControllerRevision.</param>
|
2018-01-27 04:25:58 +08:00
|
|
|
/// <param name="conditions">Represents the latest available
|
|
|
|
|
/// observations of a statefulset's current state.</param>
|
2017-10-19 19:53:02 +00:00
|
|
|
/// <param name="currentReplicas">currentReplicas is the number of Pods
|
|
|
|
|
/// created by the StatefulSet controller from the StatefulSet version
|
|
|
|
|
/// indicated by currentRevision.</param>
|
|
|
|
|
/// <param name="currentRevision">currentRevision, if not empty,
|
|
|
|
|
/// indicates the version of the StatefulSet used to generate Pods in
|
|
|
|
|
/// the sequence [0,currentReplicas).</param>
|
|
|
|
|
/// <param name="observedGeneration">observedGeneration is the most
|
|
|
|
|
/// recent generation observed for this StatefulSet. It corresponds to
|
|
|
|
|
/// the StatefulSet's generation, which is updated on mutation by the
|
|
|
|
|
/// API Server.</param>
|
|
|
|
|
/// <param name="readyReplicas">readyReplicas is the number of Pods
|
|
|
|
|
/// created by the StatefulSet controller that have a Ready
|
|
|
|
|
/// Condition.</param>
|
|
|
|
|
/// <param name="updateRevision">updateRevision, if not empty,
|
|
|
|
|
/// indicates the version of the StatefulSet used to generate Pods in
|
|
|
|
|
/// the sequence [replicas-updatedReplicas,replicas)</param>
|
|
|
|
|
/// <param name="updatedReplicas">updatedReplicas is the number of Pods
|
|
|
|
|
/// created by the StatefulSet controller from the StatefulSet version
|
|
|
|
|
/// indicated by updateRevision.</param>
|
2018-01-27 04:25:58 +08:00
|
|
|
public V1beta1StatefulSetStatus(int replicas, int? collisionCount = default(int?), IList<V1beta1StatefulSetCondition> conditions = default(IList<V1beta1StatefulSetCondition>), int? currentReplicas = default(int?), string currentRevision = default(string), long? observedGeneration = default(long?), int? readyReplicas = default(int?), string updateRevision = default(string), int? updatedReplicas = default(int?))
|
2017-10-19 19:53:02 +00:00
|
|
|
{
|
|
|
|
|
CollisionCount = collisionCount;
|
2018-01-27 04:25:58 +08:00
|
|
|
Conditions = conditions;
|
2017-10-19 19:53:02 +00:00
|
|
|
CurrentReplicas = currentReplicas;
|
|
|
|
|
CurrentRevision = currentRevision;
|
|
|
|
|
ObservedGeneration = observedGeneration;
|
|
|
|
|
ReadyReplicas = readyReplicas;
|
|
|
|
|
Replicas = replicas;
|
|
|
|
|
UpdateRevision = updateRevision;
|
|
|
|
|
UpdatedReplicas = updatedReplicas;
|
|
|
|
|
CustomInit();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// An initialization method that performs custom operations like setting defaults
|
|
|
|
|
/// </summary>
|
|
|
|
|
partial void CustomInit();
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Gets or sets collisionCount is the count of hash collisions for the
|
|
|
|
|
/// StatefulSet. The StatefulSet controller uses this field as a
|
|
|
|
|
/// collision avoidance mechanism when it needs to create the name for
|
|
|
|
|
/// the newest ControllerRevision.
|
|
|
|
|
/// </summary>
|
|
|
|
|
[JsonProperty(PropertyName = "collisionCount")]
|
|
|
|
|
public int? CollisionCount { get; set; }
|
|
|
|
|
|
2018-01-27 04:25:58 +08:00
|
|
|
/// <summary>
|
|
|
|
|
/// Gets or sets represents the latest available observations of a
|
|
|
|
|
/// statefulset's current state.
|
|
|
|
|
/// </summary>
|
|
|
|
|
[JsonProperty(PropertyName = "conditions")]
|
|
|
|
|
public IList<V1beta1StatefulSetCondition> Conditions { get; set; }
|
|
|
|
|
|
2017-10-19 19:53:02 +00:00
|
|
|
/// <summary>
|
|
|
|
|
/// Gets or sets currentReplicas is the number of Pods created by the
|
|
|
|
|
/// StatefulSet controller from the StatefulSet version indicated by
|
|
|
|
|
/// currentRevision.
|
|
|
|
|
/// </summary>
|
|
|
|
|
[JsonProperty(PropertyName = "currentReplicas")]
|
|
|
|
|
public int? CurrentReplicas { get; set; }
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Gets or sets currentRevision, if not empty, indicates the version
|
|
|
|
|
/// of the StatefulSet used to generate Pods in the sequence
|
|
|
|
|
/// [0,currentReplicas).
|
|
|
|
|
/// </summary>
|
|
|
|
|
[JsonProperty(PropertyName = "currentRevision")]
|
|
|
|
|
public string CurrentRevision { get; set; }
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Gets or sets observedGeneration is the most recent generation
|
|
|
|
|
/// observed for this StatefulSet. It corresponds to the StatefulSet's
|
|
|
|
|
/// generation, which is updated on mutation by the API Server.
|
|
|
|
|
/// </summary>
|
|
|
|
|
[JsonProperty(PropertyName = "observedGeneration")]
|
|
|
|
|
public long? ObservedGeneration { get; set; }
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Gets or sets readyReplicas is the number of Pods created by the
|
|
|
|
|
/// StatefulSet controller that have a Ready Condition.
|
|
|
|
|
/// </summary>
|
|
|
|
|
[JsonProperty(PropertyName = "readyReplicas")]
|
|
|
|
|
public int? ReadyReplicas { get; set; }
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Gets or sets replicas is the number of Pods created by the
|
|
|
|
|
/// StatefulSet controller.
|
|
|
|
|
/// </summary>
|
|
|
|
|
[JsonProperty(PropertyName = "replicas")]
|
|
|
|
|
public int Replicas { get; set; }
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Gets or sets updateRevision, if not empty, indicates the version of
|
|
|
|
|
/// the StatefulSet used to generate Pods in the sequence
|
|
|
|
|
/// [replicas-updatedReplicas,replicas)
|
|
|
|
|
/// </summary>
|
|
|
|
|
[JsonProperty(PropertyName = "updateRevision")]
|
|
|
|
|
public string UpdateRevision { get; set; }
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Gets or sets updatedReplicas is the number of Pods created by the
|
|
|
|
|
/// StatefulSet controller from the StatefulSet version indicated by
|
|
|
|
|
/// updateRevision.
|
|
|
|
|
/// </summary>
|
|
|
|
|
[JsonProperty(PropertyName = "updatedReplicas")]
|
|
|
|
|
public int? UpdatedReplicas { get; set; }
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// Validate the object.
|
|
|
|
|
/// </summary>
|
|
|
|
|
/// <exception cref="Microsoft.Rest.ValidationException">
|
|
|
|
|
/// Thrown if validation fails
|
|
|
|
|
/// </exception>
|
|
|
|
|
public virtual void Validate()
|
|
|
|
|
{
|
2018-01-27 04:25:58 +08:00
|
|
|
if (Conditions != null)
|
|
|
|
|
{
|
|
|
|
|
foreach (var element in Conditions)
|
|
|
|
|
{
|
|
|
|
|
if (element != null)
|
|
|
|
|
{
|
|
|
|
|
element.Validate();
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
2017-10-19 19:53:02 +00:00
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|