raid

package
v0.0.0-...-aac5273 Latest Latest
Warning

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

Go to latest
Published: Sep 29, 2017 License: BSD-2-Clause Imports: 8 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ReadBufferSize = 4 * 1024
)

Variables

This section is empty.

Functions

func NewEtagContext

func NewEtagContext(ctx context.Context) context.Context

Types

type Client

type Client struct {
	// contains filtered or unexported fields
}

func NewClient

func NewClient(mode, addr string) (*Client, error)

func (*Client) Conn

func (c *Client) Conn() net.Conn

func (*Client) Request

func (c *Client) Request(msg *Message) (chan *Message, error)

func (*Client) Send

func (c *Client) Send(msg *Message) error

type Etag

type Etag string

func EtagFromContext

func EtagFromContext(ctx context.Context) (Etag, bool)

func NewEtag

func NewEtag() Etag

func (Etag) String

func (e Etag) String() string

type Message

type Message struct {
	Header map[string]interface{} `json:"header"`
	Body   interface{}            `json:"body"`
}

func (*Message) Action

func (m *Message) Action() string

func (*Message) Etag

func (m *Message) Etag() Etag

Jump to

Keyboard shortcuts

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