common

package
v0.15.5 Latest Latest
Warning

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

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

Documentation

Index

Constants

View Source
const PodNamePrefix string = "armada-"

Variables

This section is empty.

Functions

func BindCommandlineArguments

func BindCommandlineArguments()

func ConfigureCommandLineLogging

func ConfigureCommandLineLogging()

TODO Move logging-related code out of common into a new package internal/logging

func ConfigureLogging

func ConfigureLogging()

func ContextWithDefaultTimeout

func ContextWithDefaultTimeout() (*armadacontext.Context, context.CancelFunc)

func LoadConfig

func LoadConfig(config commonconfig.Config, defaultPath string, overrideConfigs []string) *viper.Viper

TODO Move code relating to config out of common into a new package internal/serverconfig

func PodName added in v0.4.44

func PodName(jobId string) string

func ServeHttp

func ServeHttp(port uint16, mux http.Handler) (shutdown func())

ServeHttp starts an HTTP server listening on the given port. TODO: Make block until a context passed in is cancelled.

func ServeHttps added in v0.3.93

func ServeHttps(port uint16, mux http.Handler, certFile, keyFile string) (shutdown func())

func ServeMetrics

func ServeMetrics(port uint16) (shutdown func())

func ServeMetricsFor

func ServeMetricsFor(port uint16, gatherer prometheus.Gatherer) (shutdown func())

func UnmarshalKey

func UnmarshalKey(v *viper.Viper, key string, item interface{}) error

Types

type LoginCredentials

type LoginCredentials struct {
	Username string
	Password string
}

func (*LoginCredentials) GetRequestMetadata

func (c *LoginCredentials) GetRequestMetadata(context.Context, ...string) (map[string]string, error)

func (*LoginCredentials) RequireTransportSecurity

func (c *LoginCredentials) RequireTransportSecurity() bool

Directories

Path Synopsis
Package armadaerrors contains generic errors that should be returned by code handling gRPC requests.
Package armadaerrors contains generic errors that should be returned by code handling gRPC requests.
Package mocks is a generated GoMock package.
Package mocks is a generated GoMock package.
controlplaneevents
Package controlplaneevents is a generated GoMock package.
Package controlplaneevents is a generated GoMock package.
jobsetevents
Package jobsetevents is a generated GoMock package.
Package jobsetevents is a generated GoMock package.

Jump to

Keyboard shortcuts

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