Documentation ¶
Overview ¶
Copyright (c) 2019 Dell EMC Corporation All Rights Reserved
Index ¶
- Constants
- func ArrayContains(stringArray []string, value string) bool
- func ArrayContainsAll(stringArray1 []string, stringArray2 []string) bool
- func FindAdditionalWwns(stringArray1 []string, stringArray2 []string) []string
- func GetFCInitiators(ctx context.Context) ([]string, error)
- func GetFcPortWwnFromVolumeContentWwn(wwn string) string
- func GetHostIP() ([]string, error)
- func GetIPsFromInferfaces(ctx context.Context, ipInterfaces []types.IPInterfaceEntries) []string
- func GetLogger() *logrus.Logger
- func GetMessageWithRunID(runid string, format string, args ...interface{}) string
- func GetRunidAndLogger(ctx context.Context) (string, *logrus.Entry)
- func GetRunidLogger(ctx context.Context) *logrus.Entry
- func GetSnapshotResponseFromSnapshot(snap *types.Snapshot, protocol, arrayId string) *csi.CreateSnapshotResponse
- func GetVolumeResponseFromFilesystem(filesystem *types.Filesystem, arrayId, protocol string) *csi.CreateVolumeResponse
- func GetVolumeResponseFromSnapshot(snapshot *types.Snapshot, arrayId, protocol string) *csi.CreateVolumeResponse
- func GetVolumeResponseFromVolume(volume *types.Volume, arrayId, protocol string) *csi.CreateVolumeResponse
- func GetWwnFromVolumeContentWwn(wwn string) string
- func IPReachable(ctx context.Context, ip, port string, pingTimeout int) bool
- func IpsCompare(ctx context.Context, ip string, hostIps []string) (bool, []string)
- type Formatter
Constants ¶
const ( UnityLogger = "unitylog" LogFields = "fields" RUNID = "runid" ARRAYID = "arrayid" )
Variables ¶
This section is empty.
Functions ¶
func ArrayContains ¶
ArrayContains method does contains check operation
func ArrayContainsAll ¶
ArrayContainsAll method checks if all elements of stringArray1 is present in stringArray2
func FindAdditionalWwns ¶
FindAdditionalWwns returns the set difference stringArray2-stringArray1
func GetFcPortWwnFromVolumeContentWwn ¶
GetWwnFromVolumeContentWwn - Method to process wwn content to extract device wwn of a volume
func GetIPsFromInferfaces ¶
func GetIPsFromInferfaces(ctx context.Context, ipInterfaces []types.IPInterfaceEntries) []string
GetIPsFromInferfaces - Method to extract ip as string from ipInterface object
func GetMessageWithRunID ¶
func GetSnapshotResponseFromSnapshot ¶
func GetSnapshotResponseFromSnapshot(snap *types.Snapshot, protocol, arrayId string) *csi.CreateSnapshotResponse
Utility method to convert Unity Rest type Snapshot to CSI standard Snapshot Response
func GetVolumeResponseFromFilesystem ¶
func GetVolumeResponseFromFilesystem(filesystem *types.Filesystem, arrayId, protocol string) *csi.CreateVolumeResponse
GetVolumeResponseFromFilesystem Utility method to convert Unity rest Filesystem response to CSI standard Volume Response
func GetVolumeResponseFromSnapshot ¶ added in v1.3.0
func GetVolumeResponseFromSnapshot(snapshot *types.Snapshot, arrayId, protocol string) *csi.CreateVolumeResponse
func GetVolumeResponseFromVolume ¶
func GetVolumeResponseFromVolume(volume *types.Volume, arrayId, protocol string) *csi.CreateVolumeResponse
GetVolumeResponseFromVolume Utility method to convert Unity Rest type Volume to CSI standard Volume Response
func GetWwnFromVolumeContentWwn ¶
GetWwnFromVolumeContentWwn - Method to process wwn content to extract device wwn of a volume
func IPReachable ¶
IPReachable checks if a given IP is reachable or not
Types ¶
type Formatter ¶
type Formatter struct { //logrus.TextFormatter // Timestamp format TimestampFormat string // Available standard keys: time, msg, lvl // Also can include custom fields but limited to strings. // All of fields need to be wrapped inside %% i.e %time% %msg% LogFormat string CallerPrettyfier func(*runtime.Frame) (function string, file string) }
Formatter implements logrus.Formatter interface.