proto

package
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: Aug 31, 2024 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AckResp

type AckResp struct {
	Ack string `json:"ack" msg:"ack"`
}

func (*AckResp) DecodeMsg

func (z *AckResp) DecodeMsg(dc *msgp.Reader) (err error)

DecodeMsg implements msgp.Decodable

func (AckResp) EncodeMsg

func (z AckResp) EncodeMsg(en *msgp.Writer) (err error)

EncodeMsg implements msgp.Encodable

func (AckResp) MarshalMsg

func (z AckResp) MarshalMsg(b []byte) (o []byte, err error)

MarshalMsg implements msgp.Marshaler

func (AckResp) Msgsize

func (z AckResp) Msgsize() (s int)

Msgsize returns an upper bound estimate of the number of bytes occupied by the serialized message

func (*AckResp) UnmarshalMsg

func (z *AckResp) UnmarshalMsg(bts []byte) (o []byte, err error)

UnmarshalMsg implements msgp.Unmarshaler

type Entry

type Entry struct {
	Time   int64       `msg:"time"`
	Record interface{} `msg:"record"`
}

func (*Entry) DecodeMsg

func (z *Entry) DecodeMsg(dc *msgp.Reader) (err error)

DecodeMsg implements msgp.Decodable

func (Entry) EncodeMsg

func (z Entry) EncodeMsg(en *msgp.Writer) (err error)

EncodeMsg implements msgp.Encodable

func (Entry) MarshalMsg

func (z Entry) MarshalMsg(b []byte) (o []byte, err error)

MarshalMsg implements msgp.Marshaler

func (Entry) Msgsize

func (z Entry) Msgsize() (s int)

Msgsize returns an upper bound estimate of the number of bytes occupied by the serialized message

func (*Entry) UnmarshalMsg

func (z *Entry) UnmarshalMsg(bts []byte) (o []byte, err error)

UnmarshalMsg implements msgp.Unmarshaler

type EventTime

type EventTime time.Time

EventTime is an extension to the serialized time value. It builds in support for sub-second (nanosecond) precision in serialized timestamps.

You can find the full specification for the msgpack message payload here: https://github.com/fluent/fluentd/wiki/Forward-Protocol-Specification-v1.

You can find more information on msgpack extension types here: https://github.com/tinylib/msgp/wiki/Using-Extensions.

func (*EventTime) ExtensionType

func (t *EventTime) ExtensionType() int8

func (*EventTime) Len

func (t *EventTime) Len() int

func (*EventTime) MarshalBinaryTo

func (t *EventTime) MarshalBinaryTo(b []byte) error

func (*EventTime) UnmarshalBinary

func (t *EventTime) UnmarshalBinary(b []byte) error

Although decoding messages is not officially supported by this library, UnmarshalBinary is implemented for testing and general completeness.

type Forward

type Forward struct {
	Tag     string  `msg:"tag"`
	Entries []Entry `msg:"entries"`
	Option  map[string]string
}

func (*Forward) DecodeMsg

func (z *Forward) DecodeMsg(dc *msgp.Reader) (err error)

DecodeMsg implements msgp.Decodable

func (*Forward) EncodeMsg

func (z *Forward) EncodeMsg(en *msgp.Writer) (err error)

EncodeMsg implements msgp.Encodable

func (*Forward) MarshalMsg

func (z *Forward) MarshalMsg(b []byte) (o []byte, err error)

MarshalMsg implements msgp.Marshaler

func (*Forward) Msgsize

func (z *Forward) Msgsize() (s int)

Msgsize returns an upper bound estimate of the number of bytes occupied by the serialized message

func (*Forward) UnmarshalMsg

func (z *Forward) UnmarshalMsg(bts []byte) (o []byte, err error)

UnmarshalMsg implements msgp.Unmarshaler

type Message

type Message struct {
	Tag    string      `msg:"tag"`
	Time   int64       `msg:"time"`
	Record interface{} `msg:"record"`
	Option map[string]string
}

func (*Message) DecodeMsg

func (z *Message) DecodeMsg(dc *msgp.Reader) (err error)

DecodeMsg implements msgp.Decodable

func (*Message) EncodeMsg

func (z *Message) EncodeMsg(en *msgp.Writer) (err error)

EncodeMsg implements msgp.Encodable

func (*Message) MarshalMsg

func (z *Message) MarshalMsg(b []byte) (o []byte, err error)

MarshalMsg implements msgp.Marshaler

func (*Message) Msgsize

func (z *Message) Msgsize() (s int)

Msgsize returns an upper bound estimate of the number of bytes occupied by the serialized message

func (*Message) UnmarshalMsg

func (z *Message) UnmarshalMsg(bts []byte) (o []byte, err error)

UnmarshalMsg implements msgp.Unmarshaler

type MessageExt

type MessageExt struct {
	Tag    string      `msg:"tag"`
	Time   EventTime   `msg:"time,extension"`
	Record interface{} `msg:"record"`
	Option map[string]string
}

func (*MessageExt) DecodeMsg

func (z *MessageExt) DecodeMsg(dc *msgp.Reader) (err error)

DecodeMsg implements msgp.Decodable

func (*MessageExt) EncodeMsg

func (z *MessageExt) EncodeMsg(en *msgp.Writer) (err error)

EncodeMsg implements msgp.Encodable

func (*MessageExt) MarshalMsg

func (z *MessageExt) MarshalMsg(b []byte) (o []byte, err error)

MarshalMsg implements msgp.Marshaler

func (*MessageExt) Msgsize

func (z *MessageExt) Msgsize() (s int)

Msgsize returns an upper bound estimate of the number of bytes occupied by the serialized message

func (*MessageExt) UnmarshalMsg

func (z *MessageExt) UnmarshalMsg(bts []byte) (o []byte, err error)

UnmarshalMsg implements msgp.Unmarshaler

type TestMessage

type TestMessage struct {
	Foo  string `msg:"foo" json:"foo,omitempty"`
	Hoge string `msg:"hoge" json:"hoge,omitempty"`
}

func (*TestMessage) DecodeMsg

func (z *TestMessage) DecodeMsg(dc *msgp.Reader) (err error)

DecodeMsg implements msgp.Decodable

func (TestMessage) EncodeMsg

func (z TestMessage) EncodeMsg(en *msgp.Writer) (err error)

EncodeMsg implements msgp.Encodable

func (TestMessage) MarshalMsg

func (z TestMessage) MarshalMsg(b []byte) (o []byte, err error)

MarshalMsg implements msgp.Marshaler

func (TestMessage) Msgsize

func (z TestMessage) Msgsize() (s int)

Msgsize returns an upper bound estimate of the number of bytes occupied by the serialized message

func (*TestMessage) UnmarshalMsg

func (z *TestMessage) UnmarshalMsg(bts []byte) (o []byte, err error)

UnmarshalMsg implements msgp.Unmarshaler

Jump to

Keyboard shortcuts

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