-
Notifications
You must be signed in to change notification settings - Fork 3.6k
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
[C++][FS][Azure] Implement Move()
#38704
Comments
This is a potential complication with move. Azure blob storage does support efficient server side only moves.... but only if using SAS token authentication for the source file. Alternatively everything will need to be downloaded and re-uploaded, but that should work with any authentication. |
Maybe copy and then delete? That is at least how I have solved it previously with adlfs and Azure 😅 |
Sorry, I don't think I was thinking very carefully when I posted that comment. I think move is efficiently supported with hierarchical namespace. E.g. using https://github.com/Azure/azure-sdk-for-cpp/blob/4a32d7266cfac8bfc0eb87feb56011361a36f43c/sdk/storage/azure-storage-files-datalake/inc/azure/storage/files/datalake/datalake_file_system_client.hpp#L239 What I was thinking of was the copy blob by URI which has to use SAS token auth. But if we're only copying within one storage account we don't need to use that. There is another copy blob API we can use https://learn.microsoft.com/en-us/rest/api/storageservices/copy-blob?tabs=microsoft-entra-id#authorization. So I don't think there is any auth complication. We can use copy followed by delete as you say 🙂. |
@kou if you haven't started to work on this one I'm happy to take it. |
I haven't. Please do it! |
felipecrv - Did you begin work on this one? |
Yes. I'm very close to sending a PR. |
…Storage Gen 2 API (#39904) ### Rationale for this change We need to move directories and files via the `arrow::FileSystem` interface. ### What changes are included in this PR? - A few filesystem error reporting improvements - A helper class to deal with Azure Storage leases [1] - The `Move()` implementation that can move files and directories within the same container on storage accounts with Hierarchical Namespace Support enabled - Lots of tests [1]: https://learn.microsoft.com/en-us/rest/api/storageservices/lease-blob ### Are these changes tested? Yes, by existing and a huge number of tests added by this PR. The test code introduced here should be extracted to a reusable test module that we can use to test move in other file system implementations. ### Are there any user-facing changes? No breaking changes, only new functionality. * Closes: #38704 Authored-by: Felipe Oliveira Carvalho <felipekde@gmail.com> Signed-off-by: Felipe Oliveira Carvalho <felipekde@gmail.com>
…aLake Storage Gen 2 API (apache#39904) ### Rationale for this change We need to move directories and files via the `arrow::FileSystem` interface. ### What changes are included in this PR? - A few filesystem error reporting improvements - A helper class to deal with Azure Storage leases [1] - The `Move()` implementation that can move files and directories within the same container on storage accounts with Hierarchical Namespace Support enabled - Lots of tests [1]: https://learn.microsoft.com/en-us/rest/api/storageservices/lease-blob ### Are these changes tested? Yes, by existing and a huge number of tests added by this PR. The test code introduced here should be extracted to a reusable test module that we can use to test move in other file system implementations. ### Are there any user-facing changes? No breaking changes, only new functionality. * Closes: apache#38704 Authored-by: Felipe Oliveira Carvalho <felipekde@gmail.com> Signed-off-by: Felipe Oliveira Carvalho <felipekde@gmail.com>
…aLake Storage Gen 2 API (apache#39904) ### Rationale for this change We need to move directories and files via the `arrow::FileSystem` interface. ### What changes are included in this PR? - A few filesystem error reporting improvements - A helper class to deal with Azure Storage leases [1] - The `Move()` implementation that can move files and directories within the same container on storage accounts with Hierarchical Namespace Support enabled - Lots of tests [1]: https://learn.microsoft.com/en-us/rest/api/storageservices/lease-blob ### Are these changes tested? Yes, by existing and a huge number of tests added by this PR. The test code introduced here should be extracted to a reusable test module that we can use to test move in other file system implementations. ### Are there any user-facing changes? No breaking changes, only new functionality. * Closes: apache#38704 Authored-by: Felipe Oliveira Carvalho <felipekde@gmail.com> Signed-off-by: Felipe Oliveira Carvalho <felipekde@gmail.com>
…aLake Storage Gen 2 API (apache#39904) ### Rationale for this change We need to move directories and files via the `arrow::FileSystem` interface. ### What changes are included in this PR? - A few filesystem error reporting improvements - A helper class to deal with Azure Storage leases [1] - The `Move()` implementation that can move files and directories within the same container on storage accounts with Hierarchical Namespace Support enabled - Lots of tests [1]: https://learn.microsoft.com/en-us/rest/api/storageservices/lease-blob ### Are these changes tested? Yes, by existing and a huge number of tests added by this PR. The test code introduced here should be extracted to a reusable test module that we can use to test move in other file system implementations. ### Are there any user-facing changes? No breaking changes, only new functionality. * Closes: apache#38704 Authored-by: Felipe Oliveira Carvalho <felipekde@gmail.com> Signed-off-by: Felipe Oliveira Carvalho <felipekde@gmail.com>
Describe the enhancement requested
It's not implemented yet.
This is a child of GH-18014.
Component(s)
C++
The text was updated successfully, but these errors were encountered: