Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Loss ¶
type Loss struct {
Count int
}
Loss is a special value used in place of a contiguous set of lost messages
type PubSub ¶
type PubSub struct {
// contains filtered or unexported fields
}
PubSub…
func (*PubSub) Close ¶
func (ps *PubSub) Close()
Close terminates, paradoxically, the infinite update stream.
func (*PubSub) Publish ¶
func (ps *PubSub) Publish(v interface{})
Publish appends a value onto the infinite update stream.
func (*PubSub) Subscribe ¶
func (ps *PubSub) Subscribe() *Subscription
Subscribe creates a new subscription object, whose interface embodies reading from an infinite stream. New subscription can join at any time. The input stream of each individual subscription is pre-loaded with a sequence of values summarizing all past history. Subsequent values come from the pubish stream. Subscriptions are abandoned on garbage-collection.
type Subscription ¶
type Subscription struct {
// contains filtered or unexported fields
}
Subscription is the user's interface to consuming messages from a topic.
func (*Subscription) Consume ¶
func (s *Subscription) Consume() (interface{}, bool)
func (*Subscription) Peek ¶
func (s *Subscription) Peek() Stat
func (*Subscription) Scrub ¶
func (s *Subscription) Scrub()
func (*Subscription) X ¶
func (s *Subscription) X() circuit.X
type Summarize ¶
type Summarize func() []interface{}
Summarize returns a list of items meant to summarize the history of the stream so far for subscribers joining now.
type YSubscription ¶
YSubscription is a client wrapper for cross-interface to *Subscription
func (YSubscription) Consume ¶
func (y YSubscription) Consume() (interface{}, bool)
func (YSubscription) IsDone ¶
func (y YSubscription) IsDone() bool
func (YSubscription) Peek ¶
func (y YSubscription) Peek() Stat
func (YSubscription) Scrub ¶
func (y YSubscription) Scrub()