store

package
v0.0.0-...-503c688 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IsKeyspaceNotExistError

func IsKeyspaceNotExistError(err error) bool

IsKeyspaceNotExistError returns true the error is caused by keyspace not exists.

func IsNotBootstrappedError

func IsNotBootstrappedError(err error) bool

IsNotBootstrappedError returns true if the error is pd not bootstrapped error.

func New

func New(path string) (kv.Storage, error)

New creates a kv Storage with path.

The path must be a URL format 'engine://path?params' like the one for session.Open() but with the dbname cut off. Examples:

goleveldb://relative/path
boltdb:///absolute/path

The engine should be registered before creating storage.

func Register

func Register(name string, driver kv.Driver) error

Register registers a kv storage with unique name and its associated Driver.

Types

This section is empty.

Jump to

Keyboard shortcuts

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