schema

package
v1.1.0-alpha-8 Latest Latest
Warning

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

Go to latest
Published: Sep 28, 2017 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
const (
	OpSet    = 1
	OpDelete = 2
)

Block operation

View Source
const HandshakeRequest_TypeID = 0xe0d4e6d68fa24ac0

HandshakeRequest_TypeID is the unique identifier for the type HandshakeRequest.

View Source
const HandshakeResponse_TypeID = 0xee959a7d96c96641

HandshakeResponse_TypeID is the unique identifier for the type HandshakeResponse.

View Source
const TlogAggregation_TypeID = 0xe46ab5b4b619e094

TlogAggregation_TypeID is the unique identifier for the type TlogAggregation.

View Source
const TlogBlock_TypeID = 0x8cf178de3c82d431

TlogBlock_TypeID is the unique identifier for the type TlogBlock.

View Source
const TlogClientMessage_TypeID = 0xc8407b23fdf6d1a2

TlogClientMessage_TypeID is the unique identifier for the type TlogClientMessage.

View Source
const TlogResponse_TypeID = 0x98d11ae1c78a24d9

TlogResponse_TypeID is the unique identifier for the type TlogResponse.

Variables

This section is empty.

Functions

func CopyBlock

func CopyBlock(dst, src *TlogBlock) error

CopyBlock copies content of block 'src' to 'dst'

func RawServerHandshakeLen

func RawServerHandshakeLen() int

RawServerHandshakeLen returns length of raw Handshake packet

func RawTlogRespLen

func RawTlogRespLen(numSeq int) int

RawTlogRespLen returns length of raw TlogResponse packet

Types

type HandshakeRequest

type HandshakeRequest struct{ capnp.Struct }

func NewHandshakeRequest

func NewHandshakeRequest(s *capnp.Segment) (HandshakeRequest, error)

func NewRootHandshakeRequest

func NewRootHandshakeRequest(s *capnp.Segment) (HandshakeRequest, error)

func ReadRootHandshakeRequest

func ReadRootHandshakeRequest(msg *capnp.Message) (HandshakeRequest, error)

func (HandshakeRequest) FirstSequence

func (s HandshakeRequest) FirstSequence() uint64

func (HandshakeRequest) HasVdiskID

func (s HandshakeRequest) HasVdiskID() bool

func (HandshakeRequest) ResetFirstSequence

func (s HandshakeRequest) ResetFirstSequence() bool

func (HandshakeRequest) SetFirstSequence

func (s HandshakeRequest) SetFirstSequence(v uint64)

func (HandshakeRequest) SetResetFirstSequence

func (s HandshakeRequest) SetResetFirstSequence(v bool)

func (HandshakeRequest) SetVdiskID

func (s HandshakeRequest) SetVdiskID(v string) error

func (HandshakeRequest) SetVersion

func (s HandshakeRequest) SetVersion(v uint32)

func (HandshakeRequest) String

func (s HandshakeRequest) String() string

func (HandshakeRequest) VdiskID

func (s HandshakeRequest) VdiskID() (string, error)

func (HandshakeRequest) VdiskIDBytes

func (s HandshakeRequest) VdiskIDBytes() ([]byte, error)

func (HandshakeRequest) Version

func (s HandshakeRequest) Version() uint32

type HandshakeRequest_List

type HandshakeRequest_List struct{ capnp.List }

HandshakeRequest_List is a list of HandshakeRequest.

func NewHandshakeRequest_List

func NewHandshakeRequest_List(s *capnp.Segment, sz int32) (HandshakeRequest_List, error)

NewHandshakeRequest creates a new list of HandshakeRequest.

func (HandshakeRequest_List) At

func (HandshakeRequest_List) Set

func (HandshakeRequest_List) String

func (s HandshakeRequest_List) String() string

type HandshakeRequest_Promise

type HandshakeRequest_Promise struct{ *capnp.Pipeline }

HandshakeRequest_Promise is a wrapper for a HandshakeRequest promised by a client call.

func (HandshakeRequest_Promise) Struct

type HandshakeResponse

type HandshakeResponse struct{ capnp.Struct }

func NewHandshakeResponse

func NewHandshakeResponse(s *capnp.Segment) (HandshakeResponse, error)

func NewRootHandshakeResponse

func NewRootHandshakeResponse(s *capnp.Segment) (HandshakeResponse, error)

func ReadRootHandshakeResponse

func ReadRootHandshakeResponse(msg *capnp.Message) (HandshakeResponse, error)

func (HandshakeResponse) SetStatus

func (s HandshakeResponse) SetStatus(v int8)

func (HandshakeResponse) SetVersion

func (s HandshakeResponse) SetVersion(v uint32)

func (HandshakeResponse) Status

func (s HandshakeResponse) Status() int8

func (HandshakeResponse) String

func (s HandshakeResponse) String() string

func (HandshakeResponse) Version

func (s HandshakeResponse) Version() uint32

type HandshakeResponse_List

type HandshakeResponse_List struct{ capnp.List }

HandshakeResponse_List is a list of HandshakeResponse.

func NewHandshakeResponse_List

func NewHandshakeResponse_List(s *capnp.Segment, sz int32) (HandshakeResponse_List, error)

NewHandshakeResponse creates a new list of HandshakeResponse.

func (HandshakeResponse_List) At

func (HandshakeResponse_List) Set

func (HandshakeResponse_List) String

func (s HandshakeResponse_List) String() string

type HandshakeResponse_Promise

type HandshakeResponse_Promise struct{ *capnp.Pipeline }

HandshakeResponse_Promise is a wrapper for a HandshakeResponse promised by a client call.

func (HandshakeResponse_Promise) Struct

type TlogAggregation

type TlogAggregation struct{ capnp.Struct }

func NewRootTlogAggregation

func NewRootTlogAggregation(s *capnp.Segment) (TlogAggregation, error)

func NewTlogAggregation

func NewTlogAggregation(s *capnp.Segment) (TlogAggregation, error)

func ReadRootTlogAggregation

func ReadRootTlogAggregation(msg *capnp.Message) (TlogAggregation, error)

func (TlogAggregation) Blocks

func (s TlogAggregation) Blocks() (TlogBlock_List, error)

func (TlogAggregation) HasBlocks

func (s TlogAggregation) HasBlocks() bool

func (TlogAggregation) HasName

func (s TlogAggregation) HasName() bool

func (TlogAggregation) HasPrev

func (s TlogAggregation) HasPrev() bool

func (TlogAggregation) HasVdiskID

func (s TlogAggregation) HasVdiskID() bool

func (TlogAggregation) Name

func (s TlogAggregation) Name() (string, error)

func (TlogAggregation) NameBytes

func (s TlogAggregation) NameBytes() ([]byte, error)

func (TlogAggregation) NewBlocks

func (s TlogAggregation) NewBlocks(n int32) (TlogBlock_List, error)

NewBlocks sets the blocks field to a newly allocated TlogBlock_List, preferring placement in s's segment.

func (TlogAggregation) Prev

func (s TlogAggregation) Prev() ([]byte, error)

func (TlogAggregation) SetBlocks

func (s TlogAggregation) SetBlocks(v TlogBlock_List) error

func (TlogAggregation) SetName

func (s TlogAggregation) SetName(v string) error

func (TlogAggregation) SetPrev

func (s TlogAggregation) SetPrev(v []byte) error

func (TlogAggregation) SetSize

func (s TlogAggregation) SetSize(v uint64)

func (TlogAggregation) SetTimestamp

func (s TlogAggregation) SetTimestamp(v int64)

func (TlogAggregation) SetVdiskID

func (s TlogAggregation) SetVdiskID(v string) error

func (TlogAggregation) Size

func (s TlogAggregation) Size() uint64

func (TlogAggregation) String

func (s TlogAggregation) String() string

func (TlogAggregation) Timestamp

func (s TlogAggregation) Timestamp() int64

func (TlogAggregation) VdiskID

func (s TlogAggregation) VdiskID() (string, error)

func (TlogAggregation) VdiskIDBytes

func (s TlogAggregation) VdiskIDBytes() ([]byte, error)

type TlogAggregation_List

type TlogAggregation_List struct{ capnp.List }

TlogAggregation_List is a list of TlogAggregation.

func NewTlogAggregation_List

func NewTlogAggregation_List(s *capnp.Segment, sz int32) (TlogAggregation_List, error)

NewTlogAggregation creates a new list of TlogAggregation.

func (TlogAggregation_List) At

func (TlogAggregation_List) Set

func (TlogAggregation_List) String

func (s TlogAggregation_List) String() string

type TlogAggregation_Promise

type TlogAggregation_Promise struct{ *capnp.Pipeline }

TlogAggregation_Promise is a wrapper for a TlogAggregation promised by a client call.

func (TlogAggregation_Promise) Struct

type TlogBlock

type TlogBlock struct{ capnp.Struct }

func NewRootTlogBlock

func NewRootTlogBlock(s *capnp.Segment) (TlogBlock, error)

func NewTlogBlock

func NewTlogBlock(s *capnp.Segment) (TlogBlock, error)

func ReadRootTlogBlock

func ReadRootTlogBlock(msg *capnp.Message) (TlogBlock, error)

func (TlogBlock) Data

func (s TlogBlock) Data() ([]byte, error)

func (TlogBlock) HasData

func (s TlogBlock) HasData() bool

func (TlogBlock) HasHash

func (s TlogBlock) HasHash() bool

func (TlogBlock) Hash

func (s TlogBlock) Hash() ([]byte, error)

func (TlogBlock) Index

func (s TlogBlock) Index() int64

func (TlogBlock) Operation

func (s TlogBlock) Operation() uint8

func (TlogBlock) Sequence

func (s TlogBlock) Sequence() uint64

func (TlogBlock) SetData

func (s TlogBlock) SetData(v []byte) error

func (TlogBlock) SetHash

func (s TlogBlock) SetHash(v []byte) error

func (TlogBlock) SetIndex

func (s TlogBlock) SetIndex(v int64)

func (TlogBlock) SetOperation

func (s TlogBlock) SetOperation(v uint8)

func (TlogBlock) SetSequence

func (s TlogBlock) SetSequence(v uint64)

func (TlogBlock) SetTimestamp

func (s TlogBlock) SetTimestamp(v int64)

func (TlogBlock) String

func (s TlogBlock) String() string

func (TlogBlock) Timestamp

func (s TlogBlock) Timestamp() int64

type TlogBlock_List

type TlogBlock_List struct{ capnp.List }

TlogBlock_List is a list of TlogBlock.

func NewTlogBlock_List

func NewTlogBlock_List(s *capnp.Segment, sz int32) (TlogBlock_List, error)

NewTlogBlock creates a new list of TlogBlock.

func (TlogBlock_List) At

func (s TlogBlock_List) At(i int) TlogBlock

func (TlogBlock_List) Set

func (s TlogBlock_List) Set(i int, v TlogBlock) error

func (TlogBlock_List) String

func (s TlogBlock_List) String() string

type TlogBlock_Promise

type TlogBlock_Promise struct{ *capnp.Pipeline }

TlogBlock_Promise is a wrapper for a TlogBlock promised by a client call.

func (TlogBlock_Promise) Struct

func (p TlogBlock_Promise) Struct() (TlogBlock, error)

type TlogClientMessage

type TlogClientMessage struct{ capnp.Struct }

func NewRootTlogClientMessage

func NewRootTlogClientMessage(s *capnp.Segment) (TlogClientMessage, error)

func NewTlogClientMessage

func NewTlogClientMessage(s *capnp.Segment) (TlogClientMessage, error)

func ReadRootTlogClientMessage

func ReadRootTlogClientMessage(msg *capnp.Message) (TlogClientMessage, error)

func (TlogClientMessage) Block

func (s TlogClientMessage) Block() (TlogBlock, error)

func (TlogClientMessage) ForceFlushAtSeq

func (s TlogClientMessage) ForceFlushAtSeq() uint64

func (TlogClientMessage) HasBlock

func (s TlogClientMessage) HasBlock() bool

func (TlogClientMessage) NewBlock

func (s TlogClientMessage) NewBlock() (TlogBlock, error)

NewBlock sets the block field to a newly allocated TlogBlock struct, preferring placement in s's segment.

func (TlogClientMessage) SetBlock

func (s TlogClientMessage) SetBlock(v TlogBlock) error

func (TlogClientMessage) SetForceFlushAtSeq

func (s TlogClientMessage) SetForceFlushAtSeq(v uint64)

func (TlogClientMessage) SetWaitNBDSlaveSync

func (s TlogClientMessage) SetWaitNBDSlaveSync()

func (TlogClientMessage) String

func (s TlogClientMessage) String() string

func (TlogClientMessage) Which

type TlogClientMessage_List

type TlogClientMessage_List struct{ capnp.List }

TlogClientMessage_List is a list of TlogClientMessage.

func NewTlogClientMessage_List

func NewTlogClientMessage_List(s *capnp.Segment, sz int32) (TlogClientMessage_List, error)

NewTlogClientMessage creates a new list of TlogClientMessage.

func (TlogClientMessage_List) At

func (TlogClientMessage_List) Set

func (TlogClientMessage_List) String

func (s TlogClientMessage_List) String() string

type TlogClientMessage_Promise

type TlogClientMessage_Promise struct{ *capnp.Pipeline }

TlogClientMessage_Promise is a wrapper for a TlogClientMessage promised by a client call.

func (TlogClientMessage_Promise) Block

func (TlogClientMessage_Promise) Struct

type TlogClientMessage_Which

type TlogClientMessage_Which uint16
const (
	TlogClientMessage_Which_block            TlogClientMessage_Which = 0
	TlogClientMessage_Which_forceFlushAtSeq  TlogClientMessage_Which = 1
	TlogClientMessage_Which_waitNBDSlaveSync TlogClientMessage_Which = 2
)

func (TlogClientMessage_Which) String

func (w TlogClientMessage_Which) String() string

type TlogResponse

type TlogResponse struct{ capnp.Struct }

func NewRootTlogResponse

func NewRootTlogResponse(s *capnp.Segment) (TlogResponse, error)

func NewTlogResponse

func NewTlogResponse(s *capnp.Segment) (TlogResponse, error)

func ReadRootTlogResponse

func ReadRootTlogResponse(msg *capnp.Message) (TlogResponse, error)

func (TlogResponse) HasSequences

func (s TlogResponse) HasSequences() bool

func (TlogResponse) NewSequences

func (s TlogResponse) NewSequences(n int32) (capnp.UInt64List, error)

NewSequences sets the sequences field to a newly allocated capnp.UInt64List, preferring placement in s's segment.

func (TlogResponse) Sequences

func (s TlogResponse) Sequences() (capnp.UInt64List, error)

func (TlogResponse) SetSequences

func (s TlogResponse) SetSequences(v capnp.UInt64List) error

func (TlogResponse) SetStatus

func (s TlogResponse) SetStatus(v int8)

func (TlogResponse) Status

func (s TlogResponse) Status() int8

func (TlogResponse) String

func (s TlogResponse) String() string

type TlogResponse_List

type TlogResponse_List struct{ capnp.List }

TlogResponse_List is a list of TlogResponse.

func NewTlogResponse_List

func NewTlogResponse_List(s *capnp.Segment, sz int32) (TlogResponse_List, error)

NewTlogResponse creates a new list of TlogResponse.

func (TlogResponse_List) At

func (TlogResponse_List) Set

func (TlogResponse_List) String

func (s TlogResponse_List) String() string

type TlogResponse_Promise

type TlogResponse_Promise struct{ *capnp.Pipeline }

TlogResponse_Promise is a wrapper for a TlogResponse promised by a client call.

func (TlogResponse_Promise) Struct

func (p TlogResponse_Promise) Struct() (TlogResponse, error)

Jump to

Keyboard shortcuts

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