Documentation
¶
Overview ¶
Package flatfs is a Datastore implementation that stores all objects in a two-level directory structure in the local file system, regardless of the hierarchy of the keys.
Index ¶
- Constants
- Variables
- type Datastore
- func (fs *Datastore) Batch() (datastore.Batch, error)
- func (fs *Datastore) Close() error
- func (fs *Datastore) Delete(key datastore.Key) error
- func (fs *Datastore) Get(key datastore.Key) (value interface{}, err error)
- func (fs *Datastore) Has(key datastore.Key) (exists bool, err error)
- func (*Datastore) IsThreadSafe()
- func (fs *Datastore) Put(key datastore.Key, value interface{}) error
- func (fs *Datastore) Query(q query.Query) (query.Results, error)
Constants ¶
View Source
const SyncThreadsMax = 16
don't block more than 16 threads on sync opearation 16 should be able to sataurate most RAIDs in case of two used disks per write (RAID 1, 5) and queue depth of 2, 16 concurrent Sync calls should be able to saturate 16 HDDs RAID TODO: benchmark it out, maybe provide tweak parmeter
Variables ¶
View Source
var (
ErrBadPrefixLen = errors.New("bad prefix length")
)
Functions ¶
This section is empty.
Types ¶
type Datastore ¶
type Datastore struct {
// contains filtered or unexported fields
}
func (*Datastore) IsThreadSafe ¶
func (*Datastore) IsThreadSafe()
Click to show internal directories.
Click to hide internal directories.