Skip to content
This repository has been archived by the owner on May 8, 2024. It is now read-only.

List Azure files and folders from File share snapshots #289

Open
Karrtojal opened this issue May 6, 2021 · 0 comments
Open

List Azure files and folders from File share snapshots #289

Karrtojal opened this issue May 6, 2021 · 0 comments

Comments

@Karrtojal
Copy link

Which service(blob, file, queue, table) does this issue concern?

file

Which version of the SDK was used?

the last

What's the PHP/OS version?

7.4

What problem was encountered?

There's no provision to provide shares snapshot query string parameter in the options to list them.

Steps to reproduce the issue?

function ListSnapshotFolder($shareName, $path, $snapshot)
{
global $fileRestProxy;
$vMaxResultados = 5000;
$vNextMarker = "";
$listResult = null;
try
{
do
{
$options = new ListDirectoriesAndFilesOptions();
$options->setMaxResults($vMaxResultados);
$options->setMarker($vNextMarker);
$shareFull = $shareName . "?snapshot=" . $snapshot;
$listResult = $fileRestProxy->ListDirectoriesAndFiles($shareFull,$path,$options);
$vNextMarker = $listResult->getNextMarker();
} while ($vNextMarker != "");
}
catch (Exception $e)
{
$code = $e->getCode();
$error_message = $e->getMessage();
return "ERROR:$code:$error_message";
}
return $listResult;
}

How to list the files and folders from a snapshot?

Have you found a mitigation/solution?

No

Is there a failing request ID related to this problem returned by server? What is it?

no

What is the storage account name and time frame of your last reproduce? (UTC YYYY/MM/DD hh:mm:ss)

all

(If you think some of the information should not be shared publicly, you can e-mail the main Microsoft contributors of the repository instead.)

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

No branches or pull requests

2 participants