app

package
v0.0.0-...-96cdf77 Latest Latest
Warning

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

Go to latest
Published: Apr 25, 2024 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	UseRFC3339           bool          `env:"USE_RFC3339"`
	APIURL               string        `env:"API_URL,              required, report"`
	APICAFile            string        `env:"API_CA_FILE_PATH,     required, report"`
	APICertFile          string        `env:"API_CERT_FILE_PATH,   required, report"`
	APIKeyFile           string        `env:"API_KEY_FILE_PATH,    required, report"`
	APICommonName        string        `env:"API_COMMON_NAME,      required, report"`
	APIPollingInterval   time.Duration `env:"API_POLLING_INTERVAL, report"`
	APIBatchSize         int           `env:"API_BATCH_SIZE, report"`
	APIDisableKeepAlives bool          `env:"API_DISABLE_KEEP_ALIVES, report"`
	CipherSuites         []string      `env:"CIPHER_SUITES, report"`
	AggregateDrainsFile  string        `env:"AGGREGATE_DRAINS_FILE, report"`

	CacheCAFile     string `env:"CACHE_CA_FILE_PATH,     required, report"`
	CacheCertFile   string `env:"CACHE_CERT_FILE_PATH,   required, report"`
	CacheKeyFile    string `env:"CACHE_KEY_FILE_PATH,    required, report"`
	CacheCommonName string `env:"CACHE_COMMON_NAME,      required, report"`

	CachePort int `env:"CACHE_PORT, required, report"`

	MetricsServer config.MetricsServer
}

Config holds the configuration for the syslog binding cache

func LoadConfig

func LoadConfig() Config

LoadConfig will load the configuration for the syslog binding cache from the environment. If loading the config fails for any reason this function will panic.

type Metrics

type Metrics interface {
	NewCounter(name, helpText string, options ...metrics.MetricOption) metrics.Counter
	NewGauge(name, helpText string, o ...metrics.MetricOption) metrics.Gauge
	RegisterDebugMetrics()
}

type SyslogBindingCache

type SyslogBindingCache struct {
	// contains filtered or unexported fields
}

func NewSyslogBindingCache

func NewSyslogBindingCache(config Config, metrics Metrics, log *log.Logger) *SyslogBindingCache

func (*SyslogBindingCache) Run

func (sbc *SyslogBindingCache) Run()

func (*SyslogBindingCache) Stop

func (sbc *SyslogBindingCache) Stop()

Jump to

Keyboard shortcuts

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