Documentation ¶
Index ¶
- type MessageQueue
- func (mq *MessageQueue) AllocateMessage(cmd any, payloads *common.Payloads, header *common.Header) *internal.Message
- func (mq *MessageQueue) Flush()
- func (mq *MessageQueue) Messages() []*internal.Message
- func (mq *MessageQueue) PushCommand(cmd any, payloads *common.Payloads, header *common.Header)
- func (mq *MessageQueue) PushError(id uint64, failure *failure.Failure)
- func (mq *MessageQueue) PushResponse(id uint64, payloads *common.Payloads)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type MessageQueue ¶
type MessageQueue struct { SeqID func() uint64 // contains filtered or unexported fields }
func NewMessageQueue ¶
func NewMessageQueue(sedID func() uint64) *MessageQueue
func (*MessageQueue) AllocateMessage ¶
func (mq *MessageQueue) AllocateMessage(cmd any, payloads *common.Payloads, header *common.Header) *internal.Message
AllocateMessage .. TODO(rustatian) allocate??? -> to sync.Pool Remove this method if flavor of sync.Pool with internal.Message
func (*MessageQueue) Flush ¶
func (mq *MessageQueue) Flush()
func (*MessageQueue) Messages ¶
func (mq *MessageQueue) Messages() []*internal.Message
func (*MessageQueue) PushCommand ¶
func (mq *MessageQueue) PushCommand(cmd any, payloads *common.Payloads, header *common.Header)
func (*MessageQueue) PushError ¶
func (mq *MessageQueue) PushError(id uint64, failure *failure.Failure)
func (*MessageQueue) PushResponse ¶
func (mq *MessageQueue) PushResponse(id uint64, payloads *common.Payloads)
Click to show internal directories.
Click to hide internal directories.