Uploaded image for project: 'Apache Drill'
  1. Apache Drill
  2. DRILL-3813

table from directory subtree having no descendent files fails with index error

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Done
    • None
    • 1.13.0
    • SQL Parser, Storage - Other
    • None

    Description

      Trying to use as a table a directory subtree that has no descendent files (but zero or more descendent directories) yields what seems to be a partially handled index out-of-bounds condition.

      For example, with /tmp/empty_directory being an empty directory:

      0: jdbc:drill:zk=local> SELECT * FROM `dfs`.`tmp`.`empty_directory`;
      Error: VALIDATION ERROR: Index: 0, Size: 0
      
      
      [Error Id: 747425c9-5350-4813-9f0d-ecf580e15101 on dev-linux2:31010] (state=,code=0)
      0: jdbc:drill:zk=local> 
      

      Also, with /tmp/no_child_files_subtree having two child directories and a grandchild directory, but not descendent files:

      0: jdbc:drill:zk=local> SELECT * FROM `dfs`.`tmp`.`no_child_files_subtree`;
      Error: VALIDATION ERROR: Index: 0, Size: 0
      
      
      [Error Id: abc90424-8434-4403-b44b-0ba69ef43151 on dev-linux2:31010] (state=,code=0)
      0: jdbc:drill:zk=local> 
      

      A directory subtree having no files was expected to be taken as a table with no rows (and a null schema).

      Attachments

        Issue Links

          Activity

            People

              vitalii Vitalii Diravka
              dsbos Daniel Barclay
              Votes:
              1 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: