api

package
v0.3.5 Latest Latest
Warning

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

Go to latest
Published: Mar 14, 2019 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ReasonAvailable  = "Available"
	ReasonCreating   = "Creating"
	ReasonUpdating   = "Updating"
	ReasonDeprecated = string(releaseapi.CanaryTrasitionDeprecated)
	ReasonAdopted    = string(releaseapi.CanaryTrasitionAdopted)
	ReasonError      = "Error"
)
View Source
const (
	CanaryReleaseKind = "CanaryRelease"
)

Variables

View Source
var (
	LabelKeyCreatedBy        = fmt.Sprintf("%s.%s/created-by", "canary", releaseapi.GroupName)
	LabelValueFormatCreateby = "%s.%s"
)

Functions

func NewCondition

func NewCondition(reason, message string) releaseapi.CanaryReleaseCondition

NewCondition creates a new Condition

func NewConditionFrom

func NewConditionFrom(err error) releaseapi.CanaryReleaseCondition

NewConditionFrom creates a new condition from error

Types

type Endpoint

type Endpoint struct {
	// Address IP address of the endpoint
	Address string `json:"address"`
	// Port number of the port
	Port int32 `json:"port"`
	// Weight of the endpoint
	Weight int32 `json:"weight"`
}

Endpoint describes a endpoint in a backend In this case, it is also a kubernetes server not endpoirnt

type L4Backend

type L4Backend struct {
	Port      int32         `json:"port"`
	Name      string        `json:"name"`
	Namespace string        `json:"namespace"`
	Protocol  core.Protocol `json:"protocol"`
}

L4Backend describes the kubernetes service behind L4 Ingress service

type L4Service

type L4Service struct {
	// Port extenrnal port to expose
	Port int32 `json:"port"`
	// Backend of the service
	Backend L4Backend `json:"backend"`
	// Endpoints active endpoints of the service
	Endpoints []Endpoint `json:"endpoints"`
}

L4Service describes a L4 service.

func (L4Service) Equal

func (s L4Service) Equal(s2 L4Service) bool

Equal tests for equality between two L4Service types

Jump to

Keyboard shortcuts

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