Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewTiPubsub ¶
func NewTiPubsub(txn kv.Transaction) *tiPubsub
Types ¶
type Option ¶
type Option func(r *pubsubOps)
func SetTikvStore ¶
func SetTikvStore(txn kv.Transaction) Option
type PubsubOps ¶
type PubsubOps interface { Publish(ns, topic string, message *pbMessage.Message) ([]byte, error) Last(ns, topic string) ([]byte, error) Range(ns, topic string, pos []byte, count int64) ([]byte, []*pbMessage.Message, bool, error) Drop(ns, topic string) error SetRetain(ns, topic string, message *pbMessage.Message) error DeleteRetain(ns, topic string) error Retain(ns, topic string) (*pbMessage.Message, error) Subscribe(ns, topic, client string, online bool) error Unsubscribe(ns, topic, client string) error HasSubscriber(ns, topic string) (bool, error) ListOfflineSubscribers(ns, topic string) ([]string, error) ListOnlineSubscribers(ns, topic string) ([]string, error) }
func NewPubsubOps ¶
Click to show internal directories.
Click to hide internal directories.