highavailability

package
v0.0.0-...-756137a Latest Latest
Warning

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

Go to latest
Published: Feb 28, 2025 License: AGPL-3.0 Imports: 27 Imported by: 2

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 ApplicationService

type ApplicationService interface {
	AddUnits(ctx context.Context, name string, units ...applicationservice.AddUnitArg) error
}

ApplicationService instances add units to an application in dqlite state.

type BlockCommandService

type BlockCommandService interface {
	// GetBlockSwitchedOn returns the optional block message if it is switched
	// on for the given type.
	GetBlockSwitchedOn(ctx context.Context, t blockcommand.BlockType) (string, error)

	// GetBlocks returns all the blocks that are currently in place.
	GetBlocks(ctx context.Context) ([]blockcommand.Block, error)
}

BlockCommandService defines methods for interacting with block commands.

type ControllerConfigService

type ControllerConfigService interface {
	ControllerConfig(ctx context.Context) (controller.Config, error)
}

ControllerConfigService instances read the controller config.

type HighAvailabilityAPI

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

HighAvailabilityAPI implements the HighAvailability interface and is the concrete implementation of the api end point.

func (*HighAvailabilityAPI) ControllerDetails

func (api *HighAvailabilityAPI) ControllerDetails(
	ctx context.Context,
) (params.ControllerDetailsResults, error)

ControllerDetails returns details about each controller node.

func (*HighAvailabilityAPI) EnableHA

EnableHA adds controller machines as necessary to ensure the controller has the number of machines specified.

type HighAvailabilityAPIV2

type HighAvailabilityAPIV2 struct {
	HighAvailabilityAPI
}

HighAvailabilityAPIV2 implements v2 of the high availability facade.

func (*HighAvailabilityAPIV2) ControllerDetails

func (api *HighAvailabilityAPIV2) ControllerDetails(_ struct{})

ControllerDetails is only available on V3 or later.

type MachineService

type MachineService interface {
	CreateMachine(context.Context, machine.Name) (string, error)
}

MachineService instances save a machine to dqlite state.

type NetworkService

type NetworkService interface {
	// GetAllSpaces returns all spaces for the model.
	GetAllSpaces(ctx context.Context) (network.SpaceInfos, error)
}

NetworkService is the interface that is used to interact with the network spaces/subnets.

type NodeService

type NodeService interface {
	// CurateNodes modifies the control place by adding and
	// removing node entries based on the input slices.
	CurateNodes(context.Context, []string, []string) error
}

NodeService describes the maintenance of controller entries.

Jump to

Keyboard shortcuts

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