config

package
v1.3.1 Latest Latest
Warning

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

Go to latest
Published: Feb 3, 2021 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ConfigurationStruct

type ConfigurationStruct struct {
	Writable      WritableInfo
	Logging       bootstrapConfig.LoggingInfo
	KongURL       KongUrlInfo
	KongAuth      KongAuthInfo
	KongACL       KongAclInfo
	SecretStore   bootstrapConfig.SecretStoreInfo
	SecretService SecretServiceInfo
	Clients       map[string]bootstrapConfig.ClientInfo
}

func (*ConfigurationStruct) EmptyWritablePtr

func (c *ConfigurationStruct) EmptyWritablePtr() interface{}

EmptyWritablePtr returns a pointer to a service-specific empty WritableInfo struct. It is used by the bootstrap to provide the appropriate structure to registry.Client's WatchForChanges().

func (*ConfigurationStruct) GetBootstrap

GetBootstrap returns the configuration elements required by the bootstrap. Currently, a copy of the configuration data is returned. This is intended to be temporary -- since ConfigurationStruct drives the configuration.toml's structure -- until we can make backwards-breaking configuration.toml changes (which would consolidate these fields into an bootstrapConfig.BootstrapConfiguration struct contained within ConfigurationStruct).

func (*ConfigurationStruct) GetDatabaseInfo

func (c *ConfigurationStruct) GetDatabaseInfo() map[string]bootstrapConfig.Database

GetDatabaseInfo returns a database information map.

func (*ConfigurationStruct) GetLogLevel

func (c *ConfigurationStruct) GetLogLevel() string

GetLogLevel returns the current ConfigurationStruct's log level.

func (*ConfigurationStruct) GetRegistryInfo

func (c *ConfigurationStruct) GetRegistryInfo() bootstrapConfig.RegistryInfo

GetRegistryInfo returns the RegistryInfo from the ConfigurationStruct.

func (*ConfigurationStruct) UpdateFromRaw

func (c *ConfigurationStruct) UpdateFromRaw(rawConfig interface{}) bool

UpdateFromRaw converts configuration received from the registry to a service-specific configuration struct which is then used to overwrite the service's existing configuration struct.

func (*ConfigurationStruct) UpdateWritableFromRaw

func (c *ConfigurationStruct) UpdateWritableFromRaw(rawWritable interface{}) bool

UpdateWritableFromRaw converts configuration received from the registry to a service-specific WritableInfo struct which is then used to overwrite the service's existing configuration's WritableInfo struct.

type KongAclInfo

type KongAclInfo struct {
	Name      string
	WhiteList string
}

type KongAuthInfo

type KongAuthInfo struct {
	Name       string
	TokenTTL   int
	Resource   string
	OutputPath string
}

type KongUrlInfo

type KongUrlInfo struct {
	Server             string
	AdminPort          int
	AdminPortSSL       int
	ApplicationPort    int
	ApplicationPortSSL int
}

func (KongUrlInfo) GetProxyBaseURL

func (k KongUrlInfo) GetProxyBaseURL() string

func (KongUrlInfo) GetSecureURL

func (k KongUrlInfo) GetSecureURL() string

type SecretServiceInfo

type SecretServiceInfo struct {
	Server          string
	Port            int
	HealthcheckPath string
	CertPath        string
	TokenPath       string
	CACertPath      string
	SNIS            []string
}

func (SecretServiceInfo) GetSecretSvcBaseURL

func (s SecretServiceInfo) GetSecretSvcBaseURL() string

type WritableInfo

type WritableInfo struct {
	LogLevel       string
	RequestTimeout int
}

Jump to

Keyboard shortcuts

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