Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewTree ¶
func NewTree(base string) (Provider, []types.RetainObject, []DynamicValue, error)
NewTree allocate systree provider
Types ¶
type BytesMetric ¶
BytesMetric bytes metric
type ClientConnectStatus ¶
type ClientConnectStatus struct { Address string Username string Timestamp string CleanSession bool SessionPresent bool Protocol message.ProtocolVersion ConnAckCode message.ReasonCode }
ClientConnectStatus is argument to client connected state
type Clients ¶
type Clients interface { Connected(string, *ClientConnectStatus) Disconnected(string, message.ReasonCode, bool) }
Clients Statistic of sessions
type DynamicValue ¶
type DynamicValue interface { Topic() string // Retained used by topics provider to get retained message when there is new subscription to given topic Retained() *message.PublishMessage // Publish used by systree update routine to publish new value when on periodic basis Publish() *message.PublishMessage }
DynamicValue interface describes states of the dynamic value
type Metric ¶
type Metric interface { Bytes() BytesMetric Packets() PacketsMetric }
Metric is wrap around all of metrics
type PacketsMetric ¶
type PacketsMetric interface { Sent(t message.PacketType) Received(t message.PacketType) }
PacketsMetric packets metric
type Provider ¶
type Provider interface { SetCallbacks(types.TopicMessenger) Metric() Metric Topics() TopicsStat Subscriptions() SubscriptionsStat Clients() Clients Sessions() SessionsStat }
Provider systree provider
type SessionsStat ¶
type SessionsStat interface { Created() Removed() }
SessionsStat Statistic of sessions
type SubscriptionsStat ¶
type SubscriptionsStat interface { Subscribed() UnSubscribed() }
SubscriptionsStat statistic of subscriptions
Click to show internal directories.
Click to hide internal directories.