Documentation
¶
Index ¶
- Constants
- Variables
- func New(endpoints []string, options *store.Config) (store.Store, error)
- func Register()
- type DB
- func (r *DB) AtomicDelete(key string, previous *store.KVPair) (bool, error)
- func (r *DB) AtomicPut(key string, value []byte, previous *store.KVPair, options *store.WriteOptions) (bool, *store.KVPair, error)
- func (r *DB) Close()
- func (r *DB) Delete(key string) error
- func (r *DB) DeleteTree(keyPrefix string) error
- func (r *DB) Exists(key string, opts *store.ReadOptions) (bool, error)
- func (r *DB) Get(key string, opts *store.ReadOptions) (*store.KVPair, error)
- func (r *DB) List(keyPrefix string, opts *store.ReadOptions) ([]*store.KVPair, error)
- func (r *DB) NewLock(key string, options *store.LockOptions) (store.Locker, error)
- func (r *DB) Put(key string, value []byte, opts *store.WriteOptions) error
- func (r *DB) Watch(key string, stopCh <-chan struct{}, opts *store.ReadOptions) (<-chan *store.KVPair, error)
- func (r *DB) WatchTree(directory string, stopCh <-chan struct{}, opts *store.ReadOptions) (<-chan []*store.KVPair, error)
Constants ¶
View Source
const ( // KeyColName key column name KeyColName = "fs_key" // ValueColName value column name ValueColName = "fs_value" )
Variables ¶
View Source
var ( // ErrDBMultipleEndpointsUnsupported ... ErrDBMultipleEndpointsUnsupported = errors.New("db supports one endpoint and should be a file path") // ErrDBNoEndpointGiven ... ErrDBNoEndpointGiven = errors.New("one endpoint at least should be given") // ErrDBBucketOptionMissing is thrown when boltBcuket config option is missing ErrDBBucketOptionMissing = errors.New("dbBucket config option missing") )
Functions ¶
Types ¶
type DB ¶
type DB struct {
// contains filtered or unexported fields
}
DB relation-db storage
func (*DB) AtomicDelete ¶
AtomicDelete ...
func (*DB) AtomicPut ¶
func (r *DB) AtomicPut(key string, value []byte, previous *store.KVPair, options *store.WriteOptions) (bool, *store.KVPair, error)
AtomicPut ...
Click to show internal directories.
Click to hide internal directories.