config

package
v0.3.1 Latest Latest
Warning

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

Go to latest
Published: Feb 28, 2017 License: Apache-2.0 Imports: 7 Imported by: 4

Documentation

Index

Constants

View Source
const (
	//VersionInt in INT form
	VersionInt = 1

	//VersionStr in string form
	VersionStr = "0.3.1"

	//CPUPerMdmExecutor num of CPUs to MDM executor
	CPUPerMdmExecutor = 1.5

	//CPUPerNonExecutor num of CPUs to Non-MDM executor
	CPUPerNonExecutor = 0.5

	//MemPerMdmExecutor mem to MDM executor
	MemPerMdmExecutor = 3072

	//MemPerNonExecutor mem to Non-MDM executor
	MemPerNonExecutor = 512

	//AwsFreeSpaceThreshold free less than this will be auto expanded
	AwsUsedThreshold = 90

	//DefaultRestPort rest port
	DefaultRestPort = 35000

	//RexrayRetry exponential backoff for retries
	RexrayRetry = 5

	//RexrayDelay a random delay to add to the exponential backoff
	RexrayDelay = 7
)

consts exported out of package

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	LogLevel        string
	Debug           bool
	DeleteKeyValues bool
	DumpKeyValues   bool
	StoreAddKey     string
	StoreAddVal     string
	StoreDelKey     string
	Experimental    bool

	RexrayBranch  string
	RexrayVersion string

	IsolatorBinary string

	RestAddress          string
	RestPort             int
	MasterREST           string
	AltExecutorPath      string
	ExecutorMdmCPU       float64
	ExecutorNonCPU       float64
	ExecutorCPUFactor    float64
	ExecutorMdmMemory    float64
	ExecutorNonMemory    float64
	ExecutorMemoryFactor float64
	User                 string
	Hostname             string
	Role                 string
	Store                string
	StoreURI             string

	ClusterName          string
	ClusterID            string
	LbGateway            string
	ProtectionDomain     string
	StoragePool          string
	AdminPassword        string
	APIVersion           string
	PrimaryMdmAddress    string
	SecondaryMdmAddress  string
	TieBreakerMdmAddress string
	GatewayAddress       string
	DebMdm               string
	DebSds               string
	DebSdc               string
	DebLia               string
	DebGw                string
	RpmMdm               string
	RpmSds               string
	RpmSdc               string
	RpmLia               string
	RpmGw                string

	UsedThreshold    int
	AccessKey        string
	SecretKey        string
	CheckFull        int
	VolumeGrowthSize int
}

Config is the representation of the config

func NewConfig

func NewConfig() *Config

NewConfig creates a new Config object

func (*Config) AddFlags

func (cfg *Config) AddFlags(fs *flag.FlagSet)

AddFlags adds flags to the command line parsing

Jump to

Keyboard shortcuts

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