Versions in this module Expand all Collapse all v0 v0.8.1 Feb 6, 2017 Changes in this version type Config + BroadcastTimeout time.Duration + BroadcastTimeoutRaw string v0.8.0 Sep 14, 2016 Changes in this version + const DefaultBindPort + const MaxIPCVersion + const MinIPCVersion + func LevelFilter() *logutils.LevelFilter + func MarshalTags(tags map[string]string) []string + func NewLogWriter(buf int) *logWriter + func UnmarshalTags(tags []string) (map[string]string, error) + func ValidateLevelFilter(minLevel logutils.LogLevel, filter *logutils.LevelFilter) bool + type Agent struct + func Create(agentConf *Config, conf *serf.Config, logOutput io.Writer) (*Agent, error) + func (a *Agent) DeregisterEventHandler(eh EventHandler) + func (a *Agent) ForceLeave(node string) error + func (a *Agent) InstallKey(key string) (*serf.KeyResponse, error) + func (a *Agent) Join(addrs []string, replay bool) (n int, err error) + func (a *Agent) Leave() error + func (a *Agent) ListKeys() (*serf.KeyResponse, error) + func (a *Agent) Query(name string, payload []byte, params *serf.QueryParam) (*serf.QueryResponse, error) + func (a *Agent) RegisterEventHandler(eh EventHandler) + func (a *Agent) RemoveKey(key string) (*serf.KeyResponse, error) + func (a *Agent) Serf() *serf.Serf + func (a *Agent) SerfConfig() *serf.Config + func (a *Agent) SetTags(tags map[string]string) error + func (a *Agent) Shutdown() error + func (a *Agent) ShutdownCh() <-chan struct{} + func (a *Agent) Start() error + func (a *Agent) Stats() map[string]map[string]string + func (a *Agent) UseKey(key string) (*serf.KeyResponse, error) + func (a *Agent) UserEvent(name string, payload []byte, coalesce bool) error + type AgentIPC struct + func NewAgentIPC(agent *Agent, authKey string, listener net.Listener, logOutput io.Writer, ...) *AgentIPC + func (i *AgentIPC) Shutdown() + type AgentMDNS struct + func NewAgentMDNS(agent *Agent, logOutput io.Writer, replay bool, node, discover string, ...) (*AgentMDNS, error) + type AppendSliceValue []string + func (s *AppendSliceValue) Set(value string) error + func (s *AppendSliceValue) String() string + type Command struct + ShutdownCh <-chan struct{} + Ui cli.Ui + func (c *Command) Help() string + func (c *Command) Run(args []string) int + func (c *Command) Synopsis() string + type Config struct + AdvertiseAddr string + BindAddr string + DisableCoordinates bool + DisableNameResolution bool + Discover string + EnableSyslog bool + EncryptKey string + EventHandlers []string + Interface string + KeyringFile string + LeaveOnTerm bool + LogLevel string + NodeName string + Profile string + Protocol int + QueryResponseSizeLimit int + QuerySizeLimit int + RPCAddr string + RPCAuthKey string + ReconnectInterval time.Duration + ReconnectIntervalRaw string + ReconnectTimeout time.Duration + ReconnectTimeoutRaw string + RejoinAfterLeave bool + ReplayOnJoin bool + RetryInterval time.Duration + RetryIntervalRaw string + RetryJoin []string + RetryMaxAttempts int + Role string + SkipLeaveOnInt bool + SnapshotPath string + StartJoin []string + StatsdAddr string + StatsiteAddr string + SyslogFacility string + Tags map[string]string + TagsFile string + TombstoneTimeout time.Duration + TombstoneTimeoutRaw string + func DecodeConfig(r io.Reader) (*Config, error) + func DefaultConfig() *Config + func MergeConfig(a, b *Config) *Config + func ReadConfigPaths(paths []string) (*Config, error) + func (c *Config) AddrParts(address string) (string, int, error) + func (c *Config) EncryptBytes() ([]byte, error) + func (c *Config) EventScripts() []EventScript + func (c *Config) NetworkInterface() (*net.Interface, error) + type EventFilter struct + Event string + Name string + func ParseEventFilter(v string) []EventFilter + func (s *EventFilter) Invoke(e serf.Event) bool + func (s *EventFilter) Valid() bool + type EventHandler interface + HandleEvent func(serf.Event) + type EventScript struct + Script string + func ParseEventScript(v string) []EventScript + func (s *EventScript) String() string + type GatedWriter struct + Writer io.Writer + func (w *GatedWriter) Flush() + func (w *GatedWriter) Write(p []byte) (n int, err error) + type IPCClient struct + func (c *IPCClient) RegisterQuery(q *serf.Query) uint64 + func (c *IPCClient) Send(header *responseHeader, obj interface{}) error + func (c *IPCClient) String() string + type LogHandler interface + HandleLog func(string) + type Member struct + Addr net.IP + DelegateCur uint8 + DelegateMax uint8 + DelegateMin uint8 + Name string + Port uint16 + ProtocolCur uint8 + ProtocolMax uint8 + ProtocolMin uint8 + Status string + Tags map[string]string + type MockEventHandler struct + Events []serf.Event + func (h *MockEventHandler) HandleEvent(e serf.Event) + type MockQueryHandler struct + Queries []*serf.Query + Response []byte + func (h *MockQueryHandler) HandleEvent(e serf.Event) + type ScriptEventHandler struct + Logger *log.Logger + Scripts []EventScript + SelfFunc func() serf.Member + func (h *ScriptEventHandler) HandleEvent(e serf.Event) + func (h *ScriptEventHandler) UpdateScripts(scripts []EventScript) + type SyslogWrapper struct + func (s *SyslogWrapper) Write(p []byte) (int, error)