Obs/bin/ObsDep/content/Powershell/Common/StorageHelpers.psm1

<###################################################
 # #
 # Copyright (c) Microsoft. All rights reserved. #
 # #
 ##################################################>


Import-Module $PSScriptRoot\Tracer.psm1 -DisableNameChecking
Import-Module $PSScriptRoot\ClusterHelpers.psm1 -DisableNameChecking

<#
 .Synopsis
  A helper funtion to convert a unprocessed share path (e.g. '{Infrastructure_2}\CloudMedia\Images\en-us') to its absolute file path.
 
  By default, it will convert to the local path for a cluster node to access locally.
    e.g. C:\ClusterStorage\Infrastructure_2\Shares\SU1_Infrastructure_2\CloudMedia\Images\en-us.
 
    e.g. \\v-host1\C$\ClusterStorage\Infrastructure_2\Shares\SU1_Infrastructure_2\CloudMedia\Images\en-us.
    If the $FromNoneClusterNode switch parameter is on, it will convert to the administrative share to the a cluster node for a none cluster machine to access remotely.
#>

function Get-SharePath {

    Param(
        [Parameter(Mandatory = $True)]
        [CloudEngine.Configurations.EceInterfaceParameters]
        $Parameters,
        [Parameter(Mandatory = $True)]
        [AllowEmptyString()]
        [string]
        $UnprocessedPath,
        [Parameter(Mandatory = $True)]
        [string]
        $ClusterName,
        [Parameter(Mandatory = $False)]
        [switch]
        $UseCurrentVersion,
        [Parameter(Mandatory = $False)]
        [switch]
        $FromNoneClusterNode
    )

    # Add support for optionally writing {LatestVersion} string in to the library share paths
    $escapedLatestVersionPattern = [regex]::escape("{LatestVersion}")
    if ($UnprocessedPath -Match $escapedLatestVersionPattern)
    {
        Import-Module $PSScriptRoot\..\Roles\Common\RoleHelpers.psm1 -DisableNameChecking -Verbose:$false | Out-Null

        # Calculate the latest version from input parameters
        $version = Get-InProgressUpdateVersion -Parameters $Parameters
        if ($UseCurrentVersion -or ($version -eq $null))
        {
            $version = ([string]($Parameters.Roles["Cloud"].PublicConfiguration.PublicInfo.Version)).Trim()
        }

        $UnprocessedPath = $UnprocessedPath -replace $escapedLatestVersionPattern, $version
    }

    if ($UnprocessedPath -NotMatch "{.*}")
    {
        throw [System.ArgumentException] "Invalid path input: replace token not found. Path: $UnprocessedPath"
    }

    $replaceToken = [regex]::match($UnprocessedPath,'{([^}]*)}').Groups[1].Value

    # If path contains {DefaultLocalShare} or {DefaultClusterShare}, we need to look up cloud role for getting the defaults
    if ($replaceToken -eq "DefaultLocalShare")
    {
        $sharePath = $Parameters.Roles["Cloud"].PublicConfiguration.PublicInfo.DefaultInfraStorageLocations.DefaultLocalShare
    }
    elseif ($replaceToken -eq "DefaultClusterShare")
    {
        $replaceToken = $Parameters.Roles["Cloud"].PublicConfiguration.PublicInfo.DefaultInfraStorageLocations.DefaultClusterShare
        $sharePath = Get-ClusterShare -Parameters $Parameters -ClusterName $ClusterName -ShareType $replaceToken
    }
    else
    {
        $sharePath = Get-ClusterShare -Parameters $Parameters -ClusterName $ClusterName -ShareType $replaceToken
    }

    if ($FromNoneClusterNode)
    {
        $activeNode = Get-ActiveClusterNodes -Parameters $Parameters -ClusterName $ClusterName | select -First 1
        $sharePath = $sharePath -replace 'C:', "\\$activeNode\c$"
    }

    $result = $UnprocessedPath -replace "{[^}]*}", $sharePath
    Trace-Execution "Get-SharePath: $UnprocessedPath -> $result"

    return $result
}

function Get-SharePathVersions {

    Param(
        [Parameter(Mandatory = $True)]
        [CloudEngine.Configurations.EceInterfaceParameters]
        $Parameters,
        [Parameter(Mandatory = $True)]
        [AllowEmptyString()]
        [string]
        $UnprocessedPath,
        [Parameter(Mandatory = $True)]
        [string]
        $ClusterName
    )
    $result = [System.Collections.ArrayList]::new()
    $escapedLatestVersionPattern = [regex]::escape("{LatestVersion}")
    if ($UnprocessedPath -Match $escapedLatestVersionPattern)
    {
        if ($UnprocessedPath -NotMatch "{.*}")
        {
            throw [System.ArgumentException] "Invalid path input: replace token not found. Path: $UnprocessedPath"
        }
        $replaceToken = [regex]::match($UnprocessedPath,'{([^}]*)}').Groups[1].Value

        # If path contains {DefaultLocalShare} or {DefaultClusterShare}, we need to look up cloud role for getting the defaults
        if ($replaceToken -eq "DefaultLocalShare")
        {
            $sharePath = $Parameters.Roles["Cloud"].PublicConfiguration.PublicInfo.DefaultInfraStorageLocations.DefaultLocalShare
        }
        elseif ($replaceToken -eq "DefaultClusterShare")
        {
            $replaceToken = $Parameters.Roles["Cloud"].PublicConfiguration.PublicInfo.DefaultInfraStorageLocations.DefaultClusterShare
            $sharePath = Get-ClusterShare -Parameters $Parameters -ClusterName $ClusterName -ShareType $replaceToken
        }
        else
        {
            $sharePath = Get-ClusterShare -Parameters $Parameters -ClusterName $ClusterName -ShareType $replaceToken
        }

        $basePath = $UnprocessedPath.Substring(0,$UnprocessedPath.IndexOf($escapedLatestVersionPattern))
        $basePath = $basePath -replace "{[^}]*}", $sharePath
        $versionFolders = Get-ChildItem -Path $basePath | where {$_.Name -match '\d+(?:\.\d+)+'} | where {$_.Name -notmatch '\s+'}
        foreach($versionFolder in $versionFolders){
            $UnprocessedPath = $UnprocessedPath
            $path = $UnprocessedPath -replace $escapedLatestVersionPattern, $versionFolder.Name -replace "{[^}]*}", $sharePath
            $result.Add($path) | Out-Null
        }
    }
    return $result
}

<#
 .Synopsis
  Return the local path for an cluster shared infrastructure volume
#>

Function Get-ClusterShare {

    Param(
        [Parameter(Mandatory = $True)]
        [CloudEngine.Configurations.EceInterfaceParameters]
        $Parameters,
        [Parameter(Mandatory = $True)]
        [string]
        $ClusterName,
        [Parameter(Mandatory = $True)]
        [ValidateSet("Infrastructure", "Infrastructure_2", "Infrastructure_3")]
        [string]
        $ShareType
    )
    # Temporary transition for Bug 15836892: Change CloudMedia content location from Infrastructure_2 to Infrastructure_1
    if ($ShareType -eq "Infrastructure_2")
    {
        $ShareType = $Parameters.Roles["Cloud"].PublicConfiguration.PublicInfo.DefaultInfraStorageLocations.DefaultClusterShare
        Trace-Warning "Resolving {Infrastructure_2} as {DefaultClusterShare} as temporary workaround.Bug 15836892"
    }

    $storageServerPrefix = $Parameters.Roles["Cluster"].PublicConfiguration.Clusters.Node | Where-Object Name -eq $ClusterName | Select-Object -ExpandProperty StorageServerPrefix
    $shareObject = $Parameters.Roles["Storage"].PublicConfiguration.PublicInfo.Shares.Share | Where-Object Type -eq $ShareType

    if (-not $shareObject)
    {
        throw [System.ArgumentException] "Invalid input: the cluster $ClusterName storage role contains no configuration for a share of type $ShareType."
    }

    $volumeName = $shareObject.Name
    $shareName = "${storageServerPrefix}_$($shareObject.Name)"

    $fullLocalPath = "C:\ClusterStorage\$volumeName\Shares\$shareName"

    return $fullLocalPath
}

function Test-LocalHostHasClusterStoragePath
{
    [CmdletBinding()]
    param(
        [Parameter(Mandatory = $true)]
        [CloudEngine.Configurations.EceInterfaceParameters]
        $Parameters
    )

    $ErrorActionPreference = "Stop"
    Trace-Execution "Testing for presence of local CSV path on this node."
    Test-Path "C:\ClusterStorage"
}

function Get-LocalCsvPathFromSharePath
{
    [CmdletBinding()]
    param(
        [Parameter(Mandatory = $true)]
        [CloudEngine.Configurations.EceInterfaceParameters]
        $Parameters,

        [Parameter(Mandatory = $true)]
        [string]
        $UNCSharePath,

        [Parameter(Mandatory = $false)]
        [string]
        $ClusterName
    )

    $ErrorActionPreference = "Stop"
    Trace-Execution "Getting local CSV path for share path $UNCSharePath on cluster $ClusterName."
    $pathParts = $UNCSharePath.Split("\")

    # Share path will look like \\SU1FileServer\SU1_Infrastructure_2\CloudMedia\WindowsUpdates\1.0.170925.1
    $smbShareName = $pathParts[3]

    if (-not $ClusterName)
    {
        $ClusterName = Get-ManagementClusterName $Parameters
    }
    $smbShare = Invoke-Command -ComputerName $ClusterName -ScriptBlock { Get-SmbShare | where Name -eq $using:smbShareName }

    if (-not $smbShare)
    {
        throw "An SMB share with the name '$smbShareName' could not be found on $ClusterName."
    }

    Trace-Execution "Found SMB share $smbShareName with local CSV path $($smbShare.Path)."
    return (Join-Path $smbShare.Path ($pathParts[4..$pathParts.Count] -join "\"))
}

<#
 .Synopsis
  Returns the name of the management cluster
#>

function Get-ManagementClusterName
{
    [CmdletBinding()]
    param
    (
        [Parameter(Mandatory = $true)]
        [CloudEngine.Configurations.EceInterfaceParameters]
        $Parameters
    )

    $ErrorActionPreference = "Stop"
    $publicInfo = $Parameters.Roles["Cluster"].PublicConfiguration
    $clusterName = $publicInfo.Clusters.Node | ? IsManagementCluster -eq "true" | Select-Object -ExpandProperty "Name"

    return $clusterName
}

<#
 .Synopsis
  Returns the host names of the management cluster
#>

function Get-ManagementClusterNodes
{
    [CmdletBinding()]
    param
    (
        [Parameter(Mandatory = $true)]
        [CloudEngine.Configurations.EceInterfaceParameters]
        $Parameters
    )

    $ErrorActionPreference = "Stop"
    $managementClusterName = Get-ManagementClusterName $Parameters

    $physicalMachinesRole = $Parameters.Roles["BareMetal"].PublicConfiguration
    $hostNames = @($physicalMachinesRole.Nodes.Node | ? RefClusterId -eq $managementClusterName | % Name)

    return $hostNames
}

<#
 .Synopsis
  Returns the RefClusterId of the Node
#>

function Get-NodeRefClusterId
{
    [CmdletBinding()]
    param
    (
        [Parameter(Mandatory = $true)]
        [CloudEngine.Configurations.EceInterfaceParameters]
        $Parameters,

        [Parameter(Mandatory = $true)]
        [string]
        $RoleName,

        [Parameter(Mandatory = $true)]
        [string]
        $NodeName
    )

    $ErrorActionPreference = "Stop"

    $node = $Parameters.Roles[$RoleName].PublicConfiguration.Nodes.Node | ? Name -ieq $NodeName
    $clusterName = $node.RefClusterId

    return $clusterName
}

<#
 .Synopsis
  Returns the RefNodeId of the Node
#>

function Get-NodeRefNodeId
{
    [CmdletBinding()]
    param
    (
        [Parameter(Mandatory = $true)]
        [CloudEngine.Configurations.EceInterfaceParameters]
        $Parameters,

        [Parameter(Mandatory = $true)]
        [string]
        $RoleName,

        [Parameter(Mandatory = $true)]
        [string]
        $NodeName
    )

    $ErrorActionPreference = "Stop"

    $node = $Parameters.Roles[$RoleName].PublicConfiguration.Nodes.Node | ? Name -ieq $NodeName
    return $node.RefNodeId
}

<#
 .Synopsis
  A replacement for Test-Path:
 
  1. differentiate file non-existence vs unexpected situlation such as location not accessible / share unavailability
     this cmdlet will return False on file non-existence; and throw the insider exception on other unexpected situlation
  2. optional retry feature, so that less random error will occure with logic like `if (-not test-path $Path) { throw "not found"}`
#>

function Test-PathStrict
{
    [CmdletBinding()]
    param(
        [Parameter(Mandatory = $true)]
        [string[]]
        $Path,

        [Parameter(Mandatory=$false)]
        [ValidateSet("Any", "Container", "Leaf")]
        [string] $PathType = 'Any',

        [Parameter(Mandatory=$false)]
        [UInt32] $RetryCount = 0,

        [Parameter(Mandatory=$false)]
        [UInt32] $RetryIntervalInSeconds = 60,

        [Parameter(Mandatory=$false)]
        [switch] $NoRetryOnItemNotFound = $false

    )

    $ErrorActionPreference = "Stop"
    $unexpectedException = $null
    for ($i = 0; $i -le $RetryCount; $i += 1) {
        if ($i -gt 0) {
            Start-Sleep -Seconds $RetryIntervalInSeconds
        }
        try {
            $r = dir -Path $Path
            if ($PathType -ieq 'Leaf') {
                if ($r.GetType().Name -ne 'FileInfo') {
                    throw "Path exists for $Path, however PathType not match (expected: Leaf, actual: Container)"
                }
            } elseif ($PathType -ieq 'Container') {
                if ($r.GetType().Name -eq 'FileInfo') {
                    throw "Path exists for $Path, however PathType not match (expected: Container, actual: Leaf)"
                }
            }
            return $true
        }
        catch {
            # `dir` will throw a single ItemNotFoundException when the folder/file doesn't exists but filesystem/smb-share is accessible & well connected
            # otherwise, UnauthorizedAccessException or other exception will be thrown together with ItemNotFoundException
            if ($_.length -eq 1 -and $_[0].Exception.GetType().Name -eq 'ItemNotFoundException') {
                if ($NoRetryOnItemNotFound) {
                    return $false
                }
                $unexpectedException = $null
            } else {
                $unexpectedException = $_
            }
        }
    }
    if ($unexpectedException -ne $null) {
        throw $unexpectedException;
    }
    return $false
}
<#
 .Synopsis
  A safe replacement for Test-Path, compare to Test-PathStrict:
 
  1. it doesn't retry on ItemNotFound
  2. during unexpected situlation (transient SMB connection issue), it by-default retry once after 60 seconds; then if the exception doesn't recover, it do the actual throwing
#>

function Test-PathSafe
{
    [CmdletBinding()]
    param(
        [Parameter(Mandatory = $true)]
        [string[]]
        $Path,

        [Parameter(Mandatory=$false)]
        [ValidateSet("Any", "Container", "Leaf")]
        [string] $PathType = 'Any',

        [Parameter(Mandatory=$false)]
        [UInt32] $RetryCount = 1,

        [Parameter(Mandatory=$false)]
        [UInt32] $RetryIntervalInSeconds = 60
    )
    $ErrorActionPreference = "Stop"
    return (Test-PathStrict -Path $Path -PathType $PathType -RetryCount $RetryCount -RetryIntervalInSeconds $RetryIntervalInSeconds -NoRetryOnItemNotFound)
}

Export-ModuleMember -Function Get-ClusterShare
Export-ModuleMember -Function Get-LocalCsvPathFromSharePath
Export-ModuleMember -Function Test-LocalHostHasClusterStoragePath
Export-ModuleMember -Function Get-ManagementClusterName
Export-ModuleMember -Function Get-ManagementClusterNodes
Export-ModuleMember -Function Get-NodeRefClusterId
Export-ModuleMember -Function Get-NodeRefNodeId
Export-ModuleMember -Function Get-SharePath
Export-ModuleMember -Function Get-SharePathVersions
Export-ModuleMember -Function Test-PathSafe

# SIG # Begin signature block
# MIIoQwYJKoZIhvcNAQcCoIIoNDCCKDACAQExDzANBglghkgBZQMEAgEFADB5Bgor
# BgEEAYI3AgEEoGswaTA0BgorBgEEAYI3AgEeMCYCAwEAAAQQH8w7YFlLCE63JNLG
# KX7zUQIBAAIBAAIBAAIBAAIBADAxMA0GCWCGSAFlAwQCAQUABCAWn7c0ZzmLURGf
# yTwwYAsS+F/3Et3x2D6YP8Zd3GHSpqCCDXYwggX0MIID3KADAgECAhMzAAADrzBA
# DkyjTQVBAAAAAAOvMA0GCSqGSIb3DQEBCwUAMH4xCzAJBgNVBAYTAlVTMRMwEQYD
# VQQIEwpXYXNoaW5ndG9uMRAwDgYDVQQHEwdSZWRtb25kMR4wHAYDVQQKExVNaWNy
# b3NvZnQgQ29ycG9yYXRpb24xKDAmBgNVBAMTH01pY3Jvc29mdCBDb2RlIFNpZ25p
# bmcgUENBIDIwMTEwHhcNMjMxMTE2MTkwOTAwWhcNMjQxMTE0MTkwOTAwWjB0MQsw
# CQYDVQQGEwJVUzETMBEGA1UECBMK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