Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Database ¶
type Database struct {
*bolt.DB
}
Database stores database connection.
func NewDB ¶
func NewDB(opt *DatabaseOptions) (d *Database, err error)
NewDB will create a new database connection.
type DatabaseOptions ¶
type DatabaseOptions struct {
Address string
}
DatabaseOptions stores database options.
type Tx ¶
type Tx = bolt.Tx
Tx represents a read-only or read/write transaction on the database. Read-only transactions can be used for retrieving values for keys and creating cursors. Read/write transactions can create and remove buckets and create and remove keys.
IMPORTANT: You must commit or rollback transactions when you are done with them. Pages can not be reclaimed by the writer until no more transactions are using them. A long running read transaction can cause the database to quickly grow.
Click to show internal directories.
Click to hide internal directories.