juju: github.com/juju/juju/apiserver/facades/client/storage Index | Files

package storage

import "github.com/juju/juju/apiserver/facades/client/storage"

Package storage provides an API server facade for managing storage entities.

Index

Package Files

shim.go storage.go

type StorageAPI Uses

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

StorageAPI implements the latest version (v6) of the Storage API.

func NewStorageAPI Uses

func NewStorageAPI(context facade.Context) (*StorageAPI, error)

NewStorageAPI returns a new storage API facade.

func (*StorageAPI) AddToUnit Uses

func (a *StorageAPI) AddToUnit(args params.StoragesAddParams) (params.AddStorageResults, error)

AddToUnit validates and creates additional storage instances for units. A "CHANGE" block can block this operation.

func (*StorageAPI) Attach Uses

func (a *StorageAPI) Attach(args params.StorageAttachmentIds) (params.ErrorResults, error)

Attach attaches existing storage instances to units. A "CHANGE" block can block this operation.

func (*StorageAPI) CreatePool Uses

func (a *StorageAPI) CreatePool(p params.StoragePoolArgs) (params.ErrorResults, error)

CreatePool creates a new pool with specified parameters.

func (*StorageAPI) DetachStorage Uses

func (a *StorageAPI) DetachStorage(args params.StorageDetachmentParams) (params.ErrorResults, error)

DetachStorage sets the specified storage attachments to Dying, unless they are already Dying or Dead. Any associated, persistent storage will remain alive. This call can be forced.

func (*StorageAPI) Import Uses

func (a *StorageAPI) Import(args params.BulkImportStorageParams) (params.ImportStorageResults, error)

Import imports existing storage into the model. A "CHANGE" block can block this operation.

func (*StorageAPI) ListFilesystems Uses

func (a *StorageAPI) ListFilesystems(filters params.FilesystemFilters) (params.FilesystemDetailsListResults, error)

ListFilesystems returns a list of filesystems in the environment matching the provided filter. Each result describes a filesystem in detail, including the filesystem's attachments.

func (*StorageAPI) ListPools Uses

func (a *StorageAPI) ListPools(
    filters params.StoragePoolFilters,
) (params.StoragePoolsResults, error)

ListPools returns a list of pools. If filter is provided, returned list only contains pools that match the filter. Pools can be filtered on names and provider types. If both names and types are provided as filter, pools that match either are returned. This method lists union of pools and environment provider types. If no filter is provided, all pools are returned.

func (*StorageAPI) ListStorageDetails Uses

func (a *StorageAPI) ListStorageDetails(filters params.StorageFilters) (params.StorageDetailsListResults, error)

ListStorageDetails returns storage matching a filter.

func (*StorageAPI) ListVolumes Uses

func (a *StorageAPI) ListVolumes(filters params.VolumeFilters) (params.VolumeDetailsListResults, error)

ListVolumes lists volumes with the given filters. Each filter produces an independent list of volumes, or an error if the filter is invalid or the volumes could not be listed.

func (*StorageAPI) Remove Uses

func (a *StorageAPI) Remove(args params.RemoveStorage) (params.ErrorResults, error)

Remove sets the specified storage entities to Dying, unless they are already Dying or Dead, such that the storage will eventually be removed from the model. If the arguments specify that the storage should be destroyed, then the associated cloud storage will be destroyed first; otherwise it will only be released from Juju's control.

func (*StorageAPI) RemovePool Uses

func (a *StorageAPI) RemovePool(p params.StoragePoolDeleteArgs) (params.ErrorResults, error)

RemovePool deletes the named pool

func (*StorageAPI) StorageDetails Uses

func (a *StorageAPI) StorageDetails(entities params.Entities) (params.StorageDetailsResults, error)

StorageDetails retrieves and returns detailed information about desired storage identified by supplied tags. If specified storage cannot be retrieved, individual error is returned instead of storage information.

func (*StorageAPI) UpdatePool Uses

func (a *StorageAPI) UpdatePool(p params.StoragePoolArgs) (params.ErrorResults, error)

UpdatePool deletes the named pool

type StorageAPIv3 Uses

type StorageAPIv3 struct {
    StorageAPIv4
}

APIv3 implements the storage v3 API.

func NewStorageAPIV3 Uses

func NewStorageAPIV3(context facade.Context) (*StorageAPIv3, error)

NewStorageAPIV3 returns a new storage v3 API facade.

func (*StorageAPIv3) AddToUnit Uses

func (a *StorageAPIv3) AddToUnit(args params.StoragesAddParams) (params.ErrorResults, error)

AddToUnit validates and creates additional storage instances for units. A "CHANGE" block can block this operation.

func (*StorageAPIv3) Destroy Uses

func (a *StorageAPIv3) Destroy(args params.Entities) (params.ErrorResults, error)

Destroy sets the specified storage entities to Dying, unless they are already Dying or Dead.

func (*StorageAPIv3) Import Uses

func (*StorageAPIv3) Import(_, _ struct{})

func (*StorageAPIv3) Remove Uses

func (*StorageAPIv3) Remove(_, _ struct{})

Added in v4 Destroy was dropped in V4, replaced with Remove.

type StorageAPIv4 Uses

type StorageAPIv4 struct {
    StorageAPIv5
}

APIv4 implements the storage v4 API adding AddToUnit, Import and Remove (replacing Destroy)

func NewStorageAPIV4 Uses

func NewStorageAPIV4(context facade.Context) (*StorageAPIv4, error)

NewStorageAPIV4 returns a new storage v4 API facade.

func (*StorageAPIv4) CreatePool Uses

func (a *StorageAPIv4) CreatePool(p params.StoragePool) error

CreatePool creates a new pool with specified parameters.

func (*StorageAPIv4) RemovePool Uses

func (*StorageAPIv4) RemovePool(_, _ struct{})

Added in v5 api version

func (*StorageAPIv4) UpdatePool Uses

func (*StorageAPIv4) UpdatePool(_, _ struct{})

type StorageAPIv5 Uses

type StorageAPIv5 struct {
    StorageAPI
}

APIv5 implements the storage v5 API.

func NewStorageAPIV5 Uses

func NewStorageAPIV5(context facade.Context) (*StorageAPIv5, error)

NewStorageAPIV5 returns a new storage v5 API facade.

func (*StorageAPIv5) Detach Uses

func (a *StorageAPIv5) Detach(args params.StorageAttachmentIds) (params.ErrorResults, error)

Detach sets the specified storage attachments to Dying, unless they are already Dying or Dead. Any associated, persistent storage will remain alive.

func (*StorageAPIv5) DetachStorage Uses

func (*StorageAPIv5) DetachStorage(_, _ struct{})

Added in v6 api version

type Unit Uses

type Unit interface {
    AssignedMachineId() (string, error)
}

Package storage imports 19 packages (graph) and is imported by 3 packages. Updated 2019-09-02. Refresh now. Tools for package owners.