Documentation ¶
Index ¶
- Constants
- func GetArraySupportForCH() bool
- func GetBool(key string, defaultValue bool) (value bool)
- func GetDuration(key string, defaultValue time.Duration, timeScale time.Duration) (value time.Duration)
- func GetEnv(key string, defaultVal string) string
- func GetEnvAsBool(name string, defaultVal bool) bool
- func GetEnvAsInt(key string, defaultVal int) int
- func GetFloat64(key string, defaultValue float64) (value float64)
- func GetInstanceID() string
- func GetInt(key string, defaultValue int) (value int)
- func GetInt64(key string, defaultValue int64) (value int64)
- func GetKubeNamespace() string
- func GetNamespaceIdentifier() string
- func GetRequiredEnv(key string) string
- func GetRequiredEnvAsInt(key string) int
- func GetString(key string, defaultValue string) (value string)
- func GetVarCharMaxForRS() bool
- func GetWHSchemaVersion() string
- func GetWorkspaceToken() string
- func Initialize()
- func IsEnvSet(key string) bool
- func IsSet(key string) bool
- func RegisterBoolConfigVariable(defaultValue bool, ptr *bool, isHotReloadable bool, keys ...string)
- func RegisterDurationConfigVariable(defaultValue time.Duration, ptr *time.Duration, isHotReloadable bool, ...)
- func RegisterFloat64ConfigVariable(defaultValue float64, ptr *float64, isHotReloadable bool, keys ...string)
- func RegisterInt64ConfigVariable(defaultValue int64, ptr *int64, isHotReloadable bool, valueScale int64, ...)
- func RegisterIntConfigVariable(defaultValue int, ptr *int, isHotReloadable bool, valueScale int, ...)
- func RegisterStringConfigVariable(defaultValue string, ptr *string, isHotReloadable bool, keys ...string)
- func SetBool(key string, value bool)
- func SetString(key string, value string)
- func SetWHSchemaVersion(version string)
- func TransformKey(s string) string
- func UpdateConfig()
- type ConfigVar
Constants ¶
const ( EmbeddedMode = "embedded" MasterMode = "master" MasterSlaveMode = "master_and_slave" SlaveMode = "slave" OffMode = "off" PooledWHSlaveMode = "embedded_master" )
Rudder server supported config constants
Variables ¶
This section is empty.
Functions ¶
func GetArraySupportForCH ¶ added in v0.1.10
func GetArraySupportForCH() bool
func GetDuration ¶
func GetDuration(key string, defaultValue time.Duration, timeScale time.Duration) (value time.Duration)
GetDuration is wrapper for viper's GetDuration
func GetEnvAsBool ¶
GetEnvAsBool returns the boolean environment value stored in key variable
func GetEnvAsInt ¶ added in v0.1.10
GetEnvAsInt returns the int value of environment value stored in the key variable If not set, default value will be return. If set but unparsable, returns 0
func GetFloat64 ¶
GetFloat64 is wrapper for viper's GetFloat64
func GetInstanceID ¶ added in v0.1.10
func GetInstanceID() string
func GetKubeNamespace ¶ added in v0.1.10
func GetKubeNamespace() string
returns value stored in KUBE_NAMESPACE env var
func GetNamespaceIdentifier ¶ added in v0.1.10
func GetNamespaceIdentifier() string
func GetRequiredEnv ¶
GetRequiredEnv returns the environment value stored in key variable, no default
func GetRequiredEnvAsInt ¶ added in v0.1.10
GetRequiredEnvAsInt returns the environment value stored in key variable as int, no default
func GetVarCharMaxForRS ¶ added in v0.1.10
func GetVarCharMaxForRS() bool
func GetWHSchemaVersion ¶ added in v0.1.10
func GetWHSchemaVersion() string
func GetWorkspaceToken ¶
func GetWorkspaceToken() string
GetWorkspaceToken returns the workspace token provided in the environment variables Env variable CONFIG_BACKEND_TOKEN is deprecating soon WORKSPACE_TOKEN is newly introduced. This will override CONFIG_BACKEND_TOKEN
func Initialize ¶
func Initialize()
Initialize used to initialize config package Deprecated - There is no need to directly call Initialize, config is initialized via its package init()
func RegisterBoolConfigVariable ¶ added in v0.1.10
func RegisterDurationConfigVariable ¶ added in v0.1.10
func RegisterFloat64ConfigVariable ¶ added in v0.1.10
func RegisterInt64ConfigVariable ¶ added in v0.1.10
func RegisterIntConfigVariable ¶ added in v0.1.10
func RegisterStringConfigVariable ¶ added in v0.1.10
func SetWHSchemaVersion ¶ added in v0.1.10
func SetWHSchemaVersion(version string)
func TransformKey ¶ added in v0.1.10
TransformKey as package method to get the formatted env from a give string
func UpdateConfig ¶ added in v0.1.10
func UpdateConfig()