Versions in this module Expand all Collapse all v1 v1.1.21 Jul 5, 2021 Changes in this version + var ErrIsQueueClosed = errors.New("ErrIsQueueClosed") + var ErrQueueChannelFull = errors.New("ErrQueueChannelFull") + var ErrQueueTimeout = errors.New("ErrQueueTimeout") + func DisableLog() + type Client interface + Close func() + CloseQueue func() (*types.Reply, error) + FreeMessage func(msg ...*Message) + GetConfig func() *types.TuringchainConfig + NewMessage func(topic string, ty int64, data interface{}) (msg *Message) + Recv func() chan *Message + Reply func(msg *Message) + Send func(msg *Message, waitReply bool) (err error) + SendTimeout func(msg *Message, waitReply bool, timeout time.Duration) (err error) + Sub func(topic string) + Wait func(msg *Message) (*Message, error) + WaitTimeout func(msg *Message, timeout time.Duration) (*Message, error) + type Message struct + Data interface{} + ID int64 + Topic string + Ty int64 + func NewMessage(id int64, topic string, ty int64, data interface{}) (msg *Message) + func NewMessageCallback(id int64, topic string, ty int64, data interface{}, ...) (msg *Message) + func (msg *Message) Err() error + func (msg *Message) GetData() interface{} + func (msg *Message) Reply(replyMsg *Message) + func (msg *Message) ReplyErr(title string, err error) + func (msg *Message) String() string + type Module interface + Close func() + SetQueueClient func(client Client) + Wait func() + type Queue interface + Client func() Client + Close func() + GetConfig func() *types.TuringchainConfig + Name func() string + SetConfig func(cfg *types.TuringchainConfig) + Start func() + func New(name string) Queue