Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Adjuster ¶
type Adjuster struct { }
Adjuster calculates the set of changes which need to be applied to Kubernetes in order for the running cluster to match the requirements described in the cluster definition.
func (*Adjuster) ChangesForCluster ¶
func (r *Adjuster) ChangesForCluster(oldCluster *v1alpha1.Cassandra, newCluster *v1alpha1.Cassandra) []ClusterChange
ChangesForCluster compares oldCluster with newCluster, and produces an ordered list of ClusterChanges which need to be applied in order for the running cluster to be in the state matching newCluster.
func (*Adjuster) CreateConfigMapHashPatchForRack ¶
func (r *Adjuster) CreateConfigMapHashPatchForRack(rack *v1alpha1.Rack, configMap *v1.ConfigMap) *ClusterChange
CreateConfigMapHashPatchForRack produces a ClusterChange which need to be applied for the given rack
type ClusterChange ¶
type ClusterChange struct { // This is not a pointer on purpose to isolate the change from the actual state Rack v1alpha1.Rack ChangeType ClusterChangeType Patch string }
ClusterChange describes a single change which needs to be applied to Kubernetes in order for the running cluster to match the requirements described in the cluster definition.
type ClusterChangeType ¶
type ClusterChangeType string
ClusterChangeType describes the type of change which needs to be made to a cluster.
const ( // AddRack means that a new rack should be added to a cluster. AddRack ClusterChangeType = "add rack" // UpdateRack means that an existing rack in the cluster needs to be updated. UpdateRack ClusterChangeType = "update rack" )