You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@drill.apache.org by parthchandra <gi...@git.apache.org> on 2017/07/21 04:08:01 UTC

[GitHub] drill pull request #864: DRILL-4720: Fix SchemaPartitionExplorer.getSubParti...

Github user parthchandra commented on a diff in the pull request:

    https://github.com/apache/drill/pull/864#discussion_r128631369
  
    --- Diff: exec/java-exec/src/main/java/org/apache/drill/exec/planner/sql/handlers/ShowFileHandler.java ---
    @@ -93,9 +94,9 @@ public PhysicalPlan getPlan(SqlNode sqlNode) throws ValidationException, RelConv
     
         List<ShowFilesCommandResult> rows = new ArrayList<>();
     
    -    for (FileStatus fileStatus : fs.list(false, new Path(defaultLocation, fromDir))) {
    +    for (FileStatus fileStatus : FileSystemUtil.listAll(fs, new Path(defaultLocation, fromDir), false)) {
           ShowFilesCommandResult result = new ShowFilesCommandResult(fileStatus.getPath().getName(), fileStatus.isDir(),
    -                                                                 !fileStatus.isDir(), fileStatus.getLen(),
    +                                                                 !fileStatus.isDirectory(), fileStatus.getLen(),
    --- End diff --
    
    Is `fileStatus.isDirectory`  true for symlinks to directories? Is it clearer to use `isFile()` ?


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---