Tom-Newton commented on code in PR #40119:
URL: https://github.com/apache/arrow/pull/40119#discussion_r1496716289


##########
cpp/src/arrow/filesystem/azurefs.cc:
##########
@@ -1662,20 +1705,28 @@ class AzureFileSystem::Impl {
       AzureFileSystem* fs) {
     RETURN_NOT_OK(ValidateFileLocation(location));
 
+    const auto blob_container_client = 
GetBlobContainerClient(location.container);
     auto block_blob_client = std::make_shared<Blobs::BlockBlobClient>(
-        blob_service_client_->GetBlobContainerClient(location.container)
-            .GetBlockBlobClient(location.path));
+        blob_container_client.GetBlockBlobClient(location.path));
+
+    auto ensure_not_flat_namespace_directory = [this, location,
+                                                blob_container_client]() -> 
Status {
+      bool hierarchical_namespace_enabled =
+          
HierarchicalNamespaceSupport(GetFileSystemClient(location.container)) ==
+          HNSSupport::kEnabled;

Review Comment:
   :+1:  we can save ourselves an extra API call if its 
`HNSSupport::kContainerNotFound`



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to