Documentation ¶
Index ¶
- type BaseStore
- type Module
- type Node
- func (n *Node) Create() error
- func (n *Node) Created() bool
- func (n *Node) DistKeyCacheGetter() fileservice.KeyRouterFactory[query.CacheKey]
- func (n *Node) Join(existing []string) error
- func (n *Node) Joined() bool
- func (n *Node) Leave(timeout time.Duration) error
- func (n *Node) NumMembers() int
- func (n *Node) SetCacheServerAddrFn(f func() string)
- func (n *Node) SetJoined()
- func (n *Node) SetListenAddrFn(f func() string)
- func (n *Node) SetServiceAddrFn(f func() string)
- func (n *Node) StatsKeyRouter() client.KeyRouter[pb.StatsInfoKey]
- func (n *Node) UnsetJoined()
- type Option
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BaseStore ¶ added in v1.2.0
type BaseStore[K comparable] struct { // contains filtered or unexported fields }
func (*BaseStore[K]) AddItem ¶ added in v1.2.0
func (s *BaseStore[K]) AddItem(item gossip.CommonItem)
AddItem implements the client.KeyRouter interface.
type Module ¶ added in v1.2.0
type Module interface { // Data returns all data that need to send to other nodes. // The second return value is the left size of the limit size. Data(limit int) ([]gossip.GossipData, int) }
type Node ¶
type Node struct {
// contains filtered or unexported fields
}
func (*Node) DistKeyCacheGetter ¶
func (n *Node) DistKeyCacheGetter() fileservice.KeyRouterFactory[query.CacheKey]
func (*Node) NumMembers ¶
func (*Node) SetCacheServerAddrFn ¶
func (*Node) SetListenAddrFn ¶
func (*Node) SetServiceAddrFn ¶
func (*Node) StatsKeyRouter ¶ added in v1.2.0
func (n *Node) StatsKeyRouter() client.KeyRouter[pb.StatsInfoKey]
func (*Node) UnsetJoined ¶
func (n *Node) UnsetJoined()
type Option ¶
type Option func(*Node)
func WithCacheServerAddrFn ¶
func WithListenAddrFn ¶
func WithServiceAddrFn ¶
Click to show internal directories.
Click to hide internal directories.