config

package
v1.17.0 Latest Latest
Warning

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

Go to latest
Published: Nov 6, 2026 License: MIT Imports: 2 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	BindAddr                    string        `envconfig:"BIND_ADDR"`
	GracefulShutdownTimeout     time.Duration `envconfig:"GRACEFUL_SHUTDOWN_TIMEOUT"`
	HealthCheckInterval         time.Duration `envconfig:"HEALTHCHECK_INTERVAL"`
	HealthCheckCriticalTimeout  time.Duration `envconfig:"HEALTHCHECK_CRITICAL_TIMEOUT"`
	OTBatchTimeout              time.Duration `encconfig:"OTEL_BATCH_TIMEOUT"`
	OTExporterOTLPEndpoint      string        `envconfig:"OTEL_EXPORTER_OTLP_ENDPOINT"`
	OTServiceName               string        `envconfig:"OTEL_SERVICE_NAME"`
	BabbageURL                  string        `envconfig:"BABBAGE_URL"`
	RelCalURL                   string        `envconfig:"RELEASE_CALENDAR_URL"`
	EnableSearchController      bool          `envconfig:"ENABLE_SEARCH_CONTROLLER"`
	SearchControllerURL         string        `envconfig:"SEARCH_CONTROLLER_URL"`
	DatasetControllerURL        string        `envconfig:"DATASET_CONTROLLER_URL"`
	LegacyCacheAPIURL           string        `envconfig:"LEGACY_CACHE_API_URL"`
	CacheTimeDefault            time.Duration `envconfig:"CACHE_TIME_DEFAULT"`
	CacheTimeErrored            time.Duration `envconfig:"CACHE_TIME_ERRORED"`
	CacheTimeLong               time.Duration `envconfig:"CACHE_TIME_LONG"`
	CacheTimeShort              time.Duration `envconfig:"CACHE_TIME_SHORT"`
	EnablePublishExpiryOffset   bool          `envconfig:"ENABLE_PUBLISH_EXPIRY_OFFSET"`
	PublishExpiryOffset         time.Duration `envconfig:"PUBLISH_EXPIRY_OFFSET"`
	ReadTimeout                 time.Duration `envconfig:"READ_TIMEOUT"`
	WriteTimeout                time.Duration `envconfig:"WRITE_TIMEOUT"`
	StaleWhileRevalidateSeconds int64         `envconfig:"STALE_WHILE_REVALIDATE_SECONDS"`
	EnableMaxAgeCountdown       bool          `envconfig:"ENABLE_MAX_AGE_COUNTDOWN"`
	OtelEnabled                 bool          `envconfig:"OTEL_ENABLED"`
}

Config represents service configuration for dp-legacy-cache-proxy

func Get

func Get() (*Config, error)

Get returns the default config with any modifications through environment variables

Jump to

Keyboard shortcuts

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