Documentation
¶
Overview ¶
Copyright (c) 2019 Dell EMC Corporation All Rights Reserved
Copyright (c) 2019 Dell EMC Corporation All Rights Reserved
Copyright (c) 2019 Dell EMC Corporation All Rights Reserved
- Copyright (c) 2021. Dell Inc., or its subsidiaries. All Rights Reserved. *
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at *
- http://www.apache.org/licenses/LICENSE-2.0 *
Copyright (c) 2019 Dell EMC Corporation All Rights Reserved
Copyright (c) 2019 Dell EMC Corporation All Rights Reserved
Index ¶
- Constants
- Variables
- func NewFilesystem(client *Client) *filesystem
- func NewHost(client *Client) *host
- func NewIpInterface(client *Client) *ipinterface
- func NewMetrics(client *Client) *metrics
- func NewSnapshot(client *Client) *snapshot
- func NewStoragePool(client *Client) *storagepool
- func NewVolume(client *Client) *volume
- type AccessType
- type Client
- type ConfigConnect
- type FilesystemAccessType
- type LicenseType
- type NFSShareDefaultAccess
Constants ¶
const ( //To Display the Volume fields LunDisplayFields = "" /* 197-byte string literal not displayed */ //To Display the File System fields FileSystemDisplayFields = "" /* 160-byte string literal not displayed */ //To Display Storage Resource fields StorageResourceDisplayFields = "id,name,filesystem" //To Display Tenants fields TenantDisplayFields = "id,name" NFSShareDisplayfields = "id,name,filesystem,readOnlyHosts,readWriteHosts,readOnlyRootAccessHosts,rootAccessHosts,exportPaths" //To Display the NAS Server fields NasServerDisplayfields = "id,name,nfsServer?fields" //To Display the Snapshot fields SnapshotDisplayFields = "" /* 130-byte string literal not displayed */ //To Display the HostInitiator fields HostInitiatorsDisplayFields = "id,health,type,initiatorId,isIgnored,parentHost,paths" //To Display the HostIpPort fields HostIpPortDisplayFields = "id,address" //To Display License Info fields LicenseInfoDisplayFields = "isInstalled,isValid" //To Display the HostInitiatorPath fields HostInitiatorPathDisplayFields = "fcPort" //To Display the FC Port fields FcPortDisplayFields = "wwn" //Host IO Limit display fields HostIOLimitFields = "id,name,description" //Iscsi IP Interface display fields IscsiIPFields = "id,ipAddress,type" //Host Display fields HostfieldsToQuery = "id,name,description,fcHostInitiators,iscsiHostInitiators,hostIPPorts?fields" //Find Storage Pool fields StoragePoolFields = "" /* 162-byte string literal not displayed */ )
const ( ReadOnlyAccessType = AccessType("READ_ONLY") ReadWriteAccessType = AccessType("READ_WRITE") ReadOnlyRootAccessType = AccessType("READ_ONLY_ROOT") ReadWriteRootAccessType = AccessType("READ_WRITE_ROOT") )
const ( NoneDefaultAccess = NFSShareDefaultAccess("0") ReadOnlyDefaultAccess = NFSShareDefaultAccess("1") ReadWriteDefaultAccess = NFSShareDefaultAccess("2") ReadOnlyRootDefaultAccess = NFSShareDefaultAccess("3") ReadWriteRootDefaultAccess = NFSShareDefaultAccess("4") )
const ( LunNameMaxLength = 63 SnapForClone = "csi-snapforclone-" ThinProvisioning LicenseType = "THIN_PROVISIONING" DataReduction LicenseType = "DATA_REDUCTION" )
const (
FsNameMaxLength = 63
)
Variables ¶
var ( HostNotFoundError = errors.New("unable to find host") MultipleHostFoundError = errors.New("Found multiple hosts with same name. Delete the duplicate entries on the array") MultipleHostFoundErrorCode = "0x7d13158" HostNotFoundErrorCode = "0x7d13005" )
var AttachedSnapshotsErrorCode = "0x6000c17"
var CloningFailedError = errors.New("Volume Cloning Failed.")
var CreateSnapshotFailedError = errors.New("Create Snapshot Failed.")
var DependentClonesError = errors.New("The specified volume cannot be deleted because it has one or more dependent thin clones.")
var DependentClonesErrorCode = "0x6701673"
var FilesystemNotFoundError = errors.New("Unable to find filesystem")
var FilesystemNotFoundErrorCode = "0x7d13005"
var MarkFilesystemForDeletion = "csi-marked-filesystem-for-deletion(do not remove this from description)"
var MarkVolumeForDeletion = "csi-marked-vol-for-deletion"
var SnapshotNotFoundError = errors.New("Unable to find filesystem")
var SnapshotNotFoundErrorCode = "0x7d13005"
var VolumeNotFoundError = errors.New("Unable to find volume")
var VolumeNotFoundErrorCode = "0x7d13005"
Functions ¶
func NewFilesystem ¶ added in v1.1.0
func NewFilesystem(client *Client) *filesystem
func NewIpInterface ¶ added in v1.1.0
func NewIpInterface(client *Client) *ipinterface
func NewMetrics ¶ added in v1.6.0
func NewMetrics(client *Client) *metrics
NewMetrics returns a new instance of the Unity Metric query interface.
func NewSnapshot ¶
func NewSnapshot(client *Client) *snapshot
func NewStoragePool ¶
func NewStoragePool(client *Client) *storagepool
Types ¶
type AccessType ¶ added in v1.2.0
type AccessType string
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Struct holds the configuration & REST Client.
func NewClientWithArgs ¶
func NewClientWithArgs(ctx context.Context, endpoint string, insecure bool) (client *Client, err error)
NewClientWithArgs initialize the new REST Client with the given arguments.
func (*Client) Authenticate ¶
func (c *Client) Authenticate(ctx context.Context, configConnect *ConfigConnect) error
Authenticate make a REST API call [/loginSessionInfo] to Unity to get authenticate the given credentials. The response contains the EMC-CSRF-TOKEN and the client caches it for further communication.
type ConfigConnect ¶
Struct holds the endpoint & credential info.
type FilesystemAccessType ¶ added in v1.3.0
type FilesystemAccessType int
const ( BlockAccessType FilesystemAccessType = 0 //Parameter not applicable for block CheckpointAccessType FilesystemAccessType = 1 //Checkpoint access to enable access through a .ckpt folder in the file system. ProtocolAccessType FilesystemAccessType = 2 //Protocol access to enable access through a file share. )
type LicenseType ¶ added in v1.1.0
type LicenseType string
type NFSShareDefaultAccess ¶ added in v1.2.0
type NFSShareDefaultAccess string