You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@nifi.apache.org by GitBox <gi...@apache.org> on 2020/05/15 14:34:25 UTC

[GitHub] [nifi] turcsanyip commented on a change in pull request #4273: NIFI-7446: Fail when the specified path is a directory in FetchAzureDataLakeStorage

turcsanyip commented on a change in pull request #4273:
URL: https://github.com/apache/nifi/pull/4273#discussion_r425843940



##########
File path: nifi-nar-bundles/nifi-azure-bundle/nifi-azure-processors/src/main/java/org/apache/nifi/processors/azure/storage/FetchAzureDataLakeStorage.java
##########
@@ -67,6 +67,10 @@ public void onTrigger(ProcessContext context, ProcessSession session) throws Pro
             final DataLakeDirectoryClient directoryClient = dataLakeFileSystemClient.getDirectoryClient(directory);
             final DataLakeFileClient fileClient = directoryClient.getFileClient(fileName);
 
+            if (fileClient.getProperties().isDirectory()) {
+                throw new ProcessException(FILE.getDisplayName() + " (" + fileName + ") points to a directory. Full path: " + fileClient.getFilePath());

Review comment:
       It works properly for me too. I also updated the nifi-azure-services-api-nar (copy to NiFi's lib folder). Though, it might not necessary, only the nifi-azure-nar.




----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org