juju: github.com/juju/juju/apiserver/facades/agent/storageprovisioner Index | Files | Directories

package storageprovisioner

import "github.com/juju/juju/apiserver/facades/agent/storageprovisioner"

Index

Package Files

shim.go storageprovisioner.go

func NewStateBackends Uses

func NewStateBackends(st *state.State) (Backend, StorageBackend, error)

NewStateBackends creates a Backend from the given *state.State.

type Backend Uses

type Backend interface {
    state.EntityFinder
    state.ModelAccessor

    ControllerConfig() (controller.Config, error)
    MachineInstanceId(names.MachineTag) (instance.Id, error)
    ModelTag() names.ModelTag
    WatchMachine(names.MachineTag) (state.NotifyWatcher, error)
    WatchApplications() state.StringsWatcher
}

type StorageBackend Uses

type StorageBackend interface {
    BlockDevices(names.MachineTag) ([]state.BlockDeviceInfo, error)

    WatchBlockDevices(names.MachineTag) state.NotifyWatcher
    WatchModelFilesystems() state.StringsWatcher
    WatchModelFilesystemAttachments() state.StringsWatcher
    WatchMachineFilesystems(names.MachineTag) state.StringsWatcher
    WatchUnitFilesystems(tag names.ApplicationTag) state.StringsWatcher
    WatchMachineFilesystemAttachments(names.MachineTag) state.StringsWatcher
    WatchUnitFilesystemAttachments(tag names.ApplicationTag) state.StringsWatcher
    WatchModelVolumes() state.StringsWatcher
    WatchModelVolumeAttachments() state.StringsWatcher
    WatchMachineVolumes(names.MachineTag) state.StringsWatcher
    WatchMachineVolumeAttachments(names.MachineTag) state.StringsWatcher
    WatchUnitVolumeAttachments(tag names.ApplicationTag) state.StringsWatcher
    WatchVolumeAttachment(names.Tag, names.VolumeTag) state.NotifyWatcher
    WatchMachineAttachmentsPlans(names.MachineTag) state.StringsWatcher

    StorageInstance(names.StorageTag) (state.StorageInstance, error)
    AllStorageInstances() ([]state.StorageInstance, error)
    StorageInstanceVolume(names.StorageTag) (state.Volume, error)
    StorageInstanceFilesystem(names.StorageTag) (state.Filesystem, error)
    ReleaseStorageInstance(names.StorageTag, bool, bool, time.Duration) error
    DetachStorage(names.StorageTag, names.UnitTag, bool, time.Duration) error

    Filesystem(names.FilesystemTag) (state.Filesystem, error)
    FilesystemAttachment(names.Tag, names.FilesystemTag) (state.FilesystemAttachment, error)

    Volume(names.VolumeTag) (state.Volume, error)
    VolumeAttachment(names.Tag, names.VolumeTag) (state.VolumeAttachment, error)
    VolumeAttachments(names.VolumeTag) ([]state.VolumeAttachment, error)
    VolumeAttachmentPlan(names.Tag, names.VolumeTag) (state.VolumeAttachmentPlan, error)
    VolumeAttachmentPlans(volume names.VolumeTag) ([]state.VolumeAttachmentPlan, error)

    RemoveFilesystem(names.FilesystemTag) error
    RemoveFilesystemAttachment(names.Tag, names.FilesystemTag) error
    RemoveVolume(names.VolumeTag) error
    RemoveVolumeAttachment(names.Tag, names.VolumeTag) error
    DetachFilesystem(names.Tag, names.FilesystemTag) error
    DestroyFilesystem(names.FilesystemTag) error
    DetachVolume(names.Tag, names.VolumeTag) error
    DestroyVolume(names.VolumeTag) error

    SetFilesystemInfo(names.FilesystemTag, state.FilesystemInfo) error
    SetFilesystemAttachmentInfo(names.Tag, names.FilesystemTag, state.FilesystemAttachmentInfo) error
    SetVolumeInfo(names.VolumeTag, state.VolumeInfo) error
    SetVolumeAttachmentInfo(names.Tag, names.VolumeTag, state.VolumeAttachmentInfo) error

    CreateVolumeAttachmentPlan(names.Tag, names.VolumeTag, state.VolumeAttachmentPlanInfo) error
    RemoveVolumeAttachmentPlan(names.Tag, names.VolumeTag) error
    SetVolumeAttachmentPlanBlockInfo(machineTag names.Tag, volumeTag names.VolumeTag, info state.BlockDeviceInfo) error
}

type StorageProvisionerAPIv3 Uses

type StorageProvisionerAPIv3 struct {
    *common.LifeGetter
    *common.DeadEnsurer
    *common.InstanceIdGetter
    *common.StatusSetter
    // contains filtered or unexported fields
}

StorageProvisionerAPIv3 provides the StorageProvisioner API v3 facade.

func NewFacadeV3 Uses

func NewFacadeV3(st *state.State, resources facade.Resources, authorizer facade.Authorizer) (*StorageProvisionerAPIv3, error)

NewFacadeV3 provides the signature required for facade registration.

func NewStorageProvisionerAPIv3 Uses

func NewStorageProvisionerAPIv3(
    st Backend,
    sb StorageBackend,
    resources facade.Resources,
    authorizer facade.Authorizer,
    registry storage.ProviderRegistry,
    poolManager poolmanager.PoolManager,
) (*StorageProvisionerAPIv3, error)

NewStorageProvisionerAPIv3 creates a new server-side StorageProvisioner v3 facade.

func (*StorageProvisionerAPIv3) AttachmentLife Uses

func (s *StorageProvisionerAPIv3) AttachmentLife(args params.MachineStorageIds) (params.LifeResults, error)

AttachmentLife returns the lifecycle state of each specified machine storage attachment.

func (*StorageProvisionerAPIv3) CreateVolumeAttachmentPlans Uses

func (s *StorageProvisionerAPIv3) CreateVolumeAttachmentPlans(args params.VolumeAttachmentPlans) (params.ErrorResults, error)

func (*StorageProvisionerAPIv3) FilesystemAttachmentParams Uses

func (s *StorageProvisionerAPIv3) FilesystemAttachmentParams(
    args params.MachineStorageIds,
) (params.FilesystemAttachmentParamsResults, error)

FilesystemAttachmentParams returns the parameters for creating the filesystem attachments with the specified IDs.

func (*StorageProvisionerAPIv3) FilesystemAttachments Uses

func (s *StorageProvisionerAPIv3) FilesystemAttachments(args params.MachineStorageIds) (params.FilesystemAttachmentResults, error)

FilesystemAttachments returns details of filesystem attachments with the specified IDs.

func (*StorageProvisionerAPIv3) FilesystemParams Uses

func (s *StorageProvisionerAPIv3) FilesystemParams(args params.Entities) (params.FilesystemParamsResults, error)

FilesystemParams returns the parameters for creating the filesystems with the specified tags.

func (*StorageProvisionerAPIv3) Filesystems Uses

func (s *StorageProvisionerAPIv3) Filesystems(args params.Entities) (params.FilesystemResults, error)

Filesystems returns details of filesystems with the specified tags.

func (*StorageProvisionerAPIv3) Remove Uses

func (s *StorageProvisionerAPIv3) Remove(args params.Entities) (params.ErrorResults, error)

Remove removes volumes and filesystems from state.

func (*StorageProvisionerAPIv3) RemoveAttachment Uses

func (s *StorageProvisionerAPIv3) RemoveAttachment(args params.MachineStorageIds) (params.ErrorResults, error)

RemoveAttachments removes the specified machine storage attachments from state.

func (*StorageProvisionerAPIv3) RemoveVolumeAttachmentPlan Uses

func (s *StorageProvisionerAPIv3) RemoveVolumeAttachmentPlan(args params.MachineStorageIds) (params.ErrorResults, error)

func (*StorageProvisionerAPIv3) SetFilesystemAttachmentInfo Uses

func (s *StorageProvisionerAPIv3) SetFilesystemAttachmentInfo(
    args params.FilesystemAttachments,
) (params.ErrorResults, error)

SetFilesystemAttachmentInfo records the details of newly provisioned filesystem attachments.

func (*StorageProvisionerAPIv3) SetFilesystemInfo Uses

func (s *StorageProvisionerAPIv3) SetFilesystemInfo(args params.Filesystems) (params.ErrorResults, error)

SetFilesystemInfo records the details of newly provisioned filesystems.

func (*StorageProvisionerAPIv3) SetVolumeAttachmentInfo Uses

func (s *StorageProvisionerAPIv3) SetVolumeAttachmentInfo(
    args params.VolumeAttachments,
) (params.ErrorResults, error)

SetVolumeAttachmentInfo records the details of newly provisioned volume attachments.

func (*StorageProvisionerAPIv3) SetVolumeAttachmentPlanBlockInfo Uses

func (s *StorageProvisionerAPIv3) SetVolumeAttachmentPlanBlockInfo(args params.VolumeAttachmentPlans) (params.ErrorResults, error)

func (*StorageProvisionerAPIv3) SetVolumeInfo Uses

func (s *StorageProvisionerAPIv3) SetVolumeInfo(args params.Volumes) (params.ErrorResults, error)

SetVolumeInfo records the details of newly provisioned volumes.

func (*StorageProvisionerAPIv3) VolumeAttachmentParams Uses

func (s *StorageProvisionerAPIv3) VolumeAttachmentParams(
    args params.MachineStorageIds,
) (params.VolumeAttachmentParamsResults, error)

VolumeAttachmentParams returns the parameters for creating the volume attachments with the specified IDs.

func (*StorageProvisionerAPIv3) VolumeAttachmentPlans Uses

func (s *StorageProvisionerAPIv3) VolumeAttachmentPlans(args params.MachineStorageIds) (params.VolumeAttachmentPlanResults, error)

VolumeAttachmentPlans returns details of volume attachment plans with the specified IDs.

func (*StorageProvisionerAPIv3) VolumeAttachments Uses

func (s *StorageProvisionerAPIv3) VolumeAttachments(args params.MachineStorageIds) (params.VolumeAttachmentResults, error)

VolumeAttachments returns details of volume attachments with the specified IDs.

func (*StorageProvisionerAPIv3) VolumeBlockDevices Uses

func (s *StorageProvisionerAPIv3) VolumeBlockDevices(args params.MachineStorageIds) (params.BlockDeviceResults, error)

VolumeBlockDevices returns details of the block devices corresponding to the volume attachments with the specified IDs.

func (*StorageProvisionerAPIv3) VolumeParams Uses

func (s *StorageProvisionerAPIv3) VolumeParams(args params.Entities) (params.VolumeParamsResults, error)

VolumeParams returns the parameters for creating or destroying the volumes with the specified tags.

func (*StorageProvisionerAPIv3) Volumes Uses

func (s *StorageProvisionerAPIv3) Volumes(args params.Entities) (params.VolumeResults, error)

Volumes returns details of volumes with the specified tags.

func (*StorageProvisionerAPIv3) WatchBlockDevices Uses

func (s *StorageProvisionerAPIv3) WatchBlockDevices(args params.Entities) (params.NotifyWatchResults, error)

WatchBlockDevices watches for changes to the specified machines' block devices.

func (*StorageProvisionerAPIv3) WatchFilesystemAttachments Uses

func (s *StorageProvisionerAPIv3) WatchFilesystemAttachments(args params.Entities) (params.MachineStorageIdsWatchResults, error)

WatchFilesystemAttachments watches for changes to filesystem attachments scoped to the entity with the tag passed to NewState.

func (*StorageProvisionerAPIv3) WatchFilesystems Uses

func (s *StorageProvisionerAPIv3) WatchFilesystems(args params.Entities) (params.StringsWatchResults, error)

WatchFilesystems watches for changes to filesystems scoped to the entity with the tag passed to NewState.

func (*StorageProvisionerAPIv3) WatchMachines Uses

func (s *StorageProvisionerAPIv3) WatchMachines(args params.Entities) (params.NotifyWatchResults, error)

WatchMachines watches for changes to the specified machines.

func (*StorageProvisionerAPIv3) WatchVolumeAttachmentPlans Uses

func (s *StorageProvisionerAPIv3) WatchVolumeAttachmentPlans(args params.Entities) (params.MachineStorageIdsWatchResults, error)

WatchVolumeAttachmentPlans watches for changes to volume attachments for a machine for the purpose of allowing that machine to run any initialization needed, for that volume to actually appear as a block device (ie: iSCSI)

func (*StorageProvisionerAPIv3) WatchVolumeAttachments Uses

func (s *StorageProvisionerAPIv3) WatchVolumeAttachments(args params.Entities) (params.MachineStorageIdsWatchResults, error)

WatchVolumeAttachments watches for changes to volume attachments scoped to the entity with the tag passed to NewState.

func (*StorageProvisionerAPIv3) WatchVolumes Uses

func (s *StorageProvisionerAPIv3) WatchVolumes(args params.Entities) (params.StringsWatchResults, error)

WatchVolumes watches for changes to volumes scoped to the entity with the tag passed to NewState.

type StorageProvisionerAPIv4 Uses

type StorageProvisionerAPIv4 struct {
    *StorageProvisionerAPIv3
}

StorageProvisionerAPIv4 provides the StorageProvisioner API v4 facade.

func NewFacadeV4 Uses

func NewFacadeV4(st *state.State, resources facade.Resources, authorizer facade.Authorizer) (*StorageProvisionerAPIv4, error)

NewFacadeV4 provides the signature required for facade registration.

func NewStorageProvisionerAPIv4 Uses

func NewStorageProvisionerAPIv4(v3 *StorageProvisionerAPIv3) *StorageProvisionerAPIv4

NewStorageProvisionerAPIv4 creates a new server-side StorageProvisioner v4 facade.

func (*StorageProvisionerAPIv4) RemoveFilesystemParams Uses

func (s *StorageProvisionerAPIv4) RemoveFilesystemParams(args params.Entities) (params.RemoveFilesystemParamsResults, error)

RemoveFilesystemParams returns the parameters for destroying or releasing the filesystems with the specified tags.

func (*StorageProvisionerAPIv4) RemoveVolumeParams Uses

func (s *StorageProvisionerAPIv4) RemoveVolumeParams(args params.Entities) (params.RemoveVolumeParamsResults, error)

RemoveVolumeParams returns the parameters for destroying or releasing the volumes with the specified tags.

func (*StorageProvisionerAPIv4) WatchApplications Uses

func (s *StorageProvisionerAPIv4) WatchApplications() (params.StringsWatchResult, error)

WatchApplications starts a StringsWatcher to watch CAAS applications deployed to this model.

Directories

PathSynopsis
internal/filesystemwatcher

Package storageprovisioner imports 18 packages (graph) and is imported by 3 packages. Updated 2019-09-01. Refresh now. Tools for package owners.