dcrd/database/ffldb
Dave Collins 10147bc8f8
database: Use chaincfg/v2.
This updates the database module to use v2 of the chaincfg module and
bumps the root module to require dcrutil@v1.3.0 accordingly.

Since v2 of the chaincfg module is only used in the tests and standalone
utility, a major version bump of the database module is not required.
2019-06-19 14:18:43 -05:00
..
bench_test.go database: Use chaincfg/v2. 2019-06-19 14:18:43 -05:00
blockio.go multi: cleanup linter warnings 2019-02-13 08:38:25 -05:00
db.go Merge remaining dcrutil code into a dcrd package. 2017-10-11 22:06:36 -04:00
dbcache.go remove deadcode 2017-07-17 15:06:47 -05:00
doc.go database: Replace with new version. 2016-08-23 17:40:38 -04:00
driver_test.go database: Use chaincfg/v2. 2019-06-19 14:18:43 -05:00
driver.go multi: Replace btclog with slog. 2018-05-23 14:22:10 -05:00
export_test.go database: Replace with new version. 2016-08-23 17:40:38 -04:00
interface_test.go multi: Remove unused code. 2018-10-31 21:50:09 -04:00
ldbtreapiter.go database: Replace with new version. 2016-08-23 17:40:38 -04:00
mockfile_test.go database: Replace with new version. 2016-08-23 17:40:38 -04:00
README.md multi: Use https links where available. 2019-06-18 14:20:06 -05:00
reconcile.go all: Remove seelog logger. 2017-06-20 10:58:10 -04:00
whitebox_test.go multi: cleanup linter warnings 2019-02-13 08:38:25 -05:00

ffldb

Build Status ISC License GoDoc

Package ffldb implements a driver for the database package that uses leveldb for the backing metadata and flat files for block storage.

This driver is the recommended driver for use with dcrd. It makes use leveldb for the metadata, flat files for block storage, and checksums in key areas to ensure data integrity.

Package ffldb is licensed under the copyfree ISC license.

Usage

This package is a driver to the database package and provides the database type of "ffldb". The parameters the Open and Create functions take are the database path as a string and the block network.

db, err := database.Open("ffldb", "path/to/database", wire.MainNet)
if err != nil {
	// Handle error
}
db, err := database.Create("ffldb", "path/to/database", wire.MainNet)
if err != nil {
	// Handle error
}

License

Package ffldb is licensed under the copyfree ISC License.