Documentation ¶
Index ¶
- type RedisFailoverCheck
- type RedisFailoverChecker
- func (r RedisFailoverChecker) CheckAllSlavesFromMaster(master string, rf *v1alpha1.RedisFailover, auth *util2.AuthConfig) error
- func (r RedisFailoverChecker) CheckRedisConfig(rf *v1alpha1.RedisFailover, addr string, auth *util2.AuthConfig) error
- func (r RedisFailoverChecker) CheckRedisNumber(rf *v1alpha1.RedisFailover) error
- func (r RedisFailoverChecker) CheckSentinelMonitor(sentinel string, monitor string, auth *util2.AuthConfig) error
- func (r RedisFailoverChecker) CheckSentinelNumber(rf *v1alpha1.RedisFailover) error
- func (r RedisFailoverChecker) CheckSentinelNumberInMemory(sentinel string, rf *v1alpha1.RedisFailover, auth *util2.AuthConfig) error
- func (r RedisFailoverChecker) CheckSentinelReadyReplicas(rf *v1alpha1.RedisFailover) error
- func (r RedisFailoverChecker) CheckSentinelSlavesNumberInMemory(sentinel string, rf *v1alpha1.RedisFailover, auth *util2.AuthConfig) error
- func (r RedisFailoverChecker) GetMasterIP(rf *v1alpha1.RedisFailover, auth *util2.AuthConfig) (string, error)
- func (r RedisFailoverChecker) GetMinimumRedisPodTime(rf *v1alpha1.RedisFailover) (time.Duration, error)
- func (r RedisFailoverChecker) GetNumberMasters(rf *v1alpha1.RedisFailover, auth *util2.AuthConfig) (int, error)
- func (r RedisFailoverChecker) GetRedisesIPs(rf *v1alpha1.RedisFailover, auth *util2.AuthConfig) ([]string, error)
- func (r RedisFailoverChecker) GetSentinelsIPs(rf *v1alpha1.RedisFailover) ([]string, error)
- type RedisFailoverClient
- type RedisFailoverHeal
- type RedisFailoverHealer
- func (r RedisFailoverHealer) MakeMaster(ip string, auth *util2.AuthConfig) error
- func (r RedisFailoverHealer) NewSentinelMonitor(ip string, monitor string, rf *middlev1alpha1.RedisFailover, ...) error
- func (r RedisFailoverHealer) RestoreSentinel(ip string, auth *util2.AuthConfig) error
- func (r RedisFailoverHealer) SetMasterOnAll(masterIP string, rf *middlev1alpha1.RedisFailover, auth *util2.AuthConfig) error
- func (r RedisFailoverHealer) SetOldestAsMaster(rf *middlev1alpha1.RedisFailover, auth *util2.AuthConfig) error
- func (r RedisFailoverHealer) SetRedisCustomConfig(ip string, rf *middlev1alpha1.RedisFailover, auth *util2.AuthConfig) error
- func (r RedisFailoverHealer) SetSentinelCustomConfig(ip string, rf *middlev1alpha1.RedisFailover, auth *util2.AuthConfig) error
- type RedisFailoverKubeClient
- func (r RedisFailoverKubeClient) EnsureNotPresentRedisService(rf *middlev1alpha1.RedisFailover) error
- func (r RedisFailoverKubeClient) EnsurePasswordSecrets(rf *middlev1alpha1.RedisFailover, labels map[string]string, ...) error
- func (r RedisFailoverKubeClient) EnsureRedisConfigMap(rf *middlev1alpha1.RedisFailover, labels map[string]string, ...) error
- func (r RedisFailoverKubeClient) EnsureRedisNodePortService(rf *middlev1alpha1.RedisFailover, labels map[string]string, ...) error
- func (r RedisFailoverKubeClient) EnsureRedisService(rf *middlev1alpha1.RedisFailover, labels map[string]string, ...) error
- func (r RedisFailoverKubeClient) EnsureRedisShutdownConfigMap(rf *middlev1alpha1.RedisFailover, labels map[string]string, ...) error
- func (r RedisFailoverKubeClient) EnsureRedisStatefulSet(rf *middlev1alpha1.RedisFailover, labels map[string]string, ...) error
- func (r RedisFailoverKubeClient) EnsureSentinelConfigMap(rf *middlev1alpha1.RedisFailover, labels map[string]string, ...) error
- func (r RedisFailoverKubeClient) EnsureSentinelDeployment(rf *middlev1alpha1.RedisFailover, labels map[string]string, ...) error
- func (r RedisFailoverKubeClient) EnsureSentinelHeadlessService(rf *middlev1alpha1.RedisFailover, labels map[string]string, ...) error
- func (r RedisFailoverKubeClient) EnsureSentinelProbeConfigMap(rf *middlev1alpha1.RedisFailover, labels map[string]string, ...) error
- func (r RedisFailoverKubeClient) EnsureSentinelService(rf *middlev1alpha1.RedisFailover, labels map[string]string, ...) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type RedisFailoverCheck ¶
type RedisFailoverCheck interface { CheckRedisNumber(rf *v1alpha1.RedisFailover) error CheckSentinelNumber(rf *v1alpha1.RedisFailover) error CheckSentinelReadyReplicas(rf *v1alpha1.RedisFailover) error CheckAllSlavesFromMaster(master string, rf *v1alpha1.RedisFailover, auth *util2.AuthConfig) error CheckSentinelNumberInMemory(sentinel string, rf *v1alpha1.RedisFailover, auth *util2.AuthConfig) error CheckSentinelSlavesNumberInMemory(sentinel string, rf *v1alpha1.RedisFailover, auth *util2.AuthConfig) error CheckSentinelMonitor(sentinel string, monitor string, auth *util2.AuthConfig) error GetMasterIP(rf *v1alpha1.RedisFailover, auth *util2.AuthConfig) (string, error) GetNumberMasters(rf *v1alpha1.RedisFailover, auth *util2.AuthConfig) (int, error) GetRedisesIPs(rf *v1alpha1.RedisFailover, auth *util2.AuthConfig) ([]string, error) GetSentinelsIPs(rf *v1alpha1.RedisFailover) ([]string, error) GetMinimumRedisPodTime(rf *v1alpha1.RedisFailover) (time.Duration, error) CheckRedisConfig(rf *v1alpha1.RedisFailover, addr string, auth *util2.AuthConfig) error }
type RedisFailoverChecker ¶
type RedisFailoverChecker struct { K8SService k8s.Services Logger logr.Logger StatusWriter client.StatusWriter Record record.EventRecorder RedisClient redis.Client }
func NewRedisFailoverChecker ¶
func NewRedisFailoverChecker(k8SService k8s.Services, log logr.Logger, status client.StatusWriter, record record.EventRecorder, rc redis.Client) *RedisFailoverChecker
func (RedisFailoverChecker) CheckAllSlavesFromMaster ¶
func (r RedisFailoverChecker) CheckAllSlavesFromMaster(master string, rf *v1alpha1.RedisFailover, auth *util2.AuthConfig) error
func (RedisFailoverChecker) CheckRedisConfig ¶
func (r RedisFailoverChecker) CheckRedisConfig(rf *v1alpha1.RedisFailover, addr string, auth *util2.AuthConfig) error
func (RedisFailoverChecker) CheckRedisNumber ¶
func (r RedisFailoverChecker) CheckRedisNumber(rf *v1alpha1.RedisFailover) error
func (RedisFailoverChecker) CheckSentinelMonitor ¶
func (r RedisFailoverChecker) CheckSentinelMonitor(sentinel string, monitor string, auth *util2.AuthConfig) error
func (RedisFailoverChecker) CheckSentinelNumber ¶
func (r RedisFailoverChecker) CheckSentinelNumber(rf *v1alpha1.RedisFailover) error
func (RedisFailoverChecker) CheckSentinelNumberInMemory ¶
func (r RedisFailoverChecker) CheckSentinelNumberInMemory(sentinel string, rf *v1alpha1.RedisFailover, auth *util2.AuthConfig) error
func (RedisFailoverChecker) CheckSentinelReadyReplicas ¶
func (r RedisFailoverChecker) CheckSentinelReadyReplicas(rf *v1alpha1.RedisFailover) error
func (RedisFailoverChecker) CheckSentinelSlavesNumberInMemory ¶
func (r RedisFailoverChecker) CheckSentinelSlavesNumberInMemory(sentinel string, rf *v1alpha1.RedisFailover, auth *util2.AuthConfig) error
func (RedisFailoverChecker) GetMasterIP ¶
func (r RedisFailoverChecker) GetMasterIP(rf *v1alpha1.RedisFailover, auth *util2.AuthConfig) (string, error)
func (RedisFailoverChecker) GetMinimumRedisPodTime ¶
func (r RedisFailoverChecker) GetMinimumRedisPodTime(rf *v1alpha1.RedisFailover) (time.Duration, error)
func (RedisFailoverChecker) GetNumberMasters ¶
func (r RedisFailoverChecker) GetNumberMasters(rf *v1alpha1.RedisFailover, auth *util2.AuthConfig) (int, error)
func (RedisFailoverChecker) GetRedisesIPs ¶
func (r RedisFailoverChecker) GetRedisesIPs(rf *v1alpha1.RedisFailover, auth *util2.AuthConfig) ([]string, error)
func (RedisFailoverChecker) GetSentinelsIPs ¶
func (r RedisFailoverChecker) GetSentinelsIPs(rf *v1alpha1.RedisFailover) ([]string, error)
type RedisFailoverClient ¶
type RedisFailoverClient interface { EnsureSentinelService(rf *middlev1alpha1.RedisFailover, labels map[string]string, or []metav1.OwnerReference) error EnsureSentinelHeadlessService(rf *middlev1alpha1.RedisFailover, labels map[string]string, ownerRefs []metav1.OwnerReference) error EnsureSentinelConfigMap(rf *middlev1alpha1.RedisFailover, labels map[string]string, ownerRefs []metav1.OwnerReference) error EnsureSentinelProbeConfigMap(rf *middlev1alpha1.RedisFailover, labels map[string]string, ownerRefs []metav1.OwnerReference) error EnsureSentinelDeployment(rf *middlev1alpha1.RedisFailover, labels map[string]string, ownerRefs []metav1.OwnerReference) error EnsureRedisStatefulSet(rf *middlev1alpha1.RedisFailover, labels map[string]string, ownerRefs []metav1.OwnerReference) error EnsureRedisService(rf *middlev1alpha1.RedisFailover, labels map[string]string, ownerRefs []metav1.OwnerReference) error EnsureRedisNodePortService(rf *middlev1alpha1.RedisFailover, labels map[string]string, ownerRefs []metav1.OwnerReference) error EnsureRedisShutdownConfigMap(rf *middlev1alpha1.RedisFailover, labels map[string]string, ownerRefs []metav1.OwnerReference) error EnsureRedisConfigMap(rf *middlev1alpha1.RedisFailover, labels map[string]string, ownerRefs []metav1.OwnerReference) error EnsureNotPresentRedisService(rf *middlev1alpha1.RedisFailover) error EnsurePasswordSecrets(rf *middlev1alpha1.RedisFailover, labels map[string]string, ownerRefs []metav1.OwnerReference) error }
type RedisFailoverHeal ¶
type RedisFailoverHeal interface { MakeMaster(ip string, auth *util2.AuthConfig) error SetOldestAsMaster(rf *middlev1alpha1.RedisFailover, auth *util2.AuthConfig) error SetMasterOnAll(masterIP string, rf *middlev1alpha1.RedisFailover, auth *util2.AuthConfig) error NewSentinelMonitor(ip string, monitor string, rf *middlev1alpha1.RedisFailover, auth *util2.AuthConfig) error RestoreSentinel(ip string, auth *util2.AuthConfig) error SetSentinelCustomConfig(ip string, rf *middlev1alpha1.RedisFailover, auth *util2.AuthConfig) error SetRedisCustomConfig(ip string, rf *middlev1alpha1.RedisFailover, auth *util2.AuthConfig) error }
type RedisFailoverHealer ¶
type RedisFailoverHealer struct { K8SService k8s.Services Logger logr.Logger StatusWriter client.StatusWriter Record record.EventRecorder RedisClient redis.Client }
func NewRedisFailoverHealer ¶
func NewRedisFailoverHealer(k8SService k8s.Services, log logr.Logger, status client.StatusWriter, record record.EventRecorder, rc redis.Client) *RedisFailoverHealer
func (RedisFailoverHealer) MakeMaster ¶
func (r RedisFailoverHealer) MakeMaster(ip string, auth *util2.AuthConfig) error
func (RedisFailoverHealer) NewSentinelMonitor ¶
func (r RedisFailoverHealer) NewSentinelMonitor(ip string, monitor string, rf *middlev1alpha1.RedisFailover, auth *util2.AuthConfig) error
func (RedisFailoverHealer) RestoreSentinel ¶
func (r RedisFailoverHealer) RestoreSentinel(ip string, auth *util2.AuthConfig) error
func (RedisFailoverHealer) SetMasterOnAll ¶
func (r RedisFailoverHealer) SetMasterOnAll(masterIP string, rf *middlev1alpha1.RedisFailover, auth *util2.AuthConfig) error
func (RedisFailoverHealer) SetOldestAsMaster ¶
func (r RedisFailoverHealer) SetOldestAsMaster(rf *middlev1alpha1.RedisFailover, auth *util2.AuthConfig) error
func (RedisFailoverHealer) SetRedisCustomConfig ¶
func (r RedisFailoverHealer) SetRedisCustomConfig(ip string, rf *middlev1alpha1.RedisFailover, auth *util2.AuthConfig) error
func (RedisFailoverHealer) SetSentinelCustomConfig ¶
func (r RedisFailoverHealer) SetSentinelCustomConfig(ip string, rf *middlev1alpha1.RedisFailover, auth *util2.AuthConfig) error
type RedisFailoverKubeClient ¶
type RedisFailoverKubeClient struct { K8SService k8s.Services Logger logr.Logger StatusWriter client.StatusWriter Record record.EventRecorder }
func NewRedisFailoverKubeClient ¶
func NewRedisFailoverKubeClient(k8SService k8s.Services, log logr.Logger, status client.StatusWriter, record record.EventRecorder) *RedisFailoverKubeClient
func (RedisFailoverKubeClient) EnsureNotPresentRedisService ¶
func (r RedisFailoverKubeClient) EnsureNotPresentRedisService(rf *middlev1alpha1.RedisFailover) error
func (RedisFailoverKubeClient) EnsurePasswordSecrets ¶
func (r RedisFailoverKubeClient) EnsurePasswordSecrets(rf *middlev1alpha1.RedisFailover, labels map[string]string, ownerRefs []metav1.OwnerReference) error
func (RedisFailoverKubeClient) EnsureRedisConfigMap ¶
func (r RedisFailoverKubeClient) EnsureRedisConfigMap(rf *middlev1alpha1.RedisFailover, labels map[string]string, ownerRefs []metav1.OwnerReference) error
func (RedisFailoverKubeClient) EnsureRedisNodePortService ¶
func (r RedisFailoverKubeClient) EnsureRedisNodePortService(rf *middlev1alpha1.RedisFailover, labels map[string]string, ownerRefs []metav1.OwnerReference) error
func (RedisFailoverKubeClient) EnsureRedisService ¶
func (r RedisFailoverKubeClient) EnsureRedisService(rf *middlev1alpha1.RedisFailover, labels map[string]string, ownerRefs []metav1.OwnerReference) error
func (RedisFailoverKubeClient) EnsureRedisShutdownConfigMap ¶
func (r RedisFailoverKubeClient) EnsureRedisShutdownConfigMap(rf *middlev1alpha1.RedisFailover, labels map[string]string, ownerRefs []metav1.OwnerReference) error
func (RedisFailoverKubeClient) EnsureRedisStatefulSet ¶
func (r RedisFailoverKubeClient) EnsureRedisStatefulSet(rf *middlev1alpha1.RedisFailover, labels map[string]string, ownerRefs []metav1.OwnerReference) error
func (RedisFailoverKubeClient) EnsureSentinelConfigMap ¶
func (r RedisFailoverKubeClient) EnsureSentinelConfigMap(rf *middlev1alpha1.RedisFailover, labels map[string]string, ownerRefs []metav1.OwnerReference) error
func (RedisFailoverKubeClient) EnsureSentinelDeployment ¶
func (r RedisFailoverKubeClient) EnsureSentinelDeployment(rf *middlev1alpha1.RedisFailover, labels map[string]string, ownerRefs []metav1.OwnerReference) error
func (RedisFailoverKubeClient) EnsureSentinelHeadlessService ¶
func (r RedisFailoverKubeClient) EnsureSentinelHeadlessService(rf *middlev1alpha1.RedisFailover, labels map[string]string, ownerRefs []metav1.OwnerReference) error
func (RedisFailoverKubeClient) EnsureSentinelProbeConfigMap ¶
func (r RedisFailoverKubeClient) EnsureSentinelProbeConfigMap(rf *middlev1alpha1.RedisFailover, labels map[string]string, ownerRefs []metav1.OwnerReference) error
func (RedisFailoverKubeClient) EnsureSentinelService ¶
func (r RedisFailoverKubeClient) EnsureSentinelService(rf *middlev1alpha1.RedisFailover, labels map[string]string, ownerRefs []metav1.OwnerReference) error
Click to show internal directories.
Click to hide internal directories.