configs

package
v0.0.0-...-57b48e0 Latest Latest
Warning

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

Go to latest
Published: Oct 25, 2018 License: GPL-3.0, LGPL-3.0, LGPL-3.0-or-later Imports: 5 Imported by: 5

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func InitDB

func InitDB(config *FDBConfig) (*fdb.Database, error)

Types

type ConcurrencyConfig

type ConcurrencyConfig struct {
	DatabaseConcurrency  int `env:"FDB_CONCURRENCY" envDefault:"10000"`
	ECRecoverConcurrency int `env:"EC_CONCURRENCY" envDefault:"-1"`
	MaxProc              int `env:"GOMAXPROCS" envDefault:"-1"`
}

type FDBConfig

type FDBConfig struct {
	FdbRewriteClusterFile bool   `env:"FDB_REWRITE" envDefault:"false"`
	FdbClusterFilePath    string `env:"FDB_CLUSTER_FILE_PATH" envDefault:""`
}

type HTTPConfig

type HTTPConfig struct {
	Port                int `env:"PORT" envDefault:"3001"`
	HTTPConcurrency     int `env:"HTTP_CONCURRENCY" envDefault:"50000"`
	MaxConnectionsPerIP int `env:"HTTP_MAXCONNECTIONS" envDefault:"50000"`
	MaxBodySize         int `env:"HTTP_MAXBODYSIZE" envDefault:"5000"`
}

type RedisConfig

type RedisConfig struct {
	RedisHost     string `env:"REDIS_HOST" envDefault:"127.0.0.1"`
	RedisPort     int    `env:"REDIS_PORT" envDefault:"6379"`
	RedisPassword string `env:"REDIS_PASSWORD" envDefault:""`
}

type SignatureConfig

type SignatureConfig struct {
	FundingTXSigningKey string `env:"FUNDINGTX_ETH_KEY" envDefault:"0xc87509a1c067bbde78beb793e6fa76530b6382a4c0241e5e4a9ec0a0f44dc0d3"`
	BlockSigningKey     string `env:"BLOCK_ETH_KEY" envDefault:"0xc87509a1c067bbde78beb793e6fa76530b6382a4c0241e5e4a9ec0a0f44dc0d3"`
}

Jump to

Keyboard shortcuts

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