server

package
v1.0.24 Latest Latest
Warning

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

Go to latest
Published: Dec 12, 2024 License: GPL-3.0 Imports: 26 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 {
	// The address to listen on.
	Addr string `yaml:"addr" default:":8080"`
	// PreStopSleepSeconds is the number of seconds to sleep before stopping.
	// Useful for giving kubernetes time to drain connections.
	// This sleep will happen after a SIGTERM is received, and will
	// delay the shutdown of the server and all of it's components.
	// Note: Do not set this to a value greater than the kubernetes
	// terminationGracePeriodSeconds.
	PreStopSleepSeconds int `yaml:"preStopSleepSeconds" default:"0"`
	// MetricsAddr is the address to listen on for metrics.
	MetricsAddr string `yaml:"metricsAddr" default:":9090"`
	// PProfAddr is the address to listen on for pprof.
	PProfAddr *string `yaml:"pprofAddr"`
	// LoggingLevel is the logging level to use.
	LoggingLevel string `yaml:"logging" default:"info"`

	// NTP Server to use for clock drift correction
	NTPServer string `yaml:"ntpServer" default:"time.google.com"`

	// Store is the cache configuration.
	Persistence persistence.Config `yaml:"persistence"`
	// Store is the cache configuration.
	Store store.Config `yaml:"store"`
	// GeoIP is the geoip provider configuration.
	GeoIP geoip.Config `yaml:"geoip"`

	// Services is the list of services to run.
	Services service.Config `yaml:"services"`

	// Tracing configuration
	Tracing observability.TracingConfig `yaml:"tracing"`
}

func (*Config) ApplyOverrides added in v1.0.8

func (c *Config) ApplyOverrides(o *Override, log logrus.FieldLogger) error

func (*Config) Validate

func (c *Config) Validate() error

type Override added in v1.0.8

type Override struct {
	// MetricsAddr configures the metrics address.
	MetricsAddr struct {
		Enabled bool
		Value   string
	}
	// EventIngesterBasicAuth configures basic authentication for the event ingester.
	EventIngesterBasicAuth struct {
		Username string
		Password string
	}
	// CoordinatorAuth configures the authentication for the coordinator.
	CoordinatorAuth struct {
		Enabled    bool
		AuthSecret string
	}
}

type Xatu

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

func NewXatu

func NewXatu(ctx context.Context, log logrus.FieldLogger, conf *Config, o *Override) (*Xatu, error)

func (*Xatu) Start

func (x *Xatu) Start(ctx context.Context) error

Jump to

Keyboard shortcuts

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