bindings

package
v0.0.0-...-73bd818 Latest Latest
Warning

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

Go to latest
Published: Feb 9, 2023 License: Apache-2.0 Imports: 18 Imported by: 0

Documentation

Index

Constants

View Source
const MAX_ATTEMPTS = 3
View Source
const TIMEOUT = 3 * time.Second
View Source
const TRUE = uint8(1)

Variables

This section is empty.

Functions

func Call

func Call(cli *rpc.Client, method string, args interface{}, reply interface{}) error

func Dial

func Dial(addr string, connect bool) net.Conn

Types

type Parameters

type Parameters struct {
	Leader int
	// contains filtered or unexported fields
}

func NewParameters

func NewParameters(masterAddr string, masterPort int, verbose bool, leaderless bool, fast bool, localReads bool) *Parameters

func (*Parameters) Connect

func (b *Parameters) Connect() error

func (*Parameters) Disconnect

func (b *Parameters) Disconnect()

func (*Parameters) FindClosestReplica

func (b *Parameters) FindClosestReplica(replyRL *masterproto.GetReplicaListReply) error

func (*Parameters) MasterDial

func (b *Parameters) MasterDial() *rpc.Client

func (*Parameters) Read

func (b *Parameters) Read(key int64) []byte

func (*Parameters) Scan

func (b *Parameters) Scan(key int64, count int64) []byte

func (*Parameters) Stats

func (b *Parameters) Stats() string

func (*Parameters) Write

func (b *Parameters) Write(key int64, value []byte)

not idempotent in case of a failure

Jump to

Keyboard shortcuts

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