encoding

package
v0.9.1 Latest Latest
Warning

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

Go to latest
Published: Jul 30, 2025 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrNotAProtoMessage = errors.New("encoding: not a proto message")

Functions

func CtxIsSnappy

func CtxIsSnappy(ctx context.Context) bool

func CtxWithSnappy

func CtxWithSnappy(ctx context.Context) context.Context

func WrapHandler

func WrapHandler(h drpc.Handler) drpc.Handler

Types

type ConnUnblocked

type ConnUnblocked interface {
	drpc.Conn
	Unblocked() <-chan struct{}
}

func WrapConnEncoding

func WrapConnEncoding(conn ConnUnblocked, useSnappy bool) ConnUnblocked

WrapConnEncoding wraps the drpc connection and replaces an encoding

type ProtoMessageGettable

type ProtoMessageGettable interface {
	ProtoMessage() (protobuf.Message, error)
}

type ProtoMessageSettable

type ProtoMessageSettable interface {
	ProtoMessageGettable
	SetProtoMessage(protobuf.Message) error
}

Jump to

Keyboard shortcuts

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