validation

package
v1.18.0-beta32 Latest Latest
Warning

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

Go to latest
Published: Nov 5, 2024 License: Apache-2.0 Imports: 24 Imported by: 2

Documentation

Index

Constants

View Source
const GlooGroup = "gloo.solo.io"

Variables

View Source
var SyncNotCalledError = eris.New("proxy validation called before the validation server received its first sync of resources")

Functions

func HandleResourceDeletion added in v1.17.9

func HandleResourceDeletion(snapshot *v1snap.ApiSnapshot, resource resources.Resource) error

func NewValidationServer

func NewValidationServer() *validationServer

func NewValidator added in v0.20.2

func NewValidator(config ValidatorConfig) *validator

Types

type GlooValidationReport added in v1.13.0

type GlooValidationReport struct {
	Proxy           *gloov1.Proxy
	ProxyReport     *validation.ProxyReport
	ResourceReports reporter.ResourceReports
}

type GlooValidator added in v1.13.0

type GlooValidator interface {
	Validate(ctx context.Context, proxy *gloov1.Proxy, snapshot *gloosnapshot.ApiSnapshot, shouldDelete bool) []*GlooValidationReport
}

GlooValidator is used to validate solo.io.gloo resources

func NewGlooValidator added in v1.13.0

func NewGlooValidator(config GlooValidatorConfig) GlooValidator

NewGlooValidator will create a new GlooValidator

type GlooValidatorConfig added in v1.13.0

type GlooValidatorConfig struct {
	Translator   gloo_translator.Translator
	XdsSanitizer sanitizer.XdsSanitizer
	Settings     *v1.Settings
}

type ValidationServer

type ValidationServer interface {
	validation.GlooValidationServiceServer
	SetValidator(v Validator)
	Register(grpcServer *grpc.Server)
}

type Validator added in v0.20.2

type Validator interface {
	v1snap.ApiSyncer
	validation.GlooValidationServiceServer
	ValidateGloo(ctx context.Context, proxy *v1.Proxy, resource resources.Resource, shouldDelete bool) ([]*GlooValidationReport, error)
}

type ValidatorConfig added in v1.13.0

type ValidatorConfig struct {
	Ctx                 context.Context
	GlooValidatorConfig GlooValidatorConfig
}

ValidatorConfig is used to configure the validator

Jump to

Keyboard shortcuts

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