db

package
v0.2202.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 23, 2022 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Overview

Package db implements several Tendermint DB backends.

Index

Constants

This section is empty.

Variables

Flags has the configuration flags.

Functions

func GetBackendName

func GetBackendName() string

GetBackendName returns the currently configured Tendermint database backend.

func GetProvider

func GetProvider() (node.DBProvider, error)

GetProvider returns the currently configured Tendermint DBProvider.

func New

func New(fn string, noSuffix bool) (dbm.DB, error)

New constructs a new tendermint DB with the configured backend.

func WithCloser added in v0.2202.0

func WithCloser(db dbm.DB, closer *Closer) dbm.DB

WithCloser wraps a Tendermint Core database instance so that it can only be closed by the given closer instance. Direct attempts to close the returned database instance will be ignored.

Types

type Closer added in v0.2202.0

type Closer struct {
	// contains filtered or unexported fields
}

Closer manages closing of multiple Tendermint Core databases.

func NewCloser added in v0.2202.0

func NewCloser() *Closer

NewCloser creates a new empty database closer.

func (*Closer) Close added in v0.2202.0

func (c *Closer) Close()

Close closes all the managed databases.

Directories

Path Synopsis
Package badger implements a tendermint DB, backed by BadgerDB.
Package badger implements a tendermint DB, backed by BadgerDB.
Package tests is a collection of tendermint DB backend tests.
Package tests is a collection of tendermint DB backend tests.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL