Abhishek Girish created DRILL-2799: -------------------------------------- Summary: Query fails if directory contains .DS_Store Key: DRILL-2799 URL: https://issues.apache.org/jira/browse/DRILL-2799 Project: Apache Drill Issue Type: Bug Components: Storage - Other Reporter: Abhishek Girish Assignee: Jacques Nadeau
On accessing a folder, Mac OS X writes .DS_Store (some metadata) into it. See http://en.wikipedia.org/wiki/.DS_Store When querying such a folder, Drill throws an error. Drill should ignore this file. And there should be a way to configure the same. {code:sql} > select * from dfs.`/data/json/factbook` limit 1; Query failed: DATA_READ ERROR: Error reading JSON. - Invalid UTF-32 character 0x42756431(above 10ffff) at char #1, byte #7) Filename: /data/json/factbook/.DS_Store Record: 1 [f73266e5-3171-4134-a0a8-671af037ddd9 on abhi6.qa.lab:31010] Error: exception while executing query: Failure while executing query. (state=,code=0) {code} Removing the file results in successfully querying the directory. Log Snippet: {code} 2015-04-15 11:14:04,256 [2ad15592-eb25-eb7a-5e7b-1c93e68171c6:frag:0:0] ERROR o.a.drill.exec.ops.FragmentContext - Fragment Context received failure -- Fragment: 0:0 org.apache.drill.common.exceptions.DrillUserException: DATA_READ ERROR: Error reading JSON. - Invalid UTF-32 character 0x42756431(above 10ffff) at char #1, byte #7) Filename: /data/json/factbook/.DS_Store Record: 1 [f73266e5-3171-4134-a0a8-671af037ddd9 on abhi6.qa.lab:31010] at org.apache.drill.common.exceptions.DrillUserException$Builder.build(DrillUserException.java:115) ~[drill-common-0.9.0-SNAPSHOT-rebuffed.jar:0.9.0-SNAPSHOT] at org.apache.drill.exec.store.easy.json.JSONRecordReader.handleAndRaise(JSONRecordReader.java:171) ~[drill-java-exec-0.9.0-SNAPSHOT-rebuffed.jar:0.9.0-SNAPSHOT] at org.apache.drill.exec.store.easy.json.JSONRecordReader.next(JSONRecordReader.java:218) ~[drill-java-exec-0.9.0-SNAPSHOT-rebuffed.jar:0.9.0-SNAPSHOT] at org.apache.drill.exec.physical.impl.ScanBatch.next(ScanBatch.java:170) ~[drill-java-exec-0.9.0-SNAPSHOT-rebuffed.jar:0.9.0-SNAPSHOT] at org.apache.drill.exec.physical.impl.validate.IteratorValidatorBatchIterator.next(IteratorValidatorBatchIterator.java:118) [drill-java-exec-0.9.0-SNAPSHOT-rebuffed.jar:0.9.0-SNAPSHOT] {code} -- This message was sent by Atlassian JIRA (v6.3.4#6332)