Documentation ¶
Index ¶
- Variables
- type ProvisionImpl
- func (r *ProvisionImpl) CreateDataset(ref *types.NamespacedName, bucket *ProvisionedBucket, ...) error
- func (r *ProvisionImpl) DeleteDataset(ref *types.NamespacedName) error
- func (r *ProvisionImpl) GetDatasetStatus(ref *types.NamespacedName) (*ProvisionedStorageStatus, error)
- func (r *ProvisionImpl) SetPersistent(ref *types.NamespacedName, persistent bool) error
- type ProvisionInterface
- type ProvisionTest
- func (r *ProvisionTest) CreateDataset(ref *types.NamespacedName, dataset *ProvisionedBucket, ...) error
- func (r *ProvisionTest) DeleteDataset(ref *types.NamespacedName) error
- func (r *ProvisionTest) GetDatasetStatus(ref *types.NamespacedName) (*ProvisionedStorageStatus, error)
- func (r *ProvisionTest) SetPersistent(ref *types.NamespacedName, persistent bool) error
- type ProvisionedBucket
- type ProvisionedStorageStatus
Constants ¶
This section is empty.
Variables ¶
var ( // GroupVersion is group version used to register these objects GroupVersion = schema.GroupVersion{Group: "com.ie.ibm.hpsys", Version: "v1alpha1"} )
Functions ¶
This section is empty.
Types ¶
type ProvisionImpl ¶
ProvisionImpl is an implementation of ProvisionInterface using Dataset CRDs
func NewProvisionImpl ¶
func NewProvisionImpl(c client.Client) *ProvisionImpl
NewProvisionImpl returns a new ProvisionImpl object
func (*ProvisionImpl) CreateDataset ¶
func (r *ProvisionImpl) CreateDataset(ref *types.NamespacedName, bucket *ProvisionedBucket, owner *types.NamespacedName) error
CreateDataset generates a Dataset resource
func (*ProvisionImpl) DeleteDataset ¶
func (r *ProvisionImpl) DeleteDataset(ref *types.NamespacedName) error
DeleteDataset deletes the existing Dataset resource
func (*ProvisionImpl) GetDatasetStatus ¶
func (r *ProvisionImpl) GetDatasetStatus(ref *types.NamespacedName) (*ProvisionedStorageStatus, error)
GetDatasetStatus returns status of an existing Dataset resource.
func (*ProvisionImpl) SetPersistent ¶
func (r *ProvisionImpl) SetPersistent(ref *types.NamespacedName, persistent bool) error
SetPersistent updates a "remove-on-delete" label of the existing Dataset resource
type ProvisionInterface ¶
type ProvisionInterface interface { CreateDataset(ref *types.NamespacedName, dataset *ProvisionedBucket, owner *types.NamespacedName) error DeleteDataset(ref *types.NamespacedName) error GetDatasetStatus(ref *types.NamespacedName) (*ProvisionedStorageStatus, error) SetPersistent(ref *types.NamespacedName, persistent bool) error }
ProvisionInterface is an interface for managing dynamically allocated Dataset resources
type ProvisionTest ¶
type ProvisionTest struct {
// contains filtered or unexported fields
}
ProvisionTest is an implementation of ProvisionInterface used for testing
func NewProvisionTest ¶
func NewProvisionTest() *ProvisionTest
NewProvisionTest constructs a new ProvisionTest object
func (*ProvisionTest) CreateDataset ¶
func (r *ProvisionTest) CreateDataset(ref *types.NamespacedName, dataset *ProvisionedBucket, owner *types.NamespacedName) error
CreateDataset generates a new dataset
func (*ProvisionTest) DeleteDataset ¶
func (r *ProvisionTest) DeleteDataset(ref *types.NamespacedName) error
DeleteDataset removes an existing dataset
func (*ProvisionTest) GetDatasetStatus ¶
func (r *ProvisionTest) GetDatasetStatus(ref *types.NamespacedName) (*ProvisionedStorageStatus, error)
GetDatasetStatus returns status of an existing Dataset resource.
func (*ProvisionTest) SetPersistent ¶
func (r *ProvisionTest) SetPersistent(ref *types.NamespacedName, persistent bool) error
SetPersistent does nothing for the testing implementation except for verifying that the dataset exists
type ProvisionedBucket ¶
type ProvisionedBucket struct { // Bucket name Name string // Endpoint Endpoint string // Secret containing credentials SecretRef types.NamespacedName }
ProvisionedBucket holds information about the bucket to be provisioned. In the future releases this structure may be extented to include other data store types.
type ProvisionedStorageStatus ¶
ProvisionedStorageStatus includes the status of the provisioning and an error message if the provisioning has failed