Github user vdiravka commented on a diff in the pull request: https://github.com/apache/drill/pull/1083#discussion_r160997779 --- Diff: exec/java-exec/src/main/java/org/apache/drill/exec/store/parquet/ParquetFormatPlugin.java --- @@ -250,20 +250,12 @@ private boolean metaDataFileExists(FileSystem fs, FileStatus dir) throws IOExcep } boolean isDirReadable(DrillFileSystem fs, FileStatus dir) { - Path p = new Path(dir.getPath(), ParquetFileWriter.PARQUET_METADATA_FILE); try { - if (fs.exists(p)) { - return true; - } else { - - if (metaDataFileExists(fs, dir)) { - return true; - } - List<FileStatus> statuses = DrillFileSystemUtil.listFiles(fs, dir.getPath(), false); - return !statuses.isEmpty() && super.isFileReadable(fs, statuses.get(0)); - } + // There should be at least one file, which is readable by Drill + List<FileStatus> statuses = DrillFileSystemUtil.listFiles(fs, dir.getPath(), false); + return !statuses.isEmpty() && super.isFileReadable(fs, statuses.get(0)); --- End diff -- I have reverted my changes here. SchemalessScan will be created if ParquetGroupScan has empty entries and can't be used. The info that parquet metadata files are invalid will be logged.
---