drill-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Steven Phillips (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (DRILL-3169) gz files cannot be accessed without gz formats extension definition
Date Fri, 22 May 2015 19:50:17 GMT

    [ https://issues.apache.org/jira/browse/DRILL-3169?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14556721#comment-14556721
] 

Steven Phillips commented on DRILL-3169:
----------------------------------------

The way the compression extension works is it is added in addition to the format extendsion.
So, for example,

googlebooks.tsv.gz should work.

You shouldn't define the compression extension as one of the format extensions. I might add
code to prevent a user from doing this.

> gz files cannot be accessed without gz formats extension definition
> -------------------------------------------------------------------
>
>                 Key: DRILL-3169
>                 URL: https://issues.apache.org/jira/browse/DRILL-3169
>             Project: Apache Drill
>          Issue Type: Bug
>    Affects Versions: 1.0.0
>         Environment: Mac OS X
>            Reporter: Kristine Hahn
>
> To reproduce the problem:
> 1. Put a gz file on the file system.
> 2. Define a plugin with and without a gz extension. For example:
> {noformat}
> {
>   "type": "file",
>   "enabled": true,
>   "connection": "file:///",
>   "workspaces": {
>     "ngram": {
>       "location": "/Users/khahn/drill/apache-drill-1.0.0",
>       "writable": false,
>       "defaultInputFormat": null
>     }
>   },
>   "formats": {
>     "tsv": {
>       "type": "text",
>       "extensions": [
>         "tsv",
>         "gz"
>       ],
>       "delimiter": "\t"
>     }
>   }
> }
> {noformat}
> 3. Try to query the gz file. 
> Expected results: success with and without the gz extension
> Actual results: error without the gz extension defined in formats.
> *Output--no gz extension in formats*
> {noformat}
> 0: jdbc:drill:zk=local> SELECT *  FROM ngram.`/googlebooks.gz`;
> May 22, 2015 6:06:51 AM org.apache.calcite.sql.validate.SqlValidatorException <init>
> SEVERE: org.apache.calcite.sql.validate.SqlValidatorException: Table 'ngram./googlebooks.gz'
not found
> May 22, 2015 6:06:51 AM org.apache.calcite.runtime.CalciteException <init>
> SEVERE: org.apache.calcite.runtime.CalciteContextException: From line 1, column 16 to
line 1, column 20: Table 'ngram./googlebooks.gz' not found
> Error: PARSE ERROR: From line 1, column 16 to line 1, column 20: Table 'ngram./googlebooks.gz'
not found
> [Error Id: 28f38441-81a0-4167-afad-86a8169d383b on 172.30.1.90:31010] (state=,code=0)
> {noformat}
> *Output with gz extension defined in formats*
> {noformat}
> 0: jdbc:drill:zk=local> SELECT *  FROM ngram.`/googlebooks.gz`;
> +-----------------------------------------------------------------------+
> |                                columns                                |
> +-----------------------------------------------------------------------+
> | ["ZOCOR should be taken with","2002","7","5"]                         |
> | ["ZOCOR should be taken with","2003","12","12"]                       |
> . . .
> {noformat}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message