dynconfig

package
v0.0.0-...-ddbbf7b Latest Latest
Warning

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

Go to latest
Published: Apr 18, 2024 License: BSD-3-Clause Imports: 10 Imported by: 0

Documentation

Overview

Package dynconfig supports dynamic configuration for pkgsite services. Dynamic configuration is read from a file and can change over the lifetime of the process.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DynamicConfig

type DynamicConfig struct {
	Experiments []*internal.Experiment
}

DynamicConfig holds configuration that can change over the lifetime of the process. It is loaded from a GCS file or other external source.

func Parse

func Parse(yamlData []byte) (_ *DynamicConfig, err error)

Parse parses yamlData as a YAML description of DynamicConfig.

func Read

func Read(ctx context.Context, location string) (_ *DynamicConfig, err error)

Read reads dynamic configuration from the given location. Location may be of the form gs://bucket/object, denoting a GCS bucket. Otherwise it is interpreted as a filename.

Jump to

Keyboard shortcuts

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