sql

package
v0.0.0-...-c9bb2cb Latest Latest
Warning

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

Go to latest
Published: Oct 5, 2021 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Storage

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

func New

func New(ctx context.Context, db *sql.DB) (*Storage, error)

func (*Storage) Delete

func (s *Storage) Delete(ctx context.Context, keyspace, key string) error

func (*Storage) Get

func (s *Storage) Get(ctx context.Context, keyspace, key string, into proto.Message) (version int64, err error)

func (*Storage) List

func (s *Storage) List(ctx context.Context, keyspace string) (keys []string, err error)

func (*Storage) Put

func (s *Storage) Put(ctx context.Context, keyspace, key string, version int64, obj proto.Message) (newVersion int64, err error)

func (*Storage) PutWithExpiry

func (s *Storage) PutWithExpiry(ctx context.Context, keyspace, key string, version int64, obj proto.Message, expires time.Time) (newVersion int64, err error)

Jump to

Keyboard shortcuts

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