v1

package
v3.4.0 Latest Latest
Warning

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

Go to latest
Published: Sep 2, 2022 License: CC0-1.0 Imports: 6 Imported by: 1 module, 1 package

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	RPC       *RPCConfig       `toml:"rpc"`
	Grpc      *GrpcConfig      `toml:"grpc"`
	Cosmos    *CosmosConfig    `toml:"cosmos"`
	Database  *DatabaseConfig  `toml:"database"`
	Logging   *LoggingConfig   `toml:"logging"`
	Parsing   *ParsingConfig   `toml:"parsing"`
	Pruning   *PruningConfig   `toml:"pruning"`
	Telemetry *TelemetryConfig `toml:"telemetry"`
}

func GetConfig

func GetConfig() (Config, error)

GetConfig returns the configuration reading it from the config.toml file present inside the home directory

type CosmosConfig

type CosmosConfig struct {
	Prefix  string   `toml:"prefix"`
	Modules []string `toml:"modules"`
}

type DatabaseConfig

type DatabaseConfig struct {
	Name               string `toml:"name"`
	Host               string `toml:"host"`
	Port               int64  `toml:"port"`
	User               string `toml:"user"`
	Password           string `toml:"password"`
	SSLMode            string `toml:"ssl_mode"`
	Schema             string `toml:"schema"`
	MaxOpenConnections int    `toml:"max_open_connections"`
	MaxIdleConnections int    `toml:"max_idle_connections"`
}

type GrpcConfig

type GrpcConfig struct {
	Address  string `toml:"address"`
	Insecure bool   `toml:"insecure"`
}

type LoggingConfig

type LoggingConfig struct {
	LogLevel  string `toml:"level"`
	LogFormat string `toml:"format"`
}

type ParsingConfig

type ParsingConfig struct {
	Workers         int64  `toml:"workers"`
	ParseNewBlocks  bool   `toml:"listen_new_blocks"`
	ParseOldBlocks  bool   `toml:"parse_old_blocks"`
	GenesisFilePath string `toml:"genesis_file_path"`
	ParseGenesis    bool   `toml:"parse_genesis"`
	StartHeight     int64  `toml:"start_height"`
	FastSync        bool   `toml:"fast_sync"`
}

type PruningConfig

type PruningConfig struct {
	KeepRecent int64 `toml:"keep_recent"`
	KeepEvery  int64 `toml:"keep_every"`
	Interval   int64 `toml:"interval"`
}

type RPCConfig

type RPCConfig struct {
	ClientName     string `toml:"client_name"`
	Address        string `toml:"address"`
	MaxConnections int    `toml:"max_connections"`
}

type TelemetryConfig

type TelemetryConfig struct {
	Enabled bool `toml:"enabled"`
	Port    uint `toml:"port"`
}

Jump to

Keyboard shortcuts

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