sqlitestore

package
v1.2.1 Latest Latest
Warning

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

Go to latest
Published: Nov 13, 2026 License: MIT Imports: 15 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package sqlitestore provides the server's transactional durable key store.

Index

Constants

This section is empty.

Variables

View Source
var ErrCorrupt = errors.New("SQLite database is corrupt")

ErrCorrupt identifies verified invalid database contents, not lock, permission or schema-version failures. Runtimes may isolate the affected project.

Functions

This section is empty.

Types

type Store

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

func Open

func Open(directory, filename string) (_ *Store, err error)

Open owns its directory handle until Close. Database and journal files stay in that directory; a changed directory/file identity fails closed.

func (*Store) Batch

func (s *Store) Batch(puts map[string][]byte, deletes []string) error

Batch publishes all records in one transaction, including the pinned-root snapshot path. A failed statement or durable snapshot leaves every key old.

func (*Store) Close

func (s *Store) Close() error

func (*Store) Delete

func (s *Store) Delete(key string) error

func (*Store) Get

func (s *Store) Get(key string) ([]byte, error)

func (*Store) Initialize

func (s *Store) Initialize(records map[string][]byte) error

Initialize imports legacy records and the completion marker in one commit. Once committed, even an empty records table never imports legacy data again.

func (*Store) Initialized

func (s *Store) Initialized() (bool, error)

func (*Store) List

func (s *Store) List() (map[string][]byte, error)

func (*Store) Put

func (s *Store) Put(key string, payload []byte) error

Jump to

Keyboard shortcuts

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