Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BadgerDB ¶
type BadgerDB struct { *badger.DB // contains filtered or unexported fields }
BadgerDB is a wrapper around the standard badger.DB that provides a background compaction routine.
func Open ¶
Open opens (initializing if necessary) a Badger database at the specified path. Users must close the DB with Close().
func OpenTruncate ¶ added in v0.0.3
OpenTruncate opens (initializing and/or truncating if necessary) a Badger database at the specified path. Users must close the DB with Close().
Prefer Open in the general case, but after a bad shutdown it may be necessary to call OpenTruncate. This may cause data loss. Detect this situation by looking for badger.ErrTruncateNeeded.
Click to show internal directories.
Click to hide internal directories.