mutcaskds

package
v0.1.2 Latest Latest
Warning

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

Go to latest
Published: Dec 15, 2022 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	Path            string `json:"path"`
	CaskNum         uint32 `json:"cask_num"`
	HintBootReadNum int    `json:"hint_boot_read_num"`
	Migrate         bool   `json:"migrate"`
}

func LoadConfig

func LoadConfig(path string) (*Config, error)

type MutcaskDS

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

func NewMutcaskDS

func NewMutcaskDS(ctx context.Context, cfg *Config) (*MutcaskDS, error)

func (*MutcaskDS) Close

func (dis *MutcaskDS) Close() error

func (*MutcaskDS) Delete

func (dis *MutcaskDS) Delete(k ds.Key) error

func (*MutcaskDS) Get

func (dis *MutcaskDS) Get(k ds.Key) ([]byte, error)

func (*MutcaskDS) GetSize

func (dis *MutcaskDS) GetSize(k ds.Key) (int, error)

func (*MutcaskDS) Has

func (dis *MutcaskDS) Has(k ds.Key) (bool, error)

func (*MutcaskDS) Put

func (dis *MutcaskDS) Put(k ds.Key, value []byte) error

func (*MutcaskDS) Query

func (dis *MutcaskDS) Query(q dsq.Query) (dsq.Results, error)

func (*MutcaskDS) Sync

func (dis *MutcaskDS) Sync(ds.Key) error

Jump to

Keyboard shortcuts

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