kvledger

package
v0.0.0-...-95b87ed Latest Latest
Warning

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

Go to latest
Published: Sep 16, 2019 License: Apache-2.0 Imports: 35 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrLedgerIDExists = errors.New("LedgerID already exists")

	ErrNonExistingLedgerID = errors.New("LedgerID does not exist")

	ErrLedgerNotOpened = errors.New("ledger is not opened yet")

	ErrInactiveLedger = errors.New("Ledger is not active")
)

Functions

func BlockStorePath

func BlockStorePath(rootFSPath string) string

func BookkeeperDBPath

func BookkeeperDBPath(rootFSPath string) string

func ClearPreResetHeight

func ClearPreResetHeight(rootFSPath string) error

func ConfigHistoryDBPath

func ConfigHistoryDBPath(rootFSPath string) string

func HistoryDBPath

func HistoryDBPath(rootFSPath string) string

func LedgerProviderPath

func LedgerProviderPath(rootFSPath string) string

func LoadPreResetHeight

func LoadPreResetHeight(rootFSPath string) (map[string]uint64, error)

func PvtDataStorePath

func PvtDataStorePath(rootFSPath string) string

func ResetAllKVLedgers

func ResetAllKVLedgers(rootFSPath string) error

func RollbackKVLedger

func RollbackKVLedger(rootFSPath, ledgerID string, blockNum uint64) error

func StateDBPath

func StateDBPath(rootFSPath string) string

func UpgradeDataFormat

func UpgradeDataFormat(rootFSPath string) error

func UpgradeIDStoreFormat

func UpgradeIDStoreFormat(rootFSPath string) error

Types

type Provider

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

func NewProvider

func NewProvider(initializer *ledger.Initializer) (pr *Provider, e error)

func (*Provider) Close

func (p *Provider) Close()

func (*Provider) Create

func (p *Provider) Create(genesisBlock *common.Block) (ledger.PeerLedger, error)

func (*Provider) Exists

func (p *Provider) Exists(ledgerID string) (bool, error)

func (*Provider) List

func (p *Provider) List() ([]string, error)

func (*Provider) Open

func (p *Provider) Open(ledgerID string) (ledger.PeerLedger, error)

Jump to

Keyboard shortcuts

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