Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New-URIString.ps1 does not allow for IDs longer than 100 characters #656

Closed
clumnah opened this issue Jul 6, 2020 · 0 comments · Fixed by #657
Closed

New-URIString.ps1 does not allow for IDs longer than 100 characters #656

clumnah opened this issue Jul 6, 2020 · 0 comments · Fixed by #657
Assignees
Labels

Comments

@clumnah
Copy link
Contributor

clumnah commented Jul 6, 2020

in our latest module updates (5.0.2) we limit the ID to be a maximum of 100 characters in New-URIString.ps1? This was not in earlier versions of the module and is now breaking the ability to download database backup files.
When you request to download files in the UI or via the API, we submit an AYSNC request to gather those files and zip them up. This process will create a download link. This process has an ID that looks like this "DOWNLOAD_MSSQL_BACKUP_FILES_80377d45-59d7-49b6-9078-2f98b6265e07_da994f8d-cf28-45d0-a10e-4653cc1f04cb:::0" The length of this ID is 106 characters, which causes New-URIString to error out at line 23 with an error "Please validate ID input, invalid ID provided: '$id'" -ErrorAction Stop

Steps to Reproduce:
You must be using version 5.0.2 of the SDK

Connect-Rubrik
$RubrikDatabase = Get-RubrikDatabase -Name "Northwind" -ServerInstance "mssql.lumnah.lab\sql2008r2" -DetailedObject
$body = @{
startPoint=@{
date="2020-07-06T00:00:00.000Z"
}
endPoint=@{
date="2020-07-07T00:00:00.000Z"
}
backupType="Log"
}
$RubrikRequest = Invoke-RubrikRESTCall -Endpoint "mssql/db/$($RubrikDatabase.id)/download_files" -Method POST -Body $Body

$RubrikRequest = Get-RubrikRequest -id $RubrikRequest.id -WaitForCompletion -type mssql

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants