mongodb

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Apr 5, 2021 License: GPL-3.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewDB

func NewDB(addr string, credential *options.Credential) (*kv.DB, error)

Types

type MTxnStore

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

func (MTxnStore) Close

func (m MTxnStore) Close() error

func (MTxnStore) GetTxnRecord

func (m MTxnStore) GetTxnRecord(ctx context.Context, version uint64) (value types.DBValue, err error)

func (MTxnStore) RemoveTxnRecord

func (m MTxnStore) RemoveTxnRecord(ctx context.Context, version uint64) error

func (MTxnStore) UpsertTxnRecord

func (m MTxnStore) UpsertTxnRecord(ctx context.Context, version uint64, val types.DBValue) error

type MongoVVS

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

func (MongoVVS) Close

func (m MongoVVS) Close() error

func (MongoVVS) Floor

func (m MongoVVS) Floor(ctx context.Context, key string, upperVersion uint64) (types.DBValue, uint64, error)

func (MongoVVS) Get

func (m MongoVVS) Get(ctx context.Context, key string, version uint64) (types.DBValue, error)

func (MongoVVS) Remove

func (m MongoVVS) Remove(ctx context.Context, key string, version uint64) error

func (MongoVVS) RemoveIf

func (m MongoVVS) RemoveIf(ctx context.Context, key string, version uint64, pred func(prev types.DBValue) error) error

func (MongoVVS) UpdateFlag

func (m MongoVVS) UpdateFlag(ctx context.Context, key string, version uint64, newFlag uint8) error

func (MongoVVS) Upsert

func (m MongoVVS) Upsert(ctx context.Context, key string, version uint64, val types.DBValue) error

Jump to

Keyboard shortcuts

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