state

package
v0.0.0-...-0d10c26 Latest Latest
Warning

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

Go to latest
Published: Mar 6, 2025 License: AGPL-3.0 Imports: 6 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ModelInfo

type ModelInfo struct {
	// ControllerUUID is the controllers unique id.
	ControllerUUID string `db:"controller_uuid"`
}

ModelInfo represents the model's read only information from the model table in the model database.

type State

type State struct {
	*domain.StateBase
}

State represents the access method for interacting the underlying model during model migration.

func New

func New(modelFactory database.TxnRunnerFactory) *State

New creates a new State

func (*State) GetAllInstanceIDs

func (s *State) GetAllInstanceIDs(ctx context.Context) (set.Strings, error)

GetAllInstanceIDs returns all instance IDs from the current model as juju/collections set.

func (*State) GetControllerUUID

func (s *State) GetControllerUUID(
	ctx context.Context,
) (string, error)

GetControllerUUID is responsible for returning the controller's unique id from state.

Jump to

Keyboard shortcuts

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