wire

package
v0.0.0-...-eedcae6 Latest Latest
Warning

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

Go to latest
Published: Nov 20, 2015 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var BarCreateUploadResult_Success_DEFAULT [][]byte
View Source
var BarFetchChunkResult_Success_DEFAULT []byte
View Source
var BarGetManifestsResult_Success_DEFAULT []*Manifest
View Source
var BarGetMissingBlobIdsResult_Success_DEFAULT [][]byte
View Source
var GoUnusedProtection__ int

Functions

This section is empty.

Types

type Bar

type Bar interface {
	GetInfo() (r *ServerInfo, err error)
	// Creates new upload on bard and returns missing chunks.
	//
	//
	// Parameters:
	//  - Id: upload id (UUIDv4)
	//  - Manifests: requested manifests
	//  - Ttl: upload TTL
	CreateUpload(id []byte, manifests []*Manifest, ttl int64) (r [][]byte, err error)
	// Upload BLOB chunk
	//
	//
	// Parameters:
	//  - UploadId: upload id
	//  - ChunkId: chunk id
	//  - Body: Chunk body
	UploadChunk(uploadId []byte, chunkId ID, body []byte) (err error)
	// Mark upload as finished. This action will
	// immediately remove all upload data.
	//
	//
	// Parameters:
	//  - UploadId: Upload id
	FinishUpload(uploadId []byte) (err error)
	// Tag blobs. Untagged blobs will be removed by GC.
	//
	//
	// Parameters:
	//  - Ids
	//  - Tag
	SetTag(ids [][]byte, tag []byte) (err error)
	// Parameters:
	//  - Ids
	//  - Tag
	RemoveTag(ids [][]byte, tag []byte) (err error)
	// Parameters:
	//  - Ids
	GetMissingBlobIds(ids [][]byte) (r [][]byte, err error)
	// Get manifests by their ids
	//
	//
	// Parameters:
	//  - Ids
	GetManifests(ids [][]byte) (r []*Manifest, err error)
	// Fetch chunk from bard
	//
	//
	// Parameters:
	//  - BlobID: Blob ID
	//  - Chunk: Chunk spec
	FetchChunk(blobID ID, chunk *Chunk) (r []byte, err error)
	// Parameters:
	//  - Spec
	UploadSpec(spec *Spec) (err error)
	// Parameters:
	//  - Id
	FetchSpec(id ID) (r *Spec, err error)
}

type BarClient

type BarClient struct {
	Transport       thrift.TTransport
	ProtocolFactory thrift.TProtocolFactory
	InputProtocol   thrift.TProtocol
	OutputProtocol  thrift.TProtocol
	SeqId           int32
}

Wire service

func NewBarClientProtocol

func NewBarClientProtocol(t thrift.TTransport, iprot thrift.TProtocol, oprot thrift.TProtocol) *BarClient

func (*BarClient) CreateUpload

func (p *BarClient) CreateUpload(id []byte, manifests []*Manifest, ttl int64) (r [][]byte, err error)

Creates new upload on bard and returns missing chunks.

Parameters:

  • Id: upload id (UUIDv4)
  • Manifests: requested manifests
  • Ttl: upload TTL

func (*BarClient) FetchChunk

func (p *BarClient) FetchChunk(blobID ID, chunk *Chunk) (r []byte, err error)

Fetch chunk from bard

Parameters:

  • BlobID: Blob ID
  • Chunk: Chunk spec

func (*BarClient) FetchSpec

func (p *BarClient) FetchSpec(id ID) (r *Spec, err error)

Parameters:

  • Id

func (*BarClient) FinishUpload

func (p *BarClient) FinishUpload(uploadId []byte) (err error)

Mark upload as finished. This action will immediately remove all upload data.

Parameters:

  • UploadId: Upload id

func (*BarClient) GetInfo

func (p *BarClient) GetInfo() (r *ServerInfo, err error)

func (*BarClient) GetManifests

func (p *BarClient) GetManifests(ids [][]byte) (r []*Manifest, err error)

Get manifests by their ids

Parameters:

  • Ids

func (*BarClient) GetMissingBlobIds

func (p *BarClient) GetMissingBlobIds(ids [][]byte) (r [][]byte, err error)

Parameters:

  • Ids

func (*BarClient) RemoveTag

func (p *BarClient) RemoveTag(ids [][]byte, tag []byte) (err error)

Parameters:

  • Ids
  • Tag

func (*BarClient) SetTag

func (p *BarClient) SetTag(ids [][]byte, tag []byte) (err error)

Tag blobs. Untagged blobs will be removed by GC.

Parameters:

  • Ids
  • Tag

func (*BarClient) UploadChunk

func (p *BarClient) UploadChunk(uploadId []byte, chunkId ID, body []byte) (err error)

Upload BLOB chunk

Parameters:

  • UploadId: upload id
  • ChunkId: chunk id
  • Body: Chunk body

func (*BarClient) UploadSpec

func (p *BarClient) UploadSpec(spec *Spec) (err error)

Parameters:

  • Spec

type BarCreateUploadArgs

type BarCreateUploadArgs struct {
	Id        []byte      `thrift:"id,1" db:"id" json:"id"`
	Manifests []*Manifest `thrift:"manifests,2" db:"manifests" json:"manifests"`
	Ttl       int64       `thrift:"ttl,3" db:"ttl" json:"ttl"`
}

Attributes:

  • Id: upload id (UUIDv4)
  • Manifests: requested manifests
  • Ttl: upload TTL

func NewBarCreateUploadArgs

func NewBarCreateUploadArgs() *BarCreateUploadArgs

func (*BarCreateUploadArgs) GetId

func (p *BarCreateUploadArgs) GetId() []byte

func (*BarCreateUploadArgs) GetManifests

func (p *BarCreateUploadArgs) GetManifests() []*Manifest

func (*BarCreateUploadArgs) GetTtl

func (p *BarCreateUploadArgs) GetTtl() int64

func (*BarCreateUploadArgs) Read

func (p *BarCreateUploadArgs) Read(iprot thrift.TProtocol) error

func (*BarCreateUploadArgs) ReadField1

func (p *BarCreateUploadArgs) ReadField1(iprot thrift.TProtocol) error

func (*BarCreateUploadArgs) ReadField2

func (p *BarCreateUploadArgs) ReadField2(iprot thrift.TProtocol) error

func (*BarCreateUploadArgs) ReadField3

func (p *BarCreateUploadArgs) ReadField3(iprot thrift.TProtocol) error

func (*BarCreateUploadArgs) String

func (p *BarCreateUploadArgs) String() string

func (*BarCreateUploadArgs) Write

func (p *BarCreateUploadArgs) Write(oprot thrift.TProtocol) error

type BarCreateUploadResult

type BarCreateUploadResult struct {
	Success [][]byte `thrift:"success,0" db:"success" json:"success,omitempty"`
}

Attributes:

  • Success

func NewBarCreateUploadResult

func NewBarCreateUploadResult() *BarCreateUploadResult

func (*BarCreateUploadResult) GetSuccess

func (p *BarCreateUploadResult) GetSuccess() [][]byte

func (*BarCreateUploadResult) IsSetSuccess

func (p *BarCreateUploadResult) IsSetSuccess() bool

func (*BarCreateUploadResult) Read

func (*BarCreateUploadResult) ReadField0

func (p *BarCreateUploadResult) ReadField0(iprot thrift.TProtocol) error

func (*BarCreateUploadResult) String

func (p *BarCreateUploadResult) String() string

func (*BarCreateUploadResult) Write

func (p *BarCreateUploadResult) Write(oprot thrift.TProtocol) error

type BarFetchChunkArgs

type BarFetchChunkArgs struct {
	BlobID ID     `thrift:"blobID,1" db:"blobID" json:"blobID"`
	Chunk  *Chunk `thrift:"chunk,2" db:"chunk" json:"chunk"`
}

Attributes:

  • BlobID: Blob ID
  • Chunk: Chunk spec

func NewBarFetchChunkArgs

func NewBarFetchChunkArgs() *BarFetchChunkArgs

func (*BarFetchChunkArgs) GetBlobID

func (p *BarFetchChunkArgs) GetBlobID() ID

func (*BarFetchChunkArgs) GetChunk

func (p *BarFetchChunkArgs) GetChunk() *Chunk

func (*BarFetchChunkArgs) IsSetChunk

func (p *BarFetchChunkArgs) IsSetChunk() bool

func (*BarFetchChunkArgs) Read

func (p *BarFetchChunkArgs) Read(iprot thrift.TProtocol) error

func (*BarFetchChunkArgs) ReadField1

func (p *BarFetchChunkArgs) ReadField1(iprot thrift.TProtocol) error

func (*BarFetchChunkArgs) ReadField2

func (p *BarFetchChunkArgs) ReadField2(iprot thrift.TProtocol) error

func (*BarFetchChunkArgs) String

func (p *BarFetchChunkArgs) String() string

func (*BarFetchChunkArgs) Write

func (p *BarFetchChunkArgs) Write(oprot thrift.TProtocol) error

type BarFetchChunkResult

type BarFetchChunkResult struct {
	Success []byte `thrift:"success,0" db:"success" json:"success,omitempty"`
}

Attributes:

  • Success

func NewBarFetchChunkResult

func NewBarFetchChunkResult() *BarFetchChunkResult

func (*BarFetchChunkResult) GetSuccess

func (p *BarFetchChunkResult) GetSuccess() []byte

func (*BarFetchChunkResult) IsSetSuccess

func (p *BarFetchChunkResult) IsSetSuccess() bool

func (*BarFetchChunkResult) Read

func (p *BarFetchChunkResult) Read(iprot thrift.TProtocol) error

func (*BarFetchChunkResult) ReadField0

func (p *BarFetchChunkResult) ReadField0(iprot thrift.TProtocol) error

func (*BarFetchChunkResult) String

func (p *BarFetchChunkResult) String() string

func (*BarFetchChunkResult) Write

func (p *BarFetchChunkResult) Write(oprot thrift.TProtocol) error

type BarFetchSpecArgs

type BarFetchSpecArgs struct {
	Id ID `thrift:"id,1" db:"id" json:"id"`
}

Attributes:

  • Id

func NewBarFetchSpecArgs

func NewBarFetchSpecArgs() *BarFetchSpecArgs

func (*BarFetchSpecArgs) GetId

func (p *BarFetchSpecArgs) GetId() ID

func (*BarFetchSpecArgs) Read

func (p *BarFetchSpecArgs) Read(iprot thrift.TProtocol) error

func (*BarFetchSpecArgs) ReadField1

func (p *BarFetchSpecArgs) ReadField1(iprot thrift.TProtocol) error

func (*BarFetchSpecArgs) String

func (p *BarFetchSpecArgs) String() string

func (*BarFetchSpecArgs) Write

func (p *BarFetchSpecArgs) Write(oprot thrift.TProtocol) error

type BarFetchSpecResult

type BarFetchSpecResult struct {
	Success *Spec `thrift:"success,0" db:"success" json:"success,omitempty"`
}

Attributes:

  • Success

func NewBarFetchSpecResult

func NewBarFetchSpecResult() *BarFetchSpecResult

func (*BarFetchSpecResult) GetSuccess

func (p *BarFetchSpecResult) GetSuccess() *Spec

func (*BarFetchSpecResult) IsSetSuccess

func (p *BarFetchSpecResult) IsSetSuccess() bool

func (*BarFetchSpecResult) Read

func (p *BarFetchSpecResult) Read(iprot thrift.TProtocol) error

func (*BarFetchSpecResult) ReadField0

func (p *BarFetchSpecResult) ReadField0(iprot thrift.TProtocol) error

func (*BarFetchSpecResult) String

func (p *BarFetchSpecResult) String() string

func (*BarFetchSpecResult) Write

func (p *BarFetchSpecResult) Write(oprot thrift.TProtocol) error

type BarFinishUploadArgs

type BarFinishUploadArgs struct {
	UploadId []byte `thrift:"uploadId,1" db:"uploadId" json:"uploadId"`
}

Attributes:

  • UploadId: Upload id

func NewBarFinishUploadArgs

func NewBarFinishUploadArgs() *BarFinishUploadArgs

func (*BarFinishUploadArgs) GetUploadId

func (p *BarFinishUploadArgs) GetUploadId() []byte

func (*BarFinishUploadArgs) Read

func (p *BarFinishUploadArgs) Read(iprot thrift.TProtocol) error

func (*BarFinishUploadArgs) ReadField1

func (p *BarFinishUploadArgs) ReadField1(iprot thrift.TProtocol) error

func (*BarFinishUploadArgs) String

func (p *BarFinishUploadArgs) String() string

func (*BarFinishUploadArgs) Write

func (p *BarFinishUploadArgs) Write(oprot thrift.TProtocol) error

type BarFinishUploadResult

type BarFinishUploadResult struct {
}

func NewBarFinishUploadResult

func NewBarFinishUploadResult() *BarFinishUploadResult

func (*BarFinishUploadResult) Read

func (*BarFinishUploadResult) String

func (p *BarFinishUploadResult) String() string

func (*BarFinishUploadResult) Write

func (p *BarFinishUploadResult) Write(oprot thrift.TProtocol) error

type BarGetInfoArgs

type BarGetInfoArgs struct {
}

func NewBarGetInfoArgs

func NewBarGetInfoArgs() *BarGetInfoArgs

func (*BarGetInfoArgs) Read

func (p *BarGetInfoArgs) Read(iprot thrift.TProtocol) error

func (*BarGetInfoArgs) String

func (p *BarGetInfoArgs) String() string

func (*BarGetInfoArgs) Write

func (p *BarGetInfoArgs) Write(oprot thrift.TProtocol) error

type BarGetInfoResult

type BarGetInfoResult struct {
	Success *ServerInfo `thrift:"success,0" db:"success" json:"success,omitempty"`
}

Attributes:

  • Success

func NewBarGetInfoResult

func NewBarGetInfoResult() *BarGetInfoResult

func (*BarGetInfoResult) GetSuccess

func (p *BarGetInfoResult) GetSuccess() *ServerInfo

func (*BarGetInfoResult) IsSetSuccess

func (p *BarGetInfoResult) IsSetSuccess() bool

func (*BarGetInfoResult) Read

func (p *BarGetInfoResult) Read(iprot thrift.TProtocol) error

func (*BarGetInfoResult) ReadField0

func (p *BarGetInfoResult) ReadField0(iprot thrift.TProtocol) error

func (*BarGetInfoResult) String

func (p *BarGetInfoResult) String() string

func (*BarGetInfoResult) Write

func (p *BarGetInfoResult) Write(oprot thrift.TProtocol) error

type BarGetManifestsArgs

type BarGetManifestsArgs struct {
	Ids [][]byte `thrift:"ids,1" db:"ids" json:"ids"`
}

Attributes:

  • Ids

func NewBarGetManifestsArgs

func NewBarGetManifestsArgs() *BarGetManifestsArgs

func (*BarGetManifestsArgs) GetIds

func (p *BarGetManifestsArgs) GetIds() [][]byte

func (*BarGetManifestsArgs) Read

func (p *BarGetManifestsArgs) Read(iprot thrift.TProtocol) error

func (*BarGetManifestsArgs) ReadField1

func (p *BarGetManifestsArgs) ReadField1(iprot thrift.TProtocol) error

func (*BarGetManifestsArgs) String

func (p *BarGetManifestsArgs) String() string

func (*BarGetManifestsArgs) Write

func (p *BarGetManifestsArgs) Write(oprot thrift.TProtocol) error

type BarGetManifestsResult

type BarGetManifestsResult struct {
	Success []*Manifest `thrift:"success,0" db:"success" json:"success,omitempty"`
}

Attributes:

  • Success

func NewBarGetManifestsResult

func NewBarGetManifestsResult() *BarGetManifestsResult

func (*BarGetManifestsResult) GetSuccess

func (p *BarGetManifestsResult) GetSuccess() []*Manifest

func (*BarGetManifestsResult) IsSetSuccess

func (p *BarGetManifestsResult) IsSetSuccess() bool

func (*BarGetManifestsResult) Read

func (*BarGetManifestsResult) ReadField0

func (p *BarGetManifestsResult) ReadField0(iprot thrift.TProtocol) error

func (*BarGetManifestsResult) String

func (p *BarGetManifestsResult) String() string

func (*BarGetManifestsResult) Write

func (p *BarGetManifestsResult) Write(oprot thrift.TProtocol) error

type BarGetMissingBlobIdsArgs

type BarGetMissingBlobIdsArgs struct {
	Ids [][]byte `thrift:"ids,1" db:"ids" json:"ids"`
}

Attributes:

  • Ids

func NewBarGetMissingBlobIdsArgs

func NewBarGetMissingBlobIdsArgs() *BarGetMissingBlobIdsArgs

func (*BarGetMissingBlobIdsArgs) GetIds

func (p *BarGetMissingBlobIdsArgs) GetIds() [][]byte

func (*BarGetMissingBlobIdsArgs) Read

func (*BarGetMissingBlobIdsArgs) ReadField1

func (p *BarGetMissingBlobIdsArgs) ReadField1(iprot thrift.TProtocol) error

func (*BarGetMissingBlobIdsArgs) String

func (p *BarGetMissingBlobIdsArgs) String() string

func (*BarGetMissingBlobIdsArgs) Write

type BarGetMissingBlobIdsResult

type BarGetMissingBlobIdsResult struct {
	Success [][]byte `thrift:"success,0" db:"success" json:"success,omitempty"`
}

Attributes:

  • Success

func NewBarGetMissingBlobIdsResult

func NewBarGetMissingBlobIdsResult() *BarGetMissingBlobIdsResult

func (*BarGetMissingBlobIdsResult) GetSuccess

func (p *BarGetMissingBlobIdsResult) GetSuccess() [][]byte

func (*BarGetMissingBlobIdsResult) IsSetSuccess

func (p *BarGetMissingBlobIdsResult) IsSetSuccess() bool

func (*BarGetMissingBlobIdsResult) Read

func (*BarGetMissingBlobIdsResult) ReadField0

func (p *BarGetMissingBlobIdsResult) ReadField0(iprot thrift.TProtocol) error

func (*BarGetMissingBlobIdsResult) String

func (p *BarGetMissingBlobIdsResult) String() string

func (*BarGetMissingBlobIdsResult) Write

type BarProcessor

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

func NewBarProcessor

func NewBarProcessor(handler Bar) *BarProcessor

func (*BarProcessor) AddToProcessorMap

func (p *BarProcessor) AddToProcessorMap(key string, processor thrift.TProcessorFunction)

func (*BarProcessor) GetProcessorFunction

func (p *BarProcessor) GetProcessorFunction(key string) (processor thrift.TProcessorFunction, ok bool)

func (*BarProcessor) Process

func (p *BarProcessor) Process(iprot, oprot thrift.TProtocol) (success bool, err thrift.TException)

func (*BarProcessor) ProcessorMap

func (p *BarProcessor) ProcessorMap() map[string]thrift.TProcessorFunction

type BarRemoveTagArgs

type BarRemoveTagArgs struct {
	Ids [][]byte `thrift:"ids,1" db:"ids" json:"ids"`
	Tag []byte   `thrift:"tag,2" db:"tag" json:"tag"`
}

Attributes:

  • Ids
  • Tag

func NewBarRemoveTagArgs

func NewBarRemoveTagArgs() *BarRemoveTagArgs

func (*BarRemoveTagArgs) GetIds

func (p *BarRemoveTagArgs) GetIds() [][]byte

func (*BarRemoveTagArgs) GetTag

func (p *BarRemoveTagArgs) GetTag() []byte

func (*BarRemoveTagArgs) Read

func (p *BarRemoveTagArgs) Read(iprot thrift.TProtocol) error

func (*BarRemoveTagArgs) ReadField1

func (p *BarRemoveTagArgs) ReadField1(iprot thrift.TProtocol) error

func (*BarRemoveTagArgs) ReadField2

func (p *BarRemoveTagArgs) ReadField2(iprot thrift.TProtocol) error

func (*BarRemoveTagArgs) String

func (p *BarRemoveTagArgs) String() string

func (*BarRemoveTagArgs) Write

func (p *BarRemoveTagArgs) Write(oprot thrift.TProtocol) error

type BarRemoveTagResult

type BarRemoveTagResult struct {
}

func NewBarRemoveTagResult

func NewBarRemoveTagResult() *BarRemoveTagResult

func (*BarRemoveTagResult) Read

func (p *BarRemoveTagResult) Read(iprot thrift.TProtocol) error

func (*BarRemoveTagResult) String

func (p *BarRemoveTagResult) String() string

func (*BarRemoveTagResult) Write

func (p *BarRemoveTagResult) Write(oprot thrift.TProtocol) error

type BarSetTagArgs

type BarSetTagArgs struct {
	Ids [][]byte `thrift:"ids,1" db:"ids" json:"ids"`
	Tag []byte   `thrift:"tag,2" db:"tag" json:"tag"`
}

Attributes:

  • Ids
  • Tag

func NewBarSetTagArgs

func NewBarSetTagArgs() *BarSetTagArgs

func (*BarSetTagArgs) GetIds

func (p *BarSetTagArgs) GetIds() [][]byte

func (*BarSetTagArgs) GetTag

func (p *BarSetTagArgs) GetTag() []byte

func (*BarSetTagArgs) Read

func (p *BarSetTagArgs) Read(iprot thrift.TProtocol) error

func (*BarSetTagArgs) ReadField1

func (p *BarSetTagArgs) ReadField1(iprot thrift.TProtocol) error

func (*BarSetTagArgs) ReadField2

func (p *BarSetTagArgs) ReadField2(iprot thrift.TProtocol) error

func (*BarSetTagArgs) String

func (p *BarSetTagArgs) String() string

func (*BarSetTagArgs) Write

func (p *BarSetTagArgs) Write(oprot thrift.TProtocol) error

type BarSetTagResult

type BarSetTagResult struct {
}

func NewBarSetTagResult

func NewBarSetTagResult() *BarSetTagResult

func (*BarSetTagResult) Read

func (p *BarSetTagResult) Read(iprot thrift.TProtocol) error

func (*BarSetTagResult) String

func (p *BarSetTagResult) String() string

func (*BarSetTagResult) Write

func (p *BarSetTagResult) Write(oprot thrift.TProtocol) error

type BarUploadChunkArgs

type BarUploadChunkArgs struct {
	UploadId []byte `thrift:"uploadId,1" db:"uploadId" json:"uploadId"`
	ChunkId  ID     `thrift:"chunkId,2" db:"chunkId" json:"chunkId"`
	Body     []byte `thrift:"body,3" db:"body" json:"body"`
}

Attributes:

  • UploadId: upload id
  • ChunkId: chunk id
  • Body: Chunk body

func NewBarUploadChunkArgs

func NewBarUploadChunkArgs() *BarUploadChunkArgs

func (*BarUploadChunkArgs) GetBody

func (p *BarUploadChunkArgs) GetBody() []byte

func (*BarUploadChunkArgs) GetChunkId

func (p *BarUploadChunkArgs) GetChunkId() ID

func (*BarUploadChunkArgs) GetUploadId

func (p *BarUploadChunkArgs) GetUploadId() []byte

func (*BarUploadChunkArgs) Read

func (p *BarUploadChunkArgs) Read(iprot thrift.TProtocol) error

func (*BarUploadChunkArgs) ReadField1

func (p *BarUploadChunkArgs) ReadField1(iprot thrift.TProtocol) error

func (*BarUploadChunkArgs) ReadField2

func (p *BarUploadChunkArgs) ReadField2(iprot thrift.TProtocol) error

func (*BarUploadChunkArgs) ReadField3

func (p *BarUploadChunkArgs) ReadField3(iprot thrift.TProtocol) error

func (*BarUploadChunkArgs) String

func (p *BarUploadChunkArgs) String() string

func (*BarUploadChunkArgs) Write

func (p *BarUploadChunkArgs) Write(oprot thrift.TProtocol) error

type BarUploadChunkResult

type BarUploadChunkResult struct {
}

func NewBarUploadChunkResult

func NewBarUploadChunkResult() *BarUploadChunkResult

func (*BarUploadChunkResult) Read

func (p *BarUploadChunkResult) Read(iprot thrift.TProtocol) error

func (*BarUploadChunkResult) String

func (p *BarUploadChunkResult) String() string

func (*BarUploadChunkResult) Write

func (p *BarUploadChunkResult) Write(oprot thrift.TProtocol) error

type BarUploadSpecArgs

type BarUploadSpecArgs struct {
	Spec *Spec `thrift:"spec,1" db:"spec" json:"spec"`
}

Attributes:

  • Spec

func NewBarUploadSpecArgs

func NewBarUploadSpecArgs() *BarUploadSpecArgs

func (*BarUploadSpecArgs) GetSpec

func (p *BarUploadSpecArgs) GetSpec() *Spec

func (*BarUploadSpecArgs) IsSetSpec

func (p *BarUploadSpecArgs) IsSetSpec() bool

func (*BarUploadSpecArgs) Read

func (p *BarUploadSpecArgs) Read(iprot thrift.TProtocol) error

func (*BarUploadSpecArgs) ReadField1

func (p *BarUploadSpecArgs) ReadField1(iprot thrift.TProtocol) error

func (*BarUploadSpecArgs) String

func (p *BarUploadSpecArgs) String() string

func (*BarUploadSpecArgs) Write

func (p *BarUploadSpecArgs) Write(oprot thrift.TProtocol) error

type BarUploadSpecResult

type BarUploadSpecResult struct {
}

func NewBarUploadSpecResult

func NewBarUploadSpecResult() *BarUploadSpecResult

func (*BarUploadSpecResult) Read

func (p *BarUploadSpecResult) Read(iprot thrift.TProtocol) error

func (*BarUploadSpecResult) String

func (p *BarUploadSpecResult) String() string

func (*BarUploadSpecResult) Write

func (p *BarUploadSpecResult) Write(oprot thrift.TProtocol) error

type Chunk

type Chunk struct {
	Info *DataInfo `thrift:"info,1" db:"info" json:"info"`
	// unused field # 2
	Offset int64 `thrift:"offset,3" db:"offset" json:"offset"`
}

Chunk info

Attributes:

  • Info
  • Offset
var BarFetchChunkArgs_Chunk_DEFAULT *Chunk

func NewChunk

func NewChunk() *Chunk

func (*Chunk) GetInfo

func (p *Chunk) GetInfo() *DataInfo

func (*Chunk) GetOffset

func (p *Chunk) GetOffset() int64

func (*Chunk) IsSetInfo

func (p *Chunk) IsSetInfo() bool

func (*Chunk) Read

func (p *Chunk) Read(iprot thrift.TProtocol) error

func (*Chunk) ReadField1

func (p *Chunk) ReadField1(iprot thrift.TProtocol) error

func (*Chunk) ReadField3

func (p *Chunk) ReadField3(iprot thrift.TProtocol) error

func (*Chunk) String

func (p *Chunk) String() string

func (*Chunk) Write

func (p *Chunk) Write(oprot thrift.TProtocol) error

type DataInfo

type DataInfo struct {
	Id   ID    `thrift:"id,1" db:"id" json:"id"`
	Size int64 `thrift:"size,2" db:"size" json:"size"`
}

Info about data entity

Attributes:

  • Id
  • Size: data size
var Chunk_Info_DEFAULT *DataInfo
var Manifest_Info_DEFAULT *DataInfo

func NewDataInfo

func NewDataInfo() *DataInfo

func (*DataInfo) GetId

func (p *DataInfo) GetId() ID

func (*DataInfo) GetSize

func (p *DataInfo) GetSize() int64

func (*DataInfo) Read

func (p *DataInfo) Read(iprot thrift.TProtocol) error

func (*DataInfo) ReadField1

func (p *DataInfo) ReadField1(iprot thrift.TProtocol) error

func (*DataInfo) ReadField2

func (p *DataInfo) ReadField2(iprot thrift.TProtocol) error

func (*DataInfo) String

func (p *DataInfo) String() string

func (*DataInfo) Write

func (p *DataInfo) Write(oprot thrift.TProtocol) error

type ID

type ID []byte

SHA3-256

func IDPtr

func IDPtr(v ID) *ID

type Manifest

type Manifest struct {
	Info   *DataInfo `thrift:"info,1" db:"info" json:"info"`
	Chunks []*Chunk  `thrift:"chunks,2" db:"chunks" json:"chunks"`
}

Blob manifest.

Attributes:

  • Info
  • Chunks

func NewManifest

func NewManifest() *Manifest

func (*Manifest) GetChunks

func (p *Manifest) GetChunks() []*Chunk

func (*Manifest) GetInfo

func (p *Manifest) GetInfo() *DataInfo

func (*Manifest) IsSetInfo

func (p *Manifest) IsSetInfo() bool

func (*Manifest) Read

func (p *Manifest) Read(iprot thrift.TProtocol) error

func (*Manifest) ReadField1

func (p *Manifest) ReadField1(iprot thrift.TProtocol) error

func (*Manifest) ReadField2

func (p *Manifest) ReadField2(iprot thrift.TProtocol) error

func (*Manifest) String

func (p *Manifest) String() string

func (*Manifest) Write

func (p *Manifest) Write(oprot thrift.TProtocol) error

type ServerInfo

type ServerInfo struct {
	HttpEndpoint string   `thrift:"httpEndpoint,1" db:"httpEndpoint" json:"httpEndpoint"`
	RpcEndpoints []string `thrift:"rpcEndpoints,2" db:"rpcEndpoints" json:"rpcEndpoints"`
	ChunkSize    int64    `thrift:"chunkSize,3" db:"chunkSize" json:"chunkSize"`
	MaxConn      int32    `thrift:"maxConn,4" db:"maxConn" json:"maxConn"`
	BufferSize   int32    `thrift:"bufferSize,5" db:"bufferSize" json:"bufferSize"`
}

Bard server info

Attributes:

  • HttpEndpoint: HTTP endpoint (http://bard.served:3000/v1)
  • RpcEndpoints: Thrift rpc endpoints (tcp://bard.served:3000)
  • ChunkSize: Preferred chunk size.
  • MaxConn: Preferred max connections for client
  • BufferSize: Thrift client buffer size
var BarGetInfoResult_Success_DEFAULT *ServerInfo

func NewServerInfo

func NewServerInfo() *ServerInfo

func (*ServerInfo) GetBufferSize

func (p *ServerInfo) GetBufferSize() int32

func (*ServerInfo) GetChunkSize

func (p *ServerInfo) GetChunkSize() int64

func (*ServerInfo) GetHttpEndpoint

func (p *ServerInfo) GetHttpEndpoint() string

func (*ServerInfo) GetMaxConn

func (p *ServerInfo) GetMaxConn() int32

func (*ServerInfo) GetRpcEndpoints

func (p *ServerInfo) GetRpcEndpoints() []string

func (*ServerInfo) Read

func (p *ServerInfo) Read(iprot thrift.TProtocol) error

func (*ServerInfo) ReadField1

func (p *ServerInfo) ReadField1(iprot thrift.TProtocol) error

func (*ServerInfo) ReadField2

func (p *ServerInfo) ReadField2(iprot thrift.TProtocol) error

func (*ServerInfo) ReadField3

func (p *ServerInfo) ReadField3(iprot thrift.TProtocol) error

func (*ServerInfo) ReadField4

func (p *ServerInfo) ReadField4(iprot thrift.TProtocol) error

func (*ServerInfo) ReadField5

func (p *ServerInfo) ReadField5(iprot thrift.TProtocol) error

func (*ServerInfo) String

func (p *ServerInfo) String() string

func (*ServerInfo) Write

func (p *ServerInfo) Write(oprot thrift.TProtocol) error

type Spec

type Spec struct {
	Id        ID            `thrift:"id,1" db:"id" json:"id"`
	Timestamp int64         `thrift:"timestamp,2" db:"timestamp" json:"timestamp"`
	Blobs     map[string]ID `thrift:"blobs,3" db:"blobs" json:"blobs"`
	Removes   []string      `thrift:"removes,4" db:"removes" json:"removes"`
}

Attributes:

  • Id
  • Timestamp
  • Blobs
  • Removes
var BarFetchSpecResult_Success_DEFAULT *Spec
var BarUploadSpecArgs_Spec_DEFAULT *Spec

func NewSpec

func NewSpec() *Spec

func (*Spec) GetBlobs

func (p *Spec) GetBlobs() map[string]ID

func (*Spec) GetId

func (p *Spec) GetId() ID

func (*Spec) GetRemoves

func (p *Spec) GetRemoves() []string

func (*Spec) GetTimestamp

func (p *Spec) GetTimestamp() int64

func (*Spec) Read

func (p *Spec) Read(iprot thrift.TProtocol) error

func (*Spec) ReadField1

func (p *Spec) ReadField1(iprot thrift.TProtocol) error

func (*Spec) ReadField2

func (p *Spec) ReadField2(iprot thrift.TProtocol) error

func (*Spec) ReadField3

func (p *Spec) ReadField3(iprot thrift.TProtocol) error

func (*Spec) ReadField4

func (p *Spec) ReadField4(iprot thrift.TProtocol) error

func (*Spec) String

func (p *Spec) String() string

func (*Spec) Write

func (p *Spec) Write(oprot thrift.TProtocol) error

Jump to

Keyboard shortcuts

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