Documentation ¶
Index ¶
- func BuildOwnerReference(cluster *rapi.RedisCluster) metav1.OwnerReference
- func CreateRedisClusterLabelSelector(rediscluster *rapi.RedisCluster) (labels.Selector, error)
- func GenerateMD5Spec(spec *kapiv1.PodSpec) (string, error)
- func GetAnnotationsSet(rediscluster *rapi.RedisCluster) (labels.Set, error)
- func GetLabelsSet(rediscluster *rapi.RedisCluster) (labels.Set, error)
- type RedisClusterControl
- func (p *RedisClusterControl) CreatePod(redisCluster *rapi.RedisCluster) (*kapiv1.Pod, error)
- func (p *RedisClusterControl) DeletePod(redisCluster *rapi.RedisCluster, podName string) error
- func (p *RedisClusterControl) DeletePodNow(redisCluster *rapi.RedisCluster, podName string) error
- func (p *RedisClusterControl) GetRedisClusterPods(redisCluster *rapi.RedisCluster) ([]*kapiv1.Pod, error)
- type RedisClusterControlInteface
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func BuildOwnerReference ¶
func BuildOwnerReference(cluster *rapi.RedisCluster) metav1.OwnerReference
BuildOwnerReference used to build the OwnerReference from a RedisCluster
func CreateRedisClusterLabelSelector ¶
func CreateRedisClusterLabelSelector(rediscluster *rapi.RedisCluster) (labels.Selector, error)
CreateRedisClusterLabelSelector creates label selector to select the jobs related to a rediscluster, stepName
func GenerateMD5Spec ¶
GenerateMD5Spec used to generate the PodSpec MD5 hash
func GetAnnotationsSet ¶
func GetAnnotationsSet(rediscluster *rapi.RedisCluster) (labels.Set, error)
GetAnnotationsSet return a labels.Set of annotation from the RedisCluster
func GetLabelsSet ¶
func GetLabelsSet(rediscluster *rapi.RedisCluster) (labels.Set, error)
GetLabelsSet return labels associated to the redis-node pods
Types ¶
type RedisClusterControl ¶
type RedisClusterControl struct { PodLister corev1listers.PodLister KubeClient clientset.Interface Recorder record.EventRecorder }
RedisClusterControl contains requieres accessor to managing the RedisCluster pods
func NewRedisClusterControl ¶
func NewRedisClusterControl(lister corev1listers.PodLister, client clientset.Interface, rec record.EventRecorder) *RedisClusterControl
NewRedisClusterControl builds and returns new NewRedisClusterControl instance
func (*RedisClusterControl) CreatePod ¶
func (p *RedisClusterControl) CreatePod(redisCluster *rapi.RedisCluster) (*kapiv1.Pod, error)
CreatePod used to create a Pod from the RedisCluster pod template
func (*RedisClusterControl) DeletePod ¶
func (p *RedisClusterControl) DeletePod(redisCluster *rapi.RedisCluster, podName string) error
DeletePod used to delete a pod from its name
func (*RedisClusterControl) DeletePodNow ¶
func (p *RedisClusterControl) DeletePodNow(redisCluster *rapi.RedisCluster, podName string) error
DeletePodNow used to delete now (force) a pod from its name
func (*RedisClusterControl) GetRedisClusterPods ¶
func (p *RedisClusterControl) GetRedisClusterPods(redisCluster *rapi.RedisCluster) ([]*kapiv1.Pod, error)
GetRedisClusterPods return list of Pod attached to a RedisCluster
type RedisClusterControlInteface ¶
type RedisClusterControlInteface interface { // GetRedisClusterPods return list of Pod attached to a RedisCluster GetRedisClusterPods(redisCluster *rapi.RedisCluster) ([]*kapiv1.Pod, error) // CreatePod used to create a Pod from the RedisCluster pod template CreatePod(redisCluster *rapi.RedisCluster) (*kapiv1.Pod, error) // DeletePod used to delete a pod from its name DeletePod(redisCluster *rapi.RedisCluster, podName string) error // DeletePodNow used to delete now (force) a pod from its name DeletePodNow(redisCluster *rapi.RedisCluster, podName string) error }
RedisClusterControlInteface interface for the RedisClusterPodControl