server

package
Version: v0.0.0-...-2e5a2a8 Latest Latest
Warning

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

Go to latest
Published: Sep 16, 2021 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

View Source
const (
	OrgQuery     = "org"
	RepoQuery    = "repo"
	BranchQuery  = "branch"
	VariantQuery = "variant"

	InjectFromOrgQuery     = "injectTestFromOrg"
	InjectFromRepoQuery    = "injectTestFromRepo"
	InjectFromBranchQuery  = "injectTestFromBranch"
	InjectFromVariantQuery = "injectTestFromVariant"
	InjectTestQuery        = "injectTest"
)

Variables

This section is empty.

Functions

func MetadataFromQuery

func MetadataFromQuery(w http.ResponseWriter, r *http.Request) (api.Metadata, error)

func MissingQuery

func MissingQuery(w http.ResponseWriter, field string)

func ResolveConfig

func ResolveConfig(configs Getter, resolver Resolver, resolverMetrics *metrics.Metrics) http.HandlerFunc

func ResolveConfigWithInjectedTest

func ResolveConfigWithInjectedTest(configs Getter, resolver Resolver, resolverMetrics *metrics.Metrics) http.HandlerFunc

func ResolveLiteralConfig

func ResolveLiteralConfig(resolver Resolver, resolverMetrics *metrics.Metrics) http.HandlerFunc

Types

type Getter

type Getter interface {
	// GetMatchingConfig loads a configuration that matches the metadata,
	// allowing for regex matching on branch names.
	GetMatchingConfig(metadata api.Metadata) (api.ReleaseBuildConfiguration, error)
}

type Resolver

type Resolver interface {
	ResolveConfig(config api.ReleaseBuildConfiguration) (api.ReleaseBuildConfiguration, error)
}

type ResolverClient

type ResolverClient interface {
	Config(*api.Metadata) (*api.ReleaseBuildConfiguration, error)
	ConfigWithTest(base *api.Metadata, testSource *api.MetadataWithTest) (*api.ReleaseBuildConfiguration, error)
	Resolve([]byte) (*api.ReleaseBuildConfiguration, error)
}

func NewResolverClient

func NewResolverClient(address string) ResolverClient

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
t or T : Toggle theme light dark auto
y or Y : Canonical URL