upgradesteps

package
v0.0.0-...-7db8050 Latest Latest
Warning

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

Go to latest
Published: Apr 24, 2024 License: AGPL-3.0 Imports: 12 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Register

func Register(registry facade.FacadeRegistry)

Register is called to expose a package of facades onto a given registry.

Types

type Machine

type Machine interface {
	ContainerType() instance.ContainerType
	ModificationStatus() (status.StatusInfo, error)
	SetModificationStatus(status.StatusInfo) error
}

Machine represents point of use methods from the state machine object

type Unit

type Unit interface {
	SetStateOperation(*state.UnitState, state.UnitStateSizeLimits) state.ModelOperation
}

Unit represents point of use methods from the state unit object

type UpgradeStepsAPI

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

UpgradeStepsAPI implements version 2 of the Upgrade Steps API, which adds WriteUniterState.

func NewUpgradeStepsAPI

func NewUpgradeStepsAPI(st UpgradeStepsState,
	resources facade.Resources,
	authorizer facade.Authorizer,
) (*UpgradeStepsAPI, error)

func (*UpgradeStepsAPI) ResetKVMMachineModificationStatusIdle

func (api *UpgradeStepsAPI) ResetKVMMachineModificationStatusIdle(arg params.Entity) (params.ErrorResult, error)

ResetKVMMachineModificationStatusIdle sets the modification status of a kvm machine to idle if it is in an error state before upgrade. Related to lp:1829393.

func (*UpgradeStepsAPI) WriteAgentState

func (api *UpgradeStepsAPI) WriteAgentState(args params.SetUnitStateArgs) (params.ErrorResults, error)

WriteAgentState writes the agent state for the set of units provided. This call presently deals with the state for the unit agent.

type UpgradeStepsAPIV1

type UpgradeStepsAPIV1 struct {
	*UpgradeStepsAPI
}

UpgradeStepsAPIV1 implements version 1 of the Upgrade Steps API.

type UpgradeStepsState

type UpgradeStepsState interface {
	state.EntityFinder
	ControllerConfig() (controller.Config, error)
	ApplyOperation(state.ModelOperation) error
}

type UpgradeStepsV1

type UpgradeStepsV1 interface {
	ResetKVMMachineModificationStatusIdle(params.Entity) (params.ErrorResult, error)
}

UpgradeStepsV1 defines the methods on the version 2 facade for the upgrade steps API endpoint.

type UpgradeStepsV2

type UpgradeStepsV2 interface {
	UpgradeStepsV1
	WriteAgentState(params.SetUnitStateArgs) (params.ErrorResults, error)
}

UpgradeStepsV2 defines the methods on the version 2 facade for the upgrade steps API endpoint.

Directories

Path Synopsis
Package mocks is a generated GoMock package.
Package mocks is a generated GoMock package.

Jump to

Keyboard shortcuts

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