release

package
v0.3.0-beta.0 Latest Latest
Warning

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

Go to latest
Published: Jun 12, 2019 License: Apache-2.0 Imports: 30 Imported by: 0

Documentation

Index

Constants

View Source
const (
	AgentName = "release-controller"
)

Variables

This section is empty.

Functions

func NewNotEnoughCapableClustersInRegionError

func NewNotEnoughCapableClustersInRegionError(region string, capabilities []string, required, available int) error

Types

type BrokenChartError

type BrokenChartError struct {
	ChartError
	// contains filtered or unexported fields
}

func NewBrokenChartError

func NewBrokenChartError(chartName, chartVersion, chartRepo string, err error) BrokenChartError

func (BrokenChartError) Error

func (e BrokenChartError) Error() string

type CapacityTargetOutdatedResult

type CapacityTargetOutdatedResult struct {
	Name    string
	NewSpec *shipper.CapacityTargetSpec
}

func (*CapacityTargetOutdatedResult) PatchSpec

type ChartError

type ChartError struct {
	// contains filtered or unexported fields
}

type ChartFetchFailureError

type ChartFetchFailureError struct {
	ChartError
	// contains filtered or unexported fields
}

func NewChartFetchFailureError

func NewChartFetchFailureError(chartName, chartVersion, chartRepo string, err error) ChartFetchFailureError

func (ChartFetchFailureError) Error

func (e ChartFetchFailureError) Error() string

type Controller

type Controller struct {
	// contains filtered or unexported fields
}

Controller is a Kubernetes controller whose role is to pick up a newly created release and progress it forward by scheduling the release on a set of selected clusters, creating a set of associated objects and executing the strategy.

Release Controller has 2 primary workqueues: releases and applications.

func NewController

func NewController(
	clientset shipperclient.Interface,
	informerFactory shipperinformers.SharedInformerFactory,
	chartFetchFunc chart.FetchFunc,
	recorder record.EventRecorder,
) *Controller

func (*Controller) Run

func (c *Controller) Run(threadiness int, stopCh <-chan struct{})

Run starts Release Controller workers and waits until stopCh is closed.

type DuplicateCapabilityRequirementError

type DuplicateCapabilityRequirementError struct {
	// contains filtered or unexported fields
}

func NewDuplicateCapabilityRequirementError

func NewDuplicateCapabilityRequirementError(capability string) DuplicateCapabilityRequirementError

func (DuplicateCapabilityRequirementError) Error

type Executor

type Executor struct {
	// contains filtered or unexported fields
}

func (*Executor) Execute

Execute executes the strategy. It returns an ExecutorResult, if a patch should be performed into some of the associated Release objects and an error if an error has happened. Currently if both values are nil it means that the operation was successful but no modifications are required.

type ExecutorResult

type ExecutorResult interface {
	PatchSpec() (string, schema.GroupVersionKind, []byte)
}

type FailedAPICallError

type FailedAPICallError struct {
	// contains filtered or unexported fields
}

func NewFailedAPICallError

func NewFailedAPICallError(call string, err error) FailedAPICallError

func (FailedAPICallError) Error

func (e FailedAPICallError) Error() string

type InvalidReleaseOwnerRefsError

type InvalidReleaseOwnerRefsError struct {
	// contains filtered or unexported fields
}

func NewInvalidReleaseOwnerRefsError

func NewInvalidReleaseOwnerRefsError(count int) InvalidReleaseOwnerRefsError

func (InvalidReleaseOwnerRefsError) Error

type NoRegionsSpecifiedError

type NoRegionsSpecifiedError struct{}

func NewNoRegionsSpecifiedError

func NewNoRegionsSpecifiedError() NoRegionsSpecifiedError

func (NoRegionsSpecifiedError) Error

func (e NoRegionsSpecifiedError) Error() string

type NotEnoughCapableClustersInRegionError

type NotEnoughCapableClustersInRegionError struct {
	// contains filtered or unexported fields
}

func (NotEnoughCapableClustersInRegionError) Error

type NotEnoughClustersInRegionError

type NotEnoughClustersInRegionError struct {
	// contains filtered or unexported fields
}

func NewNotEnoughClustersInRegionError

func NewNotEnoughClustersInRegionError(region string, required, available int) NotEnoughClustersInRegionError

func (NotEnoughClustersInRegionError) Error

type NotWorkingOnStrategyError

type NotWorkingOnStrategyError struct {
	// contains filtered or unexported fields
}

func NewNotWorkingOnStrategyError

func NewNotWorkingOnStrategyError(contenderReleaseKey string) NotWorkingOnStrategyError

func (NotWorkingOnStrategyError) Error

type ReleaseStrategyStateTransition

type ReleaseStrategyStateTransition struct {
	State    string
	Previous shipper.StrategyState
	New      shipper.StrategyState
}

type ReleaseUpdateResult

type ReleaseUpdateResult struct {
	Name      string
	NewStatus *shipper.ReleaseStatus
}

func (*ReleaseUpdateResult) PatchSpec

func (r *ReleaseUpdateResult) PatchSpec() (string, schema.GroupVersionKind, []byte)

type RetrievingCapacityTargetForReleaseError

type RetrievingCapacityTargetForReleaseError struct {
	// contains filtered or unexported fields
}

func NewRetrievingCapacityTargetForReleaseError

func NewRetrievingCapacityTargetForReleaseError(releaseKey string, err error) RetrievingCapacityTargetForReleaseError

func (RetrievingCapacityTargetForReleaseError) Error

type RetrievingInstallationTargetForReleaseError

type RetrievingInstallationTargetForReleaseError struct {
	// contains filtered or unexported fields
}

func NewRetrievingInstallationTargetForReleaseError

func NewRetrievingInstallationTargetForReleaseError(releaseKey string, err error) RetrievingInstallationTargetForReleaseError

func (RetrievingInstallationTargetForReleaseError) Error

type RetrievingTrafficTargetForReleaseError

type RetrievingTrafficTargetForReleaseError struct {
	// contains filtered or unexported fields
}

func NewRetrievingTrafficTargetForReleaseError

func NewRetrievingTrafficTargetForReleaseError(releaseKey string, err error) RetrievingTrafficTargetForReleaseError

func (RetrievingTrafficTargetForReleaseError) Error

type Scheduler

type Scheduler struct {
	// contains filtered or unexported fields
}

func NewScheduler

func NewScheduler(
	clientset shipperclientset.Interface,
	clusterLister listers.ClusterLister,
	installationTargerLister listers.InstallationTargetLister,
	capacityTargetLister listers.CapacityTargetLister,
	trafficTargetLister listers.TrafficTargetLister,
	fetchChart shipperchart.FetchFunc,
	recorder record.EventRecorder,
) *Scheduler

func (*Scheduler) ChooseClusters

func (s *Scheduler) ChooseClusters(rel *shipper.Release, force bool) (*shipper.Release, error)

func (*Scheduler) CreateOrUpdateCapacityTarget

func (s *Scheduler) CreateOrUpdateCapacityTarget(rel *shipper.Release, totalReplicaCount int32) (*shipper.CapacityTarget, error)

func (*Scheduler) CreateOrUpdateInstallationTarget

func (s *Scheduler) CreateOrUpdateInstallationTarget(rel *shipper.Release) (*shipper.InstallationTarget, error)

func (*Scheduler) CreateOrUpdateTrafficTarget

func (s *Scheduler) CreateOrUpdateTrafficTarget(rel *shipper.Release) (*shipper.TrafficTarget, error)

func (*Scheduler) ScheduleRelease

func (s *Scheduler) ScheduleRelease(rel *shipper.Release) (*shipper.Release, error)

type TrafficTargetOutdatedResult

type TrafficTargetOutdatedResult struct {
	Name    string
	NewSpec *shipper.TrafficTargetSpec
}

func (*TrafficTargetOutdatedResult) PatchSpec

type WrongChartDeploymentsError

type WrongChartDeploymentsError struct {
	ChartError
	// contains filtered or unexported fields
}

func NewWrongChartDeploymentsError

func NewWrongChartDeploymentsError(chartName, chartVersion, chartRepo string, deploymentCount int) WrongChartDeploymentsError

func (WrongChartDeploymentsError) Error

Jump to

Keyboard shortcuts

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