Documentation ¶
Index ¶
Constants ¶
View Source
const MemberLabel = "member-type"
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CRMemberlistStore ¶
type CRMemberlistStore struct {
// contains filtered or unexported fields
}
func NewCRMemberlistStore ¶
func NewCRMemberlistStore(dynamicClient dynamic.Interface, coordinatorNamespace string, memberlistCustomResource string) *CRMemberlistStore
func (*CRMemberlistStore) GetMemberlist ¶
func (s *CRMemberlistStore) GetMemberlist(ctx context.Context) (return_memberlist Memberlist, resourceVersion string, err error)
func (*CRMemberlistStore) UpdateMemberlist ¶
func (s *CRMemberlistStore) UpdateMemberlist(ctx context.Context, memberlist Memberlist, resourceVersion string) error
type IMemberlistManager ¶
type IMemberlistStore ¶
type IMemberlistStore interface { GetMemberlist(ctx context.Context) (_ Memberlist, resourceVersion string, err error) UpdateMemberlist(ctx context.Context, _ Memberlist, resourceVersion string) error }
type IWatcher ¶
type IWatcher interface { common.Component RegisterCallback(callback NodeWatcherCallback) ListReadyMembers() (Memberlist, error) }
type KubernetesWatcher ¶
type KubernetesWatcher struct {
// contains filtered or unexported fields
}
func NewKubernetesWatcher ¶
func NewKubernetesWatcher(clientset kubernetes.Interface, coordinator_namespace string, pod_label string, resyncPeriod time.Duration) *KubernetesWatcher
func (*KubernetesWatcher) ListReadyMembers ¶
func (w *KubernetesWatcher) ListReadyMembers() (Memberlist, error)
func (*KubernetesWatcher) RegisterCallback ¶
func (w *KubernetesWatcher) RegisterCallback(callback NodeWatcherCallback)
Register a queue
func (*KubernetesWatcher) Start ¶
func (w *KubernetesWatcher) Start() error
func (*KubernetesWatcher) Stop ¶
func (w *KubernetesWatcher) Stop() error
Stop the kubernetes watcher
type Member ¶
type Member struct {
// contains filtered or unexported fields
}
func (Member) MarshalLogObject ¶
func (m Member) MarshalLogObject(enc zapcore.ObjectEncoder) error
MarshalLogObject implements the zapcore.ObjectMarshaler interface
type Memberlist ¶
type Memberlist []Member
func (Memberlist) MarshalLogArray ¶
func (ml Memberlist) MarshalLogArray(enc zapcore.ArrayEncoder) error
MarshalLogArray implements the zapcore.ArrayMarshaler interface
type MemberlistManager ¶
type MemberlistManager struct {
// contains filtered or unexported fields
}
func NewMemberlistManager ¶
func NewMemberlistManager(nodeWatcher IWatcher, memberlistStore IMemberlistStore) *MemberlistManager
func (*MemberlistManager) SetReconcileCount ¶
func (m *MemberlistManager) SetReconcileCount(count uint)
func (*MemberlistManager) SetReconcileInterval ¶
func (m *MemberlistManager) SetReconcileInterval(interval time.Duration)
func (*MemberlistManager) Start ¶
func (m *MemberlistManager) Start() error
func (*MemberlistManager) Stop ¶
func (m *MemberlistManager) Stop() error
type NodeWatcherCallback ¶
type NodeWatcherCallback func(node_ip string)
Click to show internal directories.
Click to hide internal directories.