message

package
v1.33.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 19, 2022 License: Unlicense Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Marshal

func Marshal(message *Message) ([]byte, error)

Marshal a message.

func Unmarshal

func Unmarshal(data []byte, message *Message) error

Unmarshal a message.

Types

type Headers

type Headers map[string]string

Headers of message.

type Message

type Message struct {
	Headers Headers `msgpack:"headers"`
	Body    []byte  `msgpack:"body"`

	*nsq.Message `msgpack:"-"`
}

Message for NSQ.

func New

func New(body []byte) *Message

New message.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL