Documentation ¶
Index ¶
- Variables
- func ListenForPatternMulti(hosts []string, pattern []string, onFinish func(bool), timeout time.Duration, ...)
- func Subscribe(host string, messages chan<- []string, done <-chan bool, keepTrying bool, ...) error
- func SubscribeMultiOld(hosts []string, messages chan<- *HostMessage, done chan bool, topics ...string) error
- func SubscribeRunAndWaitForPattern(hosts []string, topic string, timeout time.Duration, ...) error
- type HostMessage
- type Subscription
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrorWaitPatternTimeout = errors.New("timeout in SubscribeRunAndWaitForPattern")
Functions ¶
func ListenForPatternMulti ¶
func ListenForPatternMulti(hosts []string, pattern []string, onFinish func(bool), timeout time.Duration, w ...io.Writer)
noinspection GoUnhandledErrorResult
func SubscribeMultiOld ¶
func SubscribeMultiOld(hosts []string, messages chan<- *HostMessage, done chan bool, topics ...string) error
Types ¶
type HostMessage ¶
type Subscription ¶
type Subscription struct {
// contains filtered or unexported fields
}
func SubscribeMulti ¶
func SubscribeMulti(hosts []string, topics string, quorum ...int) (*Subscription, error)
func (*Subscription) Close ¶
func (subs *Subscription) Close()
func (*Subscription) WaitForPattern ¶
func (*Subscription) WaitForPatterns ¶
func (subs *Subscription) WaitForPatterns(patterns [][]string, timeout time.Duration, quorum ...int) bool
WaitForPatterns waits until subscription receives all patterns from quorum of hosts
Click to show internal directories.
Click to hide internal directories.