zstore

package
v0.0.0-...-3903214 Latest Latest
Warning

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

Go to latest
Published: Apr 6, 2021 License: Apache-2.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	GrpcConnectionCount  = 4
	GrpcKeepAliveTime    = 10
	GrpcKeepAliveTimeout = 3
)

Functions

This section is empty.

Types

type Driver

type Driver struct {
}

func (Driver) Open

func (d Driver) Open(path string) (kv.Storage, error)

type KvPair

type KvPair struct {
	Key   []byte
	Value []byte
	Err   error
}

type KvPairs

type KvPairs struct {
	Keys [][]byte
	Vals [][]byte
	Err  error
}

type Scanner

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

func NewScanner

func NewScanner(rawkv *tikv.RawKVClient, startKey []byte, endKey []byte, batchSize int, reverse bool) (*Scanner, error)

func (*Scanner) Close

func (s *Scanner) Close()

Close close iterator.

func (*Scanner) Key

func (s *Scanner) Key() kv.Key

Key return key.

func (*Scanner) Next

func (s *Scanner) Next() error

Next return next element.

func (*Scanner) Valid

func (s *Scanner) Valid() bool

Valid return valid.

func (*Scanner) Value

func (s *Scanner) Value() []byte

Value return value.

type ZStore

type ZStore struct {
	tikv.Storage
	// contains filtered or unexported fields
}

ZStore xxxxx

func (*ZStore) Begin

func (s *ZStore) Begin() (kv.Transaction, error)

Begin transaction

func (*ZStore) BeginWithRawKV

func (s *ZStore) BeginWithRawKV(startTS uint64) (kv.Transaction, error)

func (*ZStore) BeginWithStartTS

func (s *ZStore) BeginWithStartTS(startTS uint64) (kv.Transaction, error)

BeginWithStartTS begins transaction with startTS.

func (*ZStore) CheckRegionInScattering

func (s *ZStore) CheckRegionInScattering(regionID uint64) (bool, error)

func (*ZStore) Close

func (s *ZStore) Close() error

Close store

func (*ZStore) Describe

func (s *ZStore) Describe() string

Describe returns of brief introduction of the storage

func (*ZStore) EtcdAddrs

func (s *ZStore) EtcdAddrs() []string

func (*ZStore) GetRawClient

func (s *ZStore) GetRawClient() *tikv.RawKVClient

func (*ZStore) Name

func (s *ZStore) Name() string

Name gets the name of the storage engine

func (*ZStore) SplitRegions

func (s *ZStore) SplitRegions(ctx context.Context, splitKey [][]byte, scatter bool) (regionID []uint64, err error)

func (*ZStore) StartGCWorker

func (s *ZStore) StartGCWorker() error

func (*ZStore) TLSConfig

func (s *ZStore) TLSConfig() *tls.Config

func (*ZStore) WaitScatterRegionFinish

func (s *ZStore) WaitScatterRegionFinish(ctx context.Context, regionID uint64, backOff int) error

Jump to

Keyboard shortcuts

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