Documentation ¶
Index ¶
- Variables
- type Cluster
- func (c *Cluster) Addr() string
- func (c *Cluster) CurrentLevel() int
- func (c *Cluster) IsOwner(addr string) bool
- func (c *Cluster) Join(peers []string) error
- func (c *Cluster) Lookup(index h3.H3Index) (h3geodist.Cell, bool)
- func (c *Cluster) Run() (err error)
- func (c *Cluster) Shutdown() (err error)
- type Options
- type VNode
- type VNodeKind
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrAlreadyRunning = errors.New("cluster: cluster already running") ErrNotRunning = errors.New("cluster: cluster is not running") ErrBootstrapTimeout = errors.New("cluster: bootstrap timeout") ErrNodeNotFound = errors.New("cluster: node not found") ErrNilOptions = errors.New("cluster: options cannot be nil") )
Functions ¶
This section is empty.
Types ¶
type Cluster ¶
type Cluster struct {
// contains filtered or unexported fields
}
func (*Cluster) CurrentLevel ¶
type Options ¶
type Options struct { GRPCServerAddr string `yaml:"grpc_server_addr"` GRPCServerPort int `yaml:"grpc_server_port"` GRPCClientIdleTimeout time.Duration `yaml:"grpc_client_idle_timeout"` GRPCClientMaxLifeDuration time.Duration `yaml:"grpc_client_max_life_duration"` GRPCClientInitPoolCount int `yaml:"grpc_client_pool_init_count"` GRPCClientPoolCapacity int `yaml:"grpc_client_pool_capacity"` H3DistLevel int `yaml:"h3dist_level"` H3DistVNodes uint64 `yaml:"h3dist_vnodes"` H3DistReplicas int `yaml:"h3dist_replicas"` JoinRetryInterval time.Duration `yaml:"join_retry_interval"` MaxJoinAttempts int `yaml:"max_join_attempts"` Peers []string `yaml:"peers"` BootstrapTimeout time.Duration `yaml:"bootstrap_timeout"` CoordinatorPushInterval time.Duration `yaml:"coordinator_update_push_interval"` MemberlistDefaultConf string `yaml:"memberlist_default_conf"` BindAddr string `yaml:"memberlist_bind_addr"` BindPort int `yaml:"memberlist_bind_port"` AdvertiseAddr *string `yaml:"memberlist_advertise_addr"` AdvertisePort *int `yaml:"memberlist_advertise_port"` EnableCompression *bool `yaml:"memberlist_enable_compression"` IndirectChecks *int `yaml:"memberlist_indirect_checks"` RetransmitMult *int `yaml:"memberlist_retransmit_mult"` SuspicionMult *int `yaml:"memberlist_suspicion_mult"` TCPTimeout *time.Duration `yaml:"memberlist_tcp_timeout"` PushPullInterval *time.Duration `yaml:"memberlist_push_pull_interval"` ProbeTimeout *time.Duration `yaml:"memberlist_probe_timeout"` ProbeInterval *time.Duration `yaml:"memberlist_probe_interval"` GossipInterval *time.Duration `yaml:"memberlist_gossip_interval"` GossipToTheDeadTime *time.Duration `yaml:"memberlist_gossip_dead_time"` SuspicionMaxTimeoutMult *int `yaml:"memberlist_suspicion_max_timeout_mult"` AwarenessMaxMultiplier *int `yaml:"memberlist_awareness_max_multiplier"` GossipNodes *int `yaml:"memberlist_gossip_nodes"` GossipVerifyIncoming *bool `yaml:"memberlist_gossip_verify_incoming"` GossipVerifyOutgoing *bool `yaml:"memberlist_gossip_verify_outgoing"` DNSConfigPath *string `yaml:"memberlist_dns_config_path"` HandoffQueueDepth *int `yaml:"memberlist_handoff_queue_depth"` UDPBufferSize *int `yaml:"memberlist_udp_buffer_size"` GRPCClientDialOpts []grpc.DialOption `yaml:"-"` }
Click to show internal directories.
Click to hide internal directories.