Documentation ¶
Index ¶
- func LoadRedisNodes(ctx context.Context, client kubernetes.ClientSet, sts *appv1.StatefulSet, ...) ([]redis.RedisNode, error)
- func NewRedisNode(ctx context.Context, client kubernetes.ClientSet, sts *appv1.StatefulSet, ...) (redis.RedisNode, error)
- type RedisNode
- func (n *RedisNode) ClusterInfo() rediscli.RedisClusterInfo
- func (n *RedisNode) Config() map[string]string
- func (n *RedisNode) ConfigedMasterIP() string
- func (n *RedisNode) ConfigedMasterPort() string
- func (n *RedisNode) ContainerStatus() *corev1.ContainerStatus
- func (n *RedisNode) CurrentVersion() redis.RedisVersion
- func (n *RedisNode) DefaultIP() net.IP
- func (n *RedisNode) DefaultInternalIP() net.IP
- func (n *RedisNode) Definition() *corev1.Pod
- func (n *RedisNode) GetPod() *corev1.Pod
- func (n *RedisNode) ID() string
- func (n *RedisNode) IPort() int
- func (n *RedisNode) IPs() []net.IP
- func (n *RedisNode) Index() int
- func (n *RedisNode) Info() rediscli.RedisInfo
- func (n *RedisNode) InternalIPort() int
- func (n *RedisNode) InternalPort() int
- func (n *RedisNode) IsACLApplied() bool
- func (n *RedisNode) IsConnected() bool
- func (n *RedisNode) IsContainerReady() bool
- func (n *RedisNode) IsJoined() bool
- func (n *RedisNode) IsMasterFailed() bool
- func (n *RedisNode) IsMasterLinkUp() bool
- func (n *RedisNode) IsReady() bool
- func (n *RedisNode) IsTerminating() bool
- func (n *RedisNode) MasterID() string
- func (n *RedisNode) NodeIP() net.IP
- func (n *RedisNode) Port() int
- func (n *RedisNode) Query(ctx context.Context, cmd string, args ...any) (any, error)
- func (n *RedisNode) Refresh(ctx context.Context) (err error)
- func (n *RedisNode) ReplicaOf(ctx context.Context, ip, port string) error
- func (n *RedisNode) Role() core.RedisRole
- func (n *RedisNode) SetACLUser(ctx context.Context, username string, passwords []string, rules string) (interface{}, error)
- func (n *RedisNode) Setup(ctx context.Context, margs ...[]any) (err error)
- func (n *RedisNode) Slots() *slot.Slots
- func (n *RedisNode) Status() corev1.PodPhase
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func LoadRedisNodes ¶
func LoadRedisNodes(ctx context.Context, client kubernetes.ClientSet, sts *appv1.StatefulSet, newUser *user.User, logger logr.Logger) ([]redis.RedisNode, error)
LoadRedisNodes
Types ¶
type RedisNode ¶
func (*RedisNode) ClusterInfo ¶
func (n *RedisNode) ClusterInfo() rediscli.RedisClusterInfo
func (*RedisNode) ConfigedMasterIP ¶
func (*RedisNode) ConfigedMasterPort ¶
func (*RedisNode) ContainerStatus ¶
func (n *RedisNode) ContainerStatus() *corev1.ContainerStatus
ContainerStatus
func (*RedisNode) CurrentVersion ¶
func (n *RedisNode) CurrentVersion() redis.RedisVersion
func (*RedisNode) DefaultInternalIP ¶
func (*RedisNode) Definition ¶
func (*RedisNode) ID ¶
ID get cluster id
TODO: if it's possible generate a const id, use this id as cluster id
func (*RedisNode) InternalIPort ¶
func (*RedisNode) InternalPort ¶
func (*RedisNode) IsACLApplied ¶
func (*RedisNode) IsMasterLinkUp ¶
master_link_status is up
func (*RedisNode) SetACLUser ¶
Click to show internal directories.
Click to hide internal directories.