caasapplication

package
v0.0.0-...-9ec3720 Latest Latest
Warning

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

Go to latest
Published: Apr 6, 2021 License: AGPL-3.0 Imports: 21 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Application

type Application interface {
	Life() state.Life
	Charm() (Charm, bool, error)
	Name() string
	AllUnits() ([]Unit, error)
	UpdateUnits(unitsOp *state.UpdateUnitsOperation) error
	AddUnit(args state.AddUnitParams) (unit Unit, err error)
}

Application provides the subset of application state required by the CAAS application facade.

type Charm

type Charm interface {
	Meta() *charm.Meta
}

Charm provides the subset of charm state required by the CAAS application facade.

type ControllerState

type ControllerState interface {
	ControllerConfig() (jujucontroller.Config, error)
	APIHostPortsForAgents() ([]network.SpaceHostPorts, error)
}

ControllerState provides the subset of controller state required by the CAAS application facade.

type Facade

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

func NewFacade

func NewFacade(
	resources facade.Resources,
	authorizer facade.Authorizer,
	ctrlSt ControllerState,
	st State,
	clock clock.Clock,
) (*Facade, error)

NewFacade returns a new CAASOperator facade.

func NewStateFacade

func NewStateFacade(ctx facade.Context) (*Facade, error)

NewStateFacade provides the signature required for facade registration.

func (*Facade) UnitIntroduction

UnitIntroduction sets the status of each given entity.

type Model

type Model interface {
	Containers(providerIds ...string) ([]state.CloudContainer, error)
	AgentVersion() (version.Number, error)
	ControllerTag() names.ControllerTag
	Tag() names.Tag
}

Model provides the subset of CAAS model state required by the CAAS application facade.

type State

type State interface {
	Application(string) (Application, error)
	Model() (Model, error)
	Unit(name string) (Unit, error)
}

State provides the subset of model state required by the CAAS application facade.

type Unit

type Unit interface {
	Tag() names.Tag
	ContainerInfo() (state.CloudContainer, error)
	Life() state.Life
	Refresh() error
	UpdateOperation(props state.UnitUpdateProperties) *state.UpdateUnitOperation
	SetPassword(string) error
}

Jump to

Keyboard shortcuts

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