database

package
v2.0.1 Latest Latest
Warning

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

Go to latest
Published: Oct 5, 2023 License: Apache-2.0 Imports: 20 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// CfgTangleDeleteDatabase defines whether to delete the database at startup.
	CfgTangleDeleteDatabase = "deleteDatabase"
	// CfgTangleDeleteAll defines whether to delete the database and snapshots at startup.
	CfgTangleDeleteAll = "deleteAll"

	// TangleDatabaseDirectoryName defines the subfolder for the tangle database.
	TangleDatabaseDirectoryName = "tangle"
	// UTXODatabaseDirectoryName defines the subfolder for the UTXO database.
	UTXODatabaseDirectoryName = "utxo"
)

Variables

View Source
var (
	Component *app.Component
)
View Source
var ParamsDatabase = &ParametersDatabase{}

Functions

This section is empty.

Types

type ParametersDatabase

type ParametersDatabase struct {
	// Engine defines the used database engine (pebble/rocksdb/mapdb).
	Engine string `default:"rocksdb" usage:"the used database engine (pebble/rocksdb/mapdb)"`
	// Path defines the path to the database folder.
	Path string `default:"mainnet/database" usage:"the path to the database folder"`
	// AutoRevalidation defines whether to automatically start revalidation on startup if the database is corrupted.
	AutoRevalidation bool `default:"false" usage:"whether to automatically start revalidation on startup if the database is corrupted"`
	// Debug defines whether to ignore the check for corrupted databases (should only be used for debug reasons).
	Debug bool `default:"false" usage:"ignore the check for corrupted databases (should only be used for debug reasons)"`
	// CheckLedgerStateOnStartup defines whether to check if the ledger state matches the total supply on startup
	CheckLedgerStateOnStartup bool `default:"false" usage:"whether to check if the ledger state matches the total supply on startup"`
}

ParametersDatabase contains the definition of the parameters used by the ParametersDatabase.

Jump to

Keyboard shortcuts

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