config

package
v0.0.0-...-81a4f0c Latest Latest
Warning

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

Go to latest
Published: Dec 1, 2021 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

View Source
const (
	DefaultLoggingLevel  = "info"
	DefaultMaxAmount     = 10
	DefaultValidDuration = 1 * time.Second
)

Variables

This section is empty.

Functions

This section is empty.

Types

type BrokerCredentialsConfig

type BrokerCredentialsConfig struct {
	BrokerUsername     string `yaml:"broker_username"`
	BrokerUsernameHash []byte `yaml:"broker_username_hash"`
	BrokerPassword     string `yaml:"broker_password"`
	BrokerPasswordHash []byte `yaml:"broker_password_hash"`
}

type Config

type Config struct {
	Logging               helpers.LoggingConfig         `yaml:"logging"`
	BrokerServer          ServerConfig                  `yaml:"broker_server"`
	PublicApiServer       ServerConfig                  `yaml:"public_api_server"`
	DB                    map[string]db.DatabaseConfig  `yaml:"db"`
	BrokerCredentials     []BrokerCredentialsConfig     `yaml:"broker_credentials"`
	APIClientId           string                        `yaml:"api_client_id"`
	QuotaManagement       *QuotaManagementConfig        `yaml:"quota_management"`
	PlanCheck             *PlanCheckConfig              `yaml:"plan_check"`
	CatalogPath           string                        `yaml:"catalog_path"`
	CatalogSchemaPath     string                        `yaml:"catalog_schema_path"`
	DashboardRedirectURI  string                        `yaml:"dashboard_redirect_uri"`
	PolicySchemaPath      string                        `yaml:"policy_schema_path"`
	Scheduler             SchedulerConfig               `yaml:"scheduler"`
	ScalingEngine         ScalingEngineConfig           `yaml:"scaling_engine"`
	MetricsCollector      MetricsCollectorConfig        `yaml:"metrics_collector"`
	EventGenerator        EventGeneratorConfig          `yaml:"event_generator"`
	CF                    cf.CFConfig                   `yaml:"cf"`
	UseBuildInMode        bool                          `yaml:"use_buildin_mode"`
	InfoFilePath          string                        `yaml:"info_file_path"`
	MetricsForwarder      MetricsForwarderConfig        `yaml:"metrics_forwarder"`
	Health                models.HealthConfig           `yaml:"health"`
	RateLimit             models.RateLimitConfig        `yaml:"rate_limit"`
	CredHelperImpl        string                        `yaml:"cred_helper_impl"`
	StoredProcedureConfig *models.StoredProcedureConfig `yaml:"stored_procedure_binding_credential_config"`
}

func LoadConfig

func LoadConfig(reader io.Reader) (*Config, error)

func (*Config) Validate

func (c *Config) Validate() error

type EventGeneratorConfig

type EventGeneratorConfig struct {
	EventGeneratorUrl string          `yaml:"event_generator_url"`
	TLSClientCerts    models.TLSCerts `yaml:"tls"`
}

type MetricsCollectorConfig

type MetricsCollectorConfig struct {
	MetricsCollectorUrl string          `yaml:"metrics_collector_url"`
	TLSClientCerts      models.TLSCerts `yaml:"tls"`
}

type MetricsForwarderConfig

type MetricsForwarderConfig struct {
	MetricsForwarderUrl     string `yaml:"metrics_forwarder_url"`
	MetricsForwarderMtlsUrl string `yaml:"metrics_forwarder_mtls_url"`
}

type PlanCheckConfig

type PlanCheckConfig struct {
	PlanDefinitions map[string]PlanDefinition `yaml:"plan_definitions"`
}

type PlanDefinition

type PlanDefinition struct {
	PlanCheckEnabled  bool `yaml:"planCheckEnabled"`
	SchedulesCount    int  `yaml:"schedules_count"`
	ScalingRulesCount int  `yaml:"scaling_rules_count"`
	PlanUpdateable    bool `yaml:"plan_updateable"`
}

type QuotaManagementConfig

type QuotaManagementConfig struct {
	API               string `yaml:"api"`
	ClientID          string `yaml:"client_id"`
	Secret            string `yaml:"secret"`
	TokenURL          string `yaml:"oauth_url"`
	SkipSSLValidation bool   `yaml:"skip_ssl_validation"`
}

type ScalingEngineConfig

type ScalingEngineConfig struct {
	ScalingEngineUrl string          `yaml:"scaling_engine_url"`
	TLSClientCerts   models.TLSCerts `yaml:"tls"`
}

type SchedulerConfig

type SchedulerConfig struct {
	SchedulerURL   string          `yaml:"scheduler_url"`
	TLSClientCerts models.TLSCerts `yaml:"tls"`
}

type ServerConfig

type ServerConfig struct {
	Port int             `yaml:"port"`
	TLS  models.TLSCerts `yaml:"tls"`
}

Jump to

Keyboard shortcuts

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