types

package
v1.1.5 Latest Latest
Warning

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

Go to latest
Published: Sep 17, 2024 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Overview

Copyright paskal.maksim@gmail.com Licensed under the Apache License, Version 2.0 (the "License") you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Index

Constants

This section is empty.

Variables

View Source
var ErrNewReleaseBadQuality = errors.New("new release failed by quality gate")

Functions

This section is empty.

Types

type CanaryProviderMetrics added in v1.1.2

type CanaryProviderMetrics struct {
	TotalSamplesQLs []string
	BadSamplesQLs   []string
}

type CanaryProviderPercent added in v1.1.2

type CanaryProviderPercent uint8
const (
	CanaryProviderPercentMax CanaryProviderPercent = 100
	CanaryProviderPercentMin CanaryProviderPercent = 0
)

func (CanaryProviderPercent) Validate added in v1.1.3

func (c CanaryProviderPercent) Validate() error

type CanaryProviderPromQLType added in v1.1.3

type CanaryProviderPromQLType string
const (
	CanaryProviderPromQLTypeCanary CanaryProviderPromQLType = "CanaryProviderPromQLTypeCanary"
	CanaryProviderPromQLTypeABTest CanaryProviderPromQLType = "CanaryProviderPromQLTypeABTest"
	CanaryProviderPromQLTypeFull   CanaryProviderPromQLType = "CanaryProviderPromQLTypeFull"
)

func (CanaryProviderPromQLType) HasValue added in v1.1.3

func (c CanaryProviderPromQLType) HasValue() bool

func (CanaryProviderPromQLType) Validate added in v1.1.3

func (c CanaryProviderPromQLType) Validate() error

type ServiceMesh added in v1.1.2

type ServiceMesh interface {
	// set canary percent
	SetCanaryPercent(ctx context.Context, percent CanaryProviderPercent) error
	// set service to canary mode
	SetServiceCanaryMode(ctx context.Context, service string, isStart bool) error
	// set service to ABTest mode
	SetServiceABTestMode(ctx context.Context, service string, isStart bool) error
	// Deprecated: use CanaryPhaseQualityGate
	// get prometheus expression for analyse bad status
	GetPromQL(promQLType CanaryProviderPromQLType, budgetSeconds int) (*CanaryProviderMetrics, error)
}

type ServiceMeshConfig added in v1.1.2

type ServiceMeshConfig struct {
	ServiceMesh string
	Config      string
	Namespace   string
}

type Version

type Version struct {
	Scope string
	Value string
}

func NewVersion

func NewVersion(scope, value string) Version

func (Version) IsNotEmpty added in v1.1.2

func (v Version) IsNotEmpty() bool

func (Version) Key

func (v Version) Key() string

func (Version) String

func (v Version) String() string

Jump to

Keyboard shortcuts

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