Categorygithub.com/decred/dcrdata/db/dcrsqlite/v2
modulepackage
2.0.0
Repository: https://github.com/decred/dcrdata.git
Documentation: pkg.go.dev

# Functions

DisableLog disables all library log output.
InitDB creates a new DB instance from a DBInfo containing the name of the file used to back the underlying sql database.
InitWiredDB creates a new WiredDB from a file containing the data for a sql.DB.
NewDB creates a new DB instance with pre-generated sql statements from an existing sql.DB.
NewWiredDB creates a new WiredDB from a *sql.DB, a node client, network parameters, and a status update channel.
UseLogger uses a specified Logger to output package logging info.

# Constants

DBBusyTimeout is the length of time in milliseconds for sqlite to retry DB access when the SQLITE_BUSY error would otherwise be returned.
No description provided by the author
A couple database queries that are called before NewWiredDB.
No description provided by the author
TableNameStakeInfo is name of the table used to store extended stake info.
TableNameSummaries is name of the table used to store block summary data.

# Structs

ChainMonitor handles change notifications from the node client.
DB is a wrapper around sql.DB that adds methods for storing and retrieving chain data.
DBDataSaver models a DB with a channel to communicate new block height to the web interface.
DBInfo contains db configuration.
WiredDB is intended to satisfy DataSourceLite interface.

# Interfaces

BlockSummaryDatabaser is the interface for a block data saving database.
StakeInfoDatabaser is the interface for an extended stake info saving database.