[jira] [Commented] (DRILL-4199) Add Support for HBase 1.X

2016-06-13 Thread ASF GitHub Bot (JIRA)

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

ASF GitHub Bot commented on DRILL-4199:
---

Github user adityakishore commented on the issue:

https://github.com/apache/drill/pull/443
  
The latest patch, 323849e48fed967d43108e5cf85ba150a50f073e, moves the 
GuavaPatcher class to java-exec module and run the GuavaPatcher at Drillbit 
start (before the Stopwatch class is loaded somewhere else).

@jacques-n Could you please take a look?


> Add Support for HBase 1.X
> -
>
> Key: DRILL-4199
> URL: https://issues.apache.org/jira/browse/DRILL-4199
> Project: Apache Drill
>  Issue Type: New Feature
>  Components: Storage - HBase
>Affects Versions: 1.7.0
>Reporter: Divjot singh
>Assignee: Aditya Kishore
>
> Is there any Road map to upgrade the Hbase version to 1.x series. Currently 
> drill supports Hbase 0.98 version.



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


[jira] [Commented] (DRILL-3743) query hangs on sqlline once Drillbit on foreman node is killed

2016-06-13 Thread Khurram Faraaz (JIRA)

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

Khurram Faraaz commented on DRILL-3743:
---

Verified that the query does not hang on Drill 1.7.0

> query hangs on sqlline once Drillbit on foreman node is killed
> --
>
> Key: DRILL-3743
> URL: https://issues.apache.org/jira/browse/DRILL-3743
> Project: Apache Drill
>  Issue Type: Bug
>  Components: Execution - Flow
>Affects Versions: 1.2.0
> Environment: 4 node cluster CentOS
>Reporter: Khurram Faraaz
>Assignee: Sudheesh Katkam
>Priority: Critical
> Fix For: 1.7.0
>
>
> sqlline/query hangs once Drillbit (on Foreman node) is killed. (kill -9 )
> query was issued from the Foreman node. The query returns many records, and 
> it is a long running query.
> Steps to reproduce the problem.
> set planner.slice_target=1
> 1.  clush -g khurram service mapr-warden stop
> 2.  clush -g khurram service mapr-warden start
> 3.  ./sqlline -u "jdbc:drill:schema=dfs.tmp"
> 0: jdbc:drill:schema=dfs.tmp> select * from `twoKeyJsn.json` limit 200;
> 4.  Immediately from another console do a jps and kill the Drillbit process 
> (in this case foreman) while the query is being run on sqlline. You will 
> notice that sqlline just hangs, we do not see any exceptions or errors being 
> reported on sqlline prompt or in drillbit.log or drillbit.out
> I do see this Exception in sqlline.log on the node from where sqlline was 
> started
> {code}
> 2015-09-04 18:45:12,069 [Client-1] INFO  o.a.d.e.rpc.user.QueryResultHandler 
> - User Error Occurred
> org.apache.drill.common.exceptions.UserException: CONNECTION ERROR: 
> Connection /10.10.100.201:53425 <--> /10.10.100.201:31010 (user client) 
> closed unexpectedly.
> [Error Id: ec316cfd-c9a5-4905-98e3-da20cb799ba5 ]
> at 
> org.apache.drill.common.exceptions.UserException$Builder.build(UserException.java:524)
>  ~[drill-common-1.2.0-SNAPSHOT.jar:1.2.0-SNAPSHOT]
> at 
> org.apache.drill.exec.rpc.user.QueryResultHandler$SubmissionListener$ChannelClosedListener.operationComplete(QueryResultHandler.java:298)
>  [drill-java-exec-1.2.0-SNAPSHOT.jar:1.2.0-SNAPSHOT]
> at 
> io.netty.util.concurrent.DefaultPromise.notifyListener0(DefaultPromise.java:680)
>  [netty-common-4.0.27.Final.jar:4.0.27.Final]
> at 
> io.netty.util.concurrent.DefaultPromise$LateListeners.run(DefaultPromise.java:845)
>  [netty-common-4.0.27.Final.jar:4.0.27.Final]
> at 
> io.netty.util.concurrent.DefaultPromise$LateListenerNotifier.run(DefaultPromise.java:873)
>  [netty-common-4.0.27.Final.jar:4.0.27.Final]
> at 
> io.netty.util.concurrent.SingleThreadEventExecutor.runAllTasks(SingleThreadEventExecutor.java:357)
>  [netty-common-4.0.27.Final.jar:4.0.27.Final]
> at io.netty.channel.epoll.EpollEventLoop.run(EpollEventLoop.java:254) 
> [netty-transport-native-epoll-4.0.27.Final-linux-x86_64.jar:na]
> at 
> io.netty.util.concurrent.SingleThreadEventExecutor$2.run(SingleThreadEventExecutor.java:111)
>  [netty-common-4.0.27.Final.jar:4.0.27.Final]
> at java.lang.Thread.run(Thread.java:744) [na:1.7.0_45]
> 2015-09-04 18:45:12,069 [Client-1] INFO  
> o.a.d.j.i.DrillResultSetImpl$ResultsListener - [#7] Query failed:
> org.apache.drill.common.exceptions.UserException: CONNECTION ERROR: 
> Connection /10.10.100.201:53425 <--> /10.10.100.201:31010 (user client) 
> closed unexpectedly.
> [Error Id: ec316cfd-c9a5-4905-98e3-da20cb799ba5 ]
> at 
> org.apache.drill.common.exceptions.UserException$Builder.build(UserException.java:524)
>  ~[drill-common-1.2.0-SNAPSHOT.jar:1.2.0-SNAPSHOT]
> at 
> org.apache.drill.exec.rpc.user.QueryResultHandler$SubmissionListener$ChannelClosedListener.operationComplete(QueryResultHandler.java:298)
>  [drill-java-exec-1.2.0-SNAPSHOT.jar:1.2.0-SNAPSHOT]
> at 
> io.netty.util.concurrent.DefaultPromise.notifyListener0(DefaultPromise.java:680)
>  [netty-common-4.0.27.Final.jar:4.0.27.Final]
> at 
> io.netty.util.concurrent.DefaultPromise$LateListeners.run(DefaultPromise.java:845)
>  [netty-common-4.0.27.Final.jar:4.0.27.Final]
> at 
> io.netty.util.concurrent.DefaultPromise$LateListenerNotifier.run(DefaultPromise.java:873)
>  [netty-common-4.0.27.Final.jar:4.0.27.Final]
> at 
> io.netty.util.concurrent.SingleThreadEventExecutor.runAllTasks(SingleThreadEventExecutor.java:357)
>  [netty-common-4.0.27.Final.jar:4.0.27.Final]
> at io.netty.channel.epoll.EpollEventLoop.run(EpollEventLoop.java:254) 
> [netty-transport-native-epoll-4.0.27.Final-linux-x86_64.jar:na]
> at 
> io.netty.util.concurrent.SingleThreadEventExecutor$2.run(SingleThreadEventExecutor.java:111)
>  [netty-common-4.0.27.Final.jar:4.

[jira] [Closed] (DRILL-3743) query hangs on sqlline once Drillbit on foreman node is killed

2016-06-13 Thread Khurram Faraaz (JIRA)

 [ 
https://issues.apache.org/jira/browse/DRILL-3743?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Khurram Faraaz closed DRILL-3743.
-

> query hangs on sqlline once Drillbit on foreman node is killed
> --
>
> Key: DRILL-3743
> URL: https://issues.apache.org/jira/browse/DRILL-3743
> Project: Apache Drill
>  Issue Type: Bug
>  Components: Execution - Flow
>Affects Versions: 1.2.0
> Environment: 4 node cluster CentOS
>Reporter: Khurram Faraaz
>Assignee: Sudheesh Katkam
>Priority: Critical
> Fix For: 1.7.0
>
>
> sqlline/query hangs once Drillbit (on Foreman node) is killed. (kill -9 )
> query was issued from the Foreman node. The query returns many records, and 
> it is a long running query.
> Steps to reproduce the problem.
> set planner.slice_target=1
> 1.  clush -g khurram service mapr-warden stop
> 2.  clush -g khurram service mapr-warden start
> 3.  ./sqlline -u "jdbc:drill:schema=dfs.tmp"
> 0: jdbc:drill:schema=dfs.tmp> select * from `twoKeyJsn.json` limit 200;
> 4.  Immediately from another console do a jps and kill the Drillbit process 
> (in this case foreman) while the query is being run on sqlline. You will 
> notice that sqlline just hangs, we do not see any exceptions or errors being 
> reported on sqlline prompt or in drillbit.log or drillbit.out
> I do see this Exception in sqlline.log on the node from where sqlline was 
> started
> {code}
> 2015-09-04 18:45:12,069 [Client-1] INFO  o.a.d.e.rpc.user.QueryResultHandler 
> - User Error Occurred
> org.apache.drill.common.exceptions.UserException: CONNECTION ERROR: 
> Connection /10.10.100.201:53425 <--> /10.10.100.201:31010 (user client) 
> closed unexpectedly.
> [Error Id: ec316cfd-c9a5-4905-98e3-da20cb799ba5 ]
> at 
> org.apache.drill.common.exceptions.UserException$Builder.build(UserException.java:524)
>  ~[drill-common-1.2.0-SNAPSHOT.jar:1.2.0-SNAPSHOT]
> at 
> org.apache.drill.exec.rpc.user.QueryResultHandler$SubmissionListener$ChannelClosedListener.operationComplete(QueryResultHandler.java:298)
>  [drill-java-exec-1.2.0-SNAPSHOT.jar:1.2.0-SNAPSHOT]
> at 
> io.netty.util.concurrent.DefaultPromise.notifyListener0(DefaultPromise.java:680)
>  [netty-common-4.0.27.Final.jar:4.0.27.Final]
> at 
> io.netty.util.concurrent.DefaultPromise$LateListeners.run(DefaultPromise.java:845)
>  [netty-common-4.0.27.Final.jar:4.0.27.Final]
> at 
> io.netty.util.concurrent.DefaultPromise$LateListenerNotifier.run(DefaultPromise.java:873)
>  [netty-common-4.0.27.Final.jar:4.0.27.Final]
> at 
> io.netty.util.concurrent.SingleThreadEventExecutor.runAllTasks(SingleThreadEventExecutor.java:357)
>  [netty-common-4.0.27.Final.jar:4.0.27.Final]
> at io.netty.channel.epoll.EpollEventLoop.run(EpollEventLoop.java:254) 
> [netty-transport-native-epoll-4.0.27.Final-linux-x86_64.jar:na]
> at 
> io.netty.util.concurrent.SingleThreadEventExecutor$2.run(SingleThreadEventExecutor.java:111)
>  [netty-common-4.0.27.Final.jar:4.0.27.Final]
> at java.lang.Thread.run(Thread.java:744) [na:1.7.0_45]
> 2015-09-04 18:45:12,069 [Client-1] INFO  
> o.a.d.j.i.DrillResultSetImpl$ResultsListener - [#7] Query failed:
> org.apache.drill.common.exceptions.UserException: CONNECTION ERROR: 
> Connection /10.10.100.201:53425 <--> /10.10.100.201:31010 (user client) 
> closed unexpectedly.
> [Error Id: ec316cfd-c9a5-4905-98e3-da20cb799ba5 ]
> at 
> org.apache.drill.common.exceptions.UserException$Builder.build(UserException.java:524)
>  ~[drill-common-1.2.0-SNAPSHOT.jar:1.2.0-SNAPSHOT]
> at 
> org.apache.drill.exec.rpc.user.QueryResultHandler$SubmissionListener$ChannelClosedListener.operationComplete(QueryResultHandler.java:298)
>  [drill-java-exec-1.2.0-SNAPSHOT.jar:1.2.0-SNAPSHOT]
> at 
> io.netty.util.concurrent.DefaultPromise.notifyListener0(DefaultPromise.java:680)
>  [netty-common-4.0.27.Final.jar:4.0.27.Final]
> at 
> io.netty.util.concurrent.DefaultPromise$LateListeners.run(DefaultPromise.java:845)
>  [netty-common-4.0.27.Final.jar:4.0.27.Final]
> at 
> io.netty.util.concurrent.DefaultPromise$LateListenerNotifier.run(DefaultPromise.java:873)
>  [netty-common-4.0.27.Final.jar:4.0.27.Final]
> at 
> io.netty.util.concurrent.SingleThreadEventExecutor.runAllTasks(SingleThreadEventExecutor.java:357)
>  [netty-common-4.0.27.Final.jar:4.0.27.Final]
> at io.netty.channel.epoll.EpollEventLoop.run(EpollEventLoop.java:254) 
> [netty-transport-native-epoll-4.0.27.Final-linux-x86_64.jar:na]
> at 
> io.netty.util.concurrent.SingleThreadEventExecutor$2.run(SingleThreadEventExecutor.java:111)
>  [netty-common-4.0.27.Final.jar:4.0.27.Final]
> at java.lang.Thread.run(Thread.java:744) [na:1.7.0_45]
> 2015-09-04 18:45:12,071 [Client-1]

[jira] [Commented] (DRILL-3510) Add ANSI_QUOTES option so that Drill's SQL Parser will recognize ANSI_SQL identifiers

2016-06-13 Thread ASF GitHub Bot (JIRA)

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

ASF GitHub Bot commented on DRILL-3510:
---

GitHub user vdiravka opened a pull request:

https://github.com/apache/drill/pull/520

DRILL-3510: Add ANSI_QUOTES option so that Drill's SQL Parser will 
recognize ANSI_SQL identifiers

- added calcite's Lex.MYSQL_ANSI (double quote) supporting for SQL 
identifiers;
- replaced drill's SqlParser.Config with calcite's one;
- added unit test TestSqlConverter - testAnsiQuotes();
- upgraded getIdentifierQuoteString() for drill's database metadata;
- upgraded unit test testGetIdentifierQuoteString();

You can merge this pull request into a Git repository by running:

$ git pull https://github.com/vdiravka/drill DRILL-3510

Alternatively you can review and apply these changes as the patch at:

https://github.com/apache/drill/pull/520.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

This closes #520


commit bccb92f4557306ee76f06435211a80cf9464c656
Author: Vitalii Diravka 
Date:   2016-05-20T20:11:33Z

DRILL-3510: Add ANSI_QUOTES option so that Drill's SQL Parser will 
recognize ANSI_SQL identifiers
- replaced drill's SqlParser.Config with calcite's one;
- added calcite's Lex.MYSQL_ANSI (double quote) supporting for SQL 
identifiers;
- added unit test TestSqlConverter - testAnsiQuotes();
- upgraded getIdentifierQuoteString() for  drill's database metadata;
- upgraded unit test testGetIdentifierQuoteString();




> Add ANSI_QUOTES option so that Drill's SQL Parser will recognize ANSI_SQL 
> identifiers 
> --
>
> Key: DRILL-3510
> URL: https://issues.apache.org/jira/browse/DRILL-3510
> Project: Apache Drill
>  Issue Type: Improvement
>  Components: SQL Parser
>Reporter: Jinfeng Ni
>Assignee: Vitalii Diravka
> Fix For: Future
>
> Attachments: DRILL-3510.patch, DRILL-3510.patch
>
>
> Currently Drill's SQL parser uses backtick as identifier quotes, the same as 
> what MySQL does. However, this is different from ANSI SQL specification, 
> where double quote is used as identifier quotes.  
> MySQL has an option "ANSI_QUOTES", which could be switched on/off by user. 
> Drill should follow the same way, so that Drill users do not have to rewrite 
> their existing queries, if their queries use double quotes. 
> {code}
> SET sql_mode='ANSI_QUOTES';
> {code}
>



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


[jira] [Created] (DRILL-4718) call to ResultSet.getObject(int columnIndex) results in InvalidCursorStateSqlException

2016-06-13 Thread Khurram Faraaz (JIRA)
Khurram Faraaz created DRILL-4718:
-

 Summary: call to ResultSet.getObject(int columnIndex) results in 
InvalidCursorStateSqlException
 Key: DRILL-4718
 URL: https://issues.apache.org/jira/browse/DRILL-4718
 Project: Apache Drill
  Issue Type: Bug
  Components: Client - JDBC
Affects Versions: 1.7.0
 Environment: CentOS 6.8
Reporter: Khurram Faraaz


The JDBC snippet below results in the exception on Drill 1.7.0

Result set cursor is positioned before all rows.  Call next() first.
org.apache.drill.jdbc.InvalidCursorStateSqlException: Result set cursor is 
positioned before all rows.  Call next() first.

Drill git.commit.id=6286c0a
JDBC Driver : drill-jdbc-all-1.7.0-SNAPSHOT.jar

{noformat}
try {
final String URL_STRING = 
"jdbc:drill:schema=dfs.tmp;drillbit=";
Class.forName("org.apache.drill.jdbc.Driver").newInstance();
Connection conn = 
DriverManager.getConnection(URL_STRING,"test","test");
Statement stmt = conn.createStatement();

String query = "select columns[0] from `t3.csv`";
ResultSet rs = stmt.executeQuery(query);

System.out.println("ResultSet.getObject(1) :"+rs.getObject(1));
while (rs.next()) {
}
if (rs != null)
rs.close();
stmt.close();
conn.close();
} catch ( Exception e ) {
System.out.println(e.getMessage());
e.printStackTrace();
}
{noformat}

data used in above query in t3.csv
{noformat}
abcd
efgh
ijkl
mnop
qrst
{noformat}

Here is the Exception

{noformat}
...
row_count: 5
def {
  record_count: 5
  field {
major_type {
  minor_type: VARCHAR
  mode: OPTIONAL
}
name_part {
  name: "EXPR$0"
}
child {
  major_type {
minor_type: UINT1
mode: REQUIRED
  }
  name_part {
name: "$bits$"
  }
  value_count: 5
  buffer_length: 5
}
child {
  major_type {
minor_type: VARCHAR
mode: OPTIONAL
  }
  name_part {
name: "EXPR$0"
  }
  child {
major_type {
  minor_type: UINT4
  mode: REQUIRED
}
name_part {
  name: "$offsets$"
}
value_count: 6
buffer_length: 24
  }
  value_count: 5
  buffer_length: 44
}
value_count: 5
buffer_length: 49
  }
  carries_two_byte_selection_vector: false
}
, data=DrillBuf[14], udle: [9 131..180]].
08:37:17.483 [USER-rpc-event-queue] DEBUG o.a.d.e.rpc.user.QueryResultHandler - 
resultArrived: queryState: COMPLETED, queryId = 
28a18f42-410f-bbc4-6445-0c95423ca341
08:37:17.484 [USER-rpc-event-queue] DEBUG 
o.a.d.j.i.DrillResultSetImpl$ResultsListener - [#1] Received query completion: 
COMPLETED.
08:37:17.485 [USER-rpc-event-queue] DEBUG o.a.drill.exec.rpc.user.UserClient - 
Sending response with Sender 1404764360
Result set cursor is positioned before all rows.  Call next() first.
org.apache.drill.jdbc.InvalidCursorStateSqlException: Result set cursor is 
positioned before all rows.  Call next() first.
at 
org.apache.drill.jdbc.impl.AvaticaDrillSqlAccessor.getCurrentRecordNumber(AvaticaDrillSqlAccessor.java:73)
at 
org.apache.drill.jdbc.impl.AvaticaDrillSqlAccessor.getObject(AvaticaDrillSqlAccessor.java:179)
at 
net.hydromatic.avatica.AvaticaResultSet.getObject(AvaticaResultSet.java:351)
at 
org.apache.drill.jdbc.impl.DrillResultSetImpl.getObject(DrillResultSetImpl.java:420)
at GetTblName.main(GetTblName.java:28)
{noformat}



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


[jira] [Commented] (DRILL-4718) call to ResultSet.getObject(int columnIndex) results in InvalidCursorStateSqlException

2016-06-13 Thread Khurram Faraaz (JIRA)

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

Khurram Faraaz commented on DRILL-4718:
---

You may want to look at the Fix for DRILL-3347 to know if this issue is related 
to that Fix.

> call to ResultSet.getObject(int columnIndex) results in 
> InvalidCursorStateSqlException
> --
>
> Key: DRILL-4718
> URL: https://issues.apache.org/jira/browse/DRILL-4718
> Project: Apache Drill
>  Issue Type: Bug
>  Components: Client - JDBC
>Affects Versions: 1.7.0
> Environment: CentOS 6.8
>Reporter: Khurram Faraaz
>
> The JDBC snippet below results in the exception on Drill 1.7.0
> Result set cursor is positioned before all rows.  Call next() first.
> org.apache.drill.jdbc.InvalidCursorStateSqlException: Result set cursor is 
> positioned before all rows.  Call next() first.
> Drill git.commit.id=6286c0a
> JDBC Driver : drill-jdbc-all-1.7.0-SNAPSHOT.jar
> {noformat}
> try {
> final String URL_STRING = 
> "jdbc:drill:schema=dfs.tmp;drillbit=";
> Class.forName("org.apache.drill.jdbc.Driver").newInstance();
> Connection conn = 
> DriverManager.getConnection(URL_STRING,"test","test");
> Statement stmt = conn.createStatement();
> String query = "select columns[0] from `t3.csv`";
> ResultSet rs = stmt.executeQuery(query);
> System.out.println("ResultSet.getObject(1) 
> :"+rs.getObject(1));
> while (rs.next()) {
> }
> if (rs != null)
> rs.close();
> stmt.close();
> conn.close();
> } catch ( Exception e ) {
> System.out.println(e.getMessage());
> e.printStackTrace();
> }
> {noformat}
> data used in above query in t3.csv
> {noformat}
> abcd
> efgh
> ijkl
> mnop
> qrst
> {noformat}
> Here is the Exception
> {noformat}
> ...
> row_count: 5
> def {
>   record_count: 5
>   field {
> major_type {
>   minor_type: VARCHAR
>   mode: OPTIONAL
> }
> name_part {
>   name: "EXPR$0"
> }
> child {
>   major_type {
> minor_type: UINT1
> mode: REQUIRED
>   }
>   name_part {
> name: "$bits$"
>   }
>   value_count: 5
>   buffer_length: 5
> }
> child {
>   major_type {
> minor_type: VARCHAR
> mode: OPTIONAL
>   }
>   name_part {
> name: "EXPR$0"
>   }
>   child {
> major_type {
>   minor_type: UINT4
>   mode: REQUIRED
> }
> name_part {
>   name: "$offsets$"
> }
> value_count: 6
> buffer_length: 24
>   }
>   value_count: 5
>   buffer_length: 44
> }
> value_count: 5
> buffer_length: 49
>   }
>   carries_two_byte_selection_vector: false
> }
> , data=DrillBuf[14], udle: [9 131..180]].
> 08:37:17.483 [USER-rpc-event-queue] DEBUG o.a.d.e.rpc.user.QueryResultHandler 
> - resultArrived: queryState: COMPLETED, queryId = 
> 28a18f42-410f-bbc4-6445-0c95423ca341
> 08:37:17.484 [USER-rpc-event-queue] DEBUG 
> o.a.d.j.i.DrillResultSetImpl$ResultsListener - [#1] Received query 
> completion: COMPLETED.
> 08:37:17.485 [USER-rpc-event-queue] DEBUG o.a.drill.exec.rpc.user.UserClient 
> - Sending response with Sender 1404764360
> Result set cursor is positioned before all rows.  Call next() first.
> org.apache.drill.jdbc.InvalidCursorStateSqlException: Result set cursor is 
> positioned before all rows.  Call next() first.
>   at 
> org.apache.drill.jdbc.impl.AvaticaDrillSqlAccessor.getCurrentRecordNumber(AvaticaDrillSqlAccessor.java:73)
>   at 
> org.apache.drill.jdbc.impl.AvaticaDrillSqlAccessor.getObject(AvaticaDrillSqlAccessor.java:179)
>   at 
> net.hydromatic.avatica.AvaticaResultSet.getObject(AvaticaResultSet.java:351)
>   at 
> org.apache.drill.jdbc.impl.DrillResultSetImpl.getObject(DrillResultSetImpl.java:420)
>   at GetTblName.main(GetTblName.java:28)
> {noformat}



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


[jira] [Closed] (DRILL-3763) Cancel (Ctrl-C) one of concurrent queries results in ChannelClosedException

2016-06-13 Thread Khurram Faraaz (JIRA)

 [ 
https://issues.apache.org/jira/browse/DRILL-3763?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Khurram Faraaz closed DRILL-3763.
-

> Cancel (Ctrl-C) one of concurrent queries results in ChannelClosedException
> ---
>
> Key: DRILL-3763
> URL: https://issues.apache.org/jira/browse/DRILL-3763
> Project: Apache Drill
>  Issue Type: Bug
>  Components: Execution - RPC
>Affects Versions: 1.2.0
> Environment: 4 node cluster CentOS
>Reporter: Khurram Faraaz
>Assignee: Deneche A. Hakim
> Fix For: 1.7.0
>
>
> Canceling a query from a set of concurrent queries executing on the same 
> table, results in ChannelClosedException when one of the queries in Canceled 
> using Ctrl-C from sqlline prompt.
> Steps to reproduce the problem,
> 1. Start, service map-warden start on 4 nodes.
> 2. Start eight sqlline sessions from eight different terminals, ./sqlline -u 
> "jdbc:drill:schema=dfs.tmp"
> 3. Run the below query from the eight sqlline sessions
> select * from `twoKeyJsn.json`;
> 4. While the queries are being executed, Cancel one of the queries on sqlline 
> prompt, issue Ctrl-C on sqlline.
> 5. you will note that after a few seconds/minutes, on one of the other 
> sqlline sessions there is a ChannelClosedException that is reported and that 
> query is reported as FAILED on the query profile on the Web UI.
> {code}
> 0: jdbc:drill:schema=dfs.tmp> select * from `twoKeyJsn.json`;
> ...
> | 1.31643767542E9  | h|
> | 9.02780441562E8  | b|
> | 6.46524413864E8  | l|
> java.lang.RuntimeException: java.sql.SQLException: SYSTEM ERROR: 
> ChannelClosedException: Channel closed /10.10.100.201:31010 <--> 
> /10.10.100.202:58705.
> Fragment 0:0
> [Error Id: bd765bd5-3921-4b58-89a7-cd87482f9088 on centos-01.qa.lab:31010]
>   at sqlline.IncrementalRows.hasNext(IncrementalRows.java:73)
>   at 
> sqlline.TableOutputFormat$ResizingRowsProvider.next(TableOutputFormat.java:87)
>   at sqlline.TableOutputFormat.print(TableOutputFormat.java:118)
>   at sqlline.SqlLine.print(SqlLine.java:1583)
>   at sqlline.Commands.execute(Commands.java:852)
>   at sqlline.Commands.sql(Commands.java:751)
>   at sqlline.SqlLine.dispatch(SqlLine.java:738)
>   at sqlline.SqlLine.begin(SqlLine.java:612)
>   at sqlline.SqlLine.start(SqlLine.java:366)
>   at sqlline.SqlLine.main(SqlLine.java:259)
> 0: jdbc:drill:schema=dfs.tmp> 
> {code}
> Stack trace from drillbit.log
> {code}
> 2015-09-10 23:23:55,019 [UserServer-1] INFO  
> o.a.d.e.w.fragment.FragmentExecutor - 
> 2a0df049-697d-f47b-86b5-1e2697946237:0:0: State change requested RUNNING --> 
> FAILED
> 2015-09-10 23:24:05,319 [2a0df049-697d-f47b-86b5-1e2697946237:frag:0:0] INFO  
> o.a.d.e.w.fragment.FragmentExecutor - 
> 2a0df049-697d-f47b-86b5-1e2697946237:0:0: State change requested FAILED --> 
> FINISHED
> 2015-09-10 23:24:05,331 [2a0df049-697d-f47b-86b5-1e2697946237:frag:0:0] ERROR 
> o.a.d.e.w.fragment.FragmentExecutor - SYSTEM ERROR: ChannelClosedException: 
> Channel closed /10.10.100.201:31010 <--> /10.10.100.202:58705.
> Fragment 0:0
> [Error Id: bd765bd5-3921-4b58-89a7-cd87482f9088 on centos-01.qa.lab:31010]
> org.apache.drill.common.exceptions.UserException: SYSTEM ERROR: 
> ChannelClosedException: Channel closed /10.10.100.201:31010 <--> 
> /10.10.100.202:58705.
> Fragment 0:0
> [Error Id: bd765bd5-3921-4b58-89a7-cd87482f9088 on centos-01.qa.lab:31010]
> at 
> org.apache.drill.common.exceptions.UserException$Builder.build(UserException.java:524)
>  ~[drill-common-1.2.0-SNAPSHOT.jar:1.2.0-SNAPSHOT]
> at 
> org.apache.drill.exec.work.fragment.FragmentExecutor.sendFinalState(FragmentExecutor.java:323)
>  [drill-java-exec-1.2.0-SNAPSHOT.jar:1.2.0-SNAPSHOT]
> at 
> org.apache.drill.exec.work.fragment.FragmentExecutor.cleanup(FragmentExecutor.java:178)
>  [drill-java-exec-1.2.0-SNAPSHOT.jar:1.2.0-SNAPSHOT]
> at 
> org.apache.drill.exec.work.fragment.FragmentExecutor.run(FragmentExecutor.java:292)
>  [drill-java-exec-1.2.0-SNAPSHOT.jar:1.2.0-SNAPSHOT]
> at 
> org.apache.drill.common.SelfCleaningRunnable.run(SelfCleaningRunnable.java:38)
>  [drill-common-1.2.0-SNAPSHOT.jar:1.2.0-SNAPSHOT]
> at 
> java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
>  [na:1.7.0_45]
> at 
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
>  [na:1.7.0_45]
> at java.lang.Thread.run(Thread.java:744) [na:1.7.0_45]
> Caused by: org.apache.drill.exec.rpc.ChannelClosedException: Channel closed 
> /10.10.100.201:31010 <--> /10.10.100.202:58705.
> at 
> org.apache.drill.exec.rpc.RpcBus$ChannelClosedHandler.operationComplete(RpcBus.java:167)
>  ~[drill-java-exec-1.2.0-SNAPSHOT.jar:1.2.0-SNAPSHOT]
> at 
> o

[jira] [Commented] (DRILL-3763) Cancel (Ctrl-C) one of concurrent queries results in ChannelClosedException

2016-06-13 Thread Khurram Faraaz (JIRA)

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

Khurram Faraaz commented on DRILL-3763:
---

Verified Fix on 6286c0a4.

> Cancel (Ctrl-C) one of concurrent queries results in ChannelClosedException
> ---
>
> Key: DRILL-3763
> URL: https://issues.apache.org/jira/browse/DRILL-3763
> Project: Apache Drill
>  Issue Type: Bug
>  Components: Execution - RPC
>Affects Versions: 1.2.0
> Environment: 4 node cluster CentOS
>Reporter: Khurram Faraaz
>Assignee: Deneche A. Hakim
> Fix For: 1.7.0
>
>
> Canceling a query from a set of concurrent queries executing on the same 
> table, results in ChannelClosedException when one of the queries in Canceled 
> using Ctrl-C from sqlline prompt.
> Steps to reproduce the problem,
> 1. Start, service map-warden start on 4 nodes.
> 2. Start eight sqlline sessions from eight different terminals, ./sqlline -u 
> "jdbc:drill:schema=dfs.tmp"
> 3. Run the below query from the eight sqlline sessions
> select * from `twoKeyJsn.json`;
> 4. While the queries are being executed, Cancel one of the queries on sqlline 
> prompt, issue Ctrl-C on sqlline.
> 5. you will note that after a few seconds/minutes, on one of the other 
> sqlline sessions there is a ChannelClosedException that is reported and that 
> query is reported as FAILED on the query profile on the Web UI.
> {code}
> 0: jdbc:drill:schema=dfs.tmp> select * from `twoKeyJsn.json`;
> ...
> | 1.31643767542E9  | h|
> | 9.02780441562E8  | b|
> | 6.46524413864E8  | l|
> java.lang.RuntimeException: java.sql.SQLException: SYSTEM ERROR: 
> ChannelClosedException: Channel closed /10.10.100.201:31010 <--> 
> /10.10.100.202:58705.
> Fragment 0:0
> [Error Id: bd765bd5-3921-4b58-89a7-cd87482f9088 on centos-01.qa.lab:31010]
>   at sqlline.IncrementalRows.hasNext(IncrementalRows.java:73)
>   at 
> sqlline.TableOutputFormat$ResizingRowsProvider.next(TableOutputFormat.java:87)
>   at sqlline.TableOutputFormat.print(TableOutputFormat.java:118)
>   at sqlline.SqlLine.print(SqlLine.java:1583)
>   at sqlline.Commands.execute(Commands.java:852)
>   at sqlline.Commands.sql(Commands.java:751)
>   at sqlline.SqlLine.dispatch(SqlLine.java:738)
>   at sqlline.SqlLine.begin(SqlLine.java:612)
>   at sqlline.SqlLine.start(SqlLine.java:366)
>   at sqlline.SqlLine.main(SqlLine.java:259)
> 0: jdbc:drill:schema=dfs.tmp> 
> {code}
> Stack trace from drillbit.log
> {code}
> 2015-09-10 23:23:55,019 [UserServer-1] INFO  
> o.a.d.e.w.fragment.FragmentExecutor - 
> 2a0df049-697d-f47b-86b5-1e2697946237:0:0: State change requested RUNNING --> 
> FAILED
> 2015-09-10 23:24:05,319 [2a0df049-697d-f47b-86b5-1e2697946237:frag:0:0] INFO  
> o.a.d.e.w.fragment.FragmentExecutor - 
> 2a0df049-697d-f47b-86b5-1e2697946237:0:0: State change requested FAILED --> 
> FINISHED
> 2015-09-10 23:24:05,331 [2a0df049-697d-f47b-86b5-1e2697946237:frag:0:0] ERROR 
> o.a.d.e.w.fragment.FragmentExecutor - SYSTEM ERROR: ChannelClosedException: 
> Channel closed /10.10.100.201:31010 <--> /10.10.100.202:58705.
> Fragment 0:0
> [Error Id: bd765bd5-3921-4b58-89a7-cd87482f9088 on centos-01.qa.lab:31010]
> org.apache.drill.common.exceptions.UserException: SYSTEM ERROR: 
> ChannelClosedException: Channel closed /10.10.100.201:31010 <--> 
> /10.10.100.202:58705.
> Fragment 0:0
> [Error Id: bd765bd5-3921-4b58-89a7-cd87482f9088 on centos-01.qa.lab:31010]
> at 
> org.apache.drill.common.exceptions.UserException$Builder.build(UserException.java:524)
>  ~[drill-common-1.2.0-SNAPSHOT.jar:1.2.0-SNAPSHOT]
> at 
> org.apache.drill.exec.work.fragment.FragmentExecutor.sendFinalState(FragmentExecutor.java:323)
>  [drill-java-exec-1.2.0-SNAPSHOT.jar:1.2.0-SNAPSHOT]
> at 
> org.apache.drill.exec.work.fragment.FragmentExecutor.cleanup(FragmentExecutor.java:178)
>  [drill-java-exec-1.2.0-SNAPSHOT.jar:1.2.0-SNAPSHOT]
> at 
> org.apache.drill.exec.work.fragment.FragmentExecutor.run(FragmentExecutor.java:292)
>  [drill-java-exec-1.2.0-SNAPSHOT.jar:1.2.0-SNAPSHOT]
> at 
> org.apache.drill.common.SelfCleaningRunnable.run(SelfCleaningRunnable.java:38)
>  [drill-common-1.2.0-SNAPSHOT.jar:1.2.0-SNAPSHOT]
> at 
> java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
>  [na:1.7.0_45]
> at 
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
>  [na:1.7.0_45]
> at java.lang.Thread.run(Thread.java:744) [na:1.7.0_45]
> Caused by: org.apache.drill.exec.rpc.ChannelClosedException: Channel closed 
> /10.10.100.201:31010 <--> /10.10.100.202:58705.
> at 
> org.apache.drill.exec.rpc.RpcBus$ChannelClosedHandler.operationComplete(RpcB

[jira] [Closed] (DRILL-4257) Ensure shutting down a Drillbit also shuts down all StoragePlugins

2016-06-13 Thread Khurram Faraaz (JIRA)

 [ 
https://issues.apache.org/jira/browse/DRILL-4257?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Khurram Faraaz closed DRILL-4257.
-

Verified.

> Ensure shutting down a Drillbit also shuts down all StoragePlugins
> --
>
> Key: DRILL-4257
> URL: https://issues.apache.org/jira/browse/DRILL-4257
> Project: Apache Drill
>  Issue Type: Bug
>  Components: Execution - Flow
>Reporter: Jacques Nadeau
>Assignee: Jacques Nadeau
> Fix For: 1.5.0
>
>
> Right now, if a StoragePlugin implementation relies on the close method to 
> clean up resources, those resources won't be cleaned up when the Drillbit 
> class is shutdown. This is because Drillbit doesn't actually close the 
> StoragePluginRegistry and associated resources. This causes problems in 
> leaking resources in tests.



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


[jira] [Commented] (DRILL-4291) Ensure the jdbc-all driver jar includes classes required to return VarChar[]

2016-06-13 Thread Khurram Faraaz (JIRA)

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

Khurram Faraaz commented on DRILL-4291:
---

Can you please list the class names here, so I can look for them in the 
jdbc-all driver jar file and verify this JIRA.

> Ensure the jdbc-all driver jar includes classes required to return VarChar[]
> 
>
> Key: DRILL-4291
> URL: https://issues.apache.org/jira/browse/DRILL-4291
> Project: Apache Drill
>  Issue Type: Bug
>  Components: Client - JDBC
>Affects Versions: 0.5.0
> Environment: Linux / 1.5-SNAPSHOT
>Reporter: Stefán Baxter
>Assignee: Jacques Nadeau
> Fix For: 1.5.0
>
>
> Hi,
> We are using the 1.5-SNAPSHOT version of the JDBC drilver (all) and we seem 
> to be getting this old thing:
> https://issues.apache.org/jira/browse/DRILL-2482
> We are either doing something wrong or this or this is a regression. Has 
> anyone else experienced not being able to get nested structures via the 
> latest JDBC driver?
> (I'm going to pull the lastest from master to be sure this has not been 
> solved)
> The error we get when accessing a field containing a sub-structure is :
> java.lang.NoClassDefFoundError: org/apache/hadoop/io/Text
> at 
> oadd.org.apache.drill.exec.util.JsonStringArrayList.(JsonStringArrayList.java:35)
> at 
> oadd.org.apache.drill.exec.vector.RepeatedVarCharVector$Accessor.getObject(RepeatedVarCharVector.java:293)
> at 
> oadd.org.apache.drill.exec.vector.RepeatedVarCharVector$Accessor.getObject(RepeatedVarCharVector.java:290)
> at 
> oadd.org.apache.drill.exec.vector.accessor.GenericAccessor.getObject(GenericAccessor.java:44)
> at 
> oadd.org.apache.drill.exec.vector.accessor.BoundCheckingAccessor.getObject(BoundCheckingAccessor.java:148)
> at 
> org.apache.drill.jdbc.impl.TypeConvertingSqlAccessor.getObject(TypeConvertingSqlAccessor.java:795)
> at 
> org.apache.drill.jdbc.impl.AvaticaDrillSqlAccessor.getObject(AvaticaDrillSqlAccessor.java:179)
> at 
> oadd.net.hydromatic.avatica.AvaticaResultSet.getObject(AvaticaResultSet.java:351)
> at 
> org.apache.drill.jdbc.impl.DrillResultSetImpl.getObject(DrillResultSetImpl.java:420)
> Regards,
>  -Stefan



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


[jira] [Assigned] (DRILL-4309) Make this option store.hive.optimize_scan_with_native_readers=true default

2016-06-13 Thread Arina Ielchiieva (JIRA)

 [ 
https://issues.apache.org/jira/browse/DRILL-4309?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Arina Ielchiieva reassigned DRILL-4309:
---

Assignee: Arina Ielchiieva

> Make this option store.hive.optimize_scan_with_native_readers=true default
> --
>
> Key: DRILL-4309
> URL: https://issues.apache.org/jira/browse/DRILL-4309
> Project: Apache Drill
>  Issue Type: Improvement
>  Components: Query Planning & Optimization
>Reporter: Sean Hsuan-Yi Chu
>Assignee: Arina Ielchiieva
> Fix For: 1.7.0
>
>
> This new feature has been around and used/tests in many scenarios. 
> We should enable this feature by default.



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


[jira] [Updated] (DRILL-4653) Malformed JSON should not stop the entire query from progressing

2016-06-13 Thread subbu srinivasan (JIRA)

 [ 
https://issues.apache.org/jira/browse/DRILL-4653?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

subbu srinivasan updated DRILL-4653:

Reviewer: Deneche A. Hakim

> Malformed JSON should not stop the entire query from progressing
> 
>
> Key: DRILL-4653
> URL: https://issues.apache.org/jira/browse/DRILL-4653
> Project: Apache Drill
>  Issue Type: Improvement
>  Components: Storage - JSON
>Affects Versions: 1.6.0
>Reporter: subbu srinivasan
>
> Currently Drill query terminates upon first encounter of a invalid JSON line.
> Drill has to continue progressing after ignoring the bad records. Something 
> similar to a setting of (ignore.malformed.json) would help.



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


[jira] [Created] (DRILL-4719) Need To Support IAM role based access for supporting Amazon S3

2016-06-13 Thread subbu srinivasan (JIRA)
subbu srinivasan created DRILL-4719:
---

 Summary: Need To Support IAM role based access for supporting 
Amazon S3
 Key: DRILL-4719
 URL: https://issues.apache.org/jira/browse/DRILL-4719
 Project: Apache Drill
  Issue Type: Improvement
  Components: Storage - Other
Affects Versions: 1.6.0
Reporter: subbu srinivasan


We need amazon secret accessid/credentials as part of the core-site.xml.
This is not ideal in many deployments, we would use IAM roles to accomplish
access to s3.





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


[jira] [Updated] (DRILL-4607) Add a split function that allows to separate string by a delimiter

2016-06-13 Thread Zelaine Fong (JIRA)

 [ 
https://issues.apache.org/jira/browse/DRILL-4607?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Zelaine Fong updated DRILL-4607:

Labels: doc-impacting  (was: )

> Add a split function that allows to separate string by a delimiter
> --
>
> Key: DRILL-4607
> URL: https://issues.apache.org/jira/browse/DRILL-4607
> Project: Apache Drill
>  Issue Type: New Feature
>  Components: Functions - Drill
>Affects Versions: 1.6.0
>Reporter: Alicia Alvarez
>Assignee: Alicia Alvarez
>  Labels: doc-impacting
> Fix For: 1.7.0
>
>
> Ex: Let's say I have records in a CSV file with the following schema
> {noformat}
> user_name, friend_list_separated_by_a_delimiter,other_fields
> ali,sam;adi;tom,45,...
> {noformat}
> I want to run a query which returns the friend list files as a repeated value.
> {noformat}
> select user_name, split(friend_list, ';') friends from userdata;
> {noformat}
> This should return the records in the following format
> {noformat}
> -
> | user_name |   friends |
> -
> |   ali |  [sam, adi, tom]  |
> -
> {noformat}



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


[jira] [Created] (DRILL-4720) MINDIR() and IMINDIR() functions return no results with metadata cache

2016-06-13 Thread Krystal (JIRA)
Krystal created DRILL-4720:
--

 Summary: MINDIR() and IMINDIR() functions return no results with 
metadata cache
 Key: DRILL-4720
 URL: https://issues.apache.org/jira/browse/DRILL-4720
 Project: Apache Drill
  Issue Type: Bug
  Components: Functions - Drill
Affects Versions: 1.7.0
Reporter: Krystal


Parquet directories with meta data cache return 0 rows for MINDIR and IMINDIR 
functions.

hadoop fs -ls /tmp/querylogs_4
Found 6 items
-rwxr-xr-x   3 mapr mapr  15406 2016-06-13 10:18 
/tmp/querylogs_4/.drill.parquet_metadata
drwxr-xr-x   - root root  4 2016-06-13 10:18 /tmp/querylogs_4/1985
drwxr-xr-x   - root root  3 2016-06-13 10:18 /tmp/querylogs_4/1999
drwxr-xr-x   - root root  3 2016-06-13 10:18 /tmp/querylogs_4/2005
drwxr-xr-x   - root root  4 2016-06-13 10:18 /tmp/querylogs_4/2014
drwxr-xr-x   - root root  6 2016-06-13 10:18 /tmp/querylogs_4/2016

hadoop fs -ls /tmp/querylogs_4/1985
Found 4 items
-rwxr-xr-x   3 mapr mapr   3634 2016-06-13 10:18 
/tmp/querylogs_4/1985/.drill.parquet_metadata
drwxr-xr-x   - root root  2 2016-06-13 10:18 /tmp/querylogs_4/1985/Feb
drwxr-xr-x   - root root  2 2016-06-13 10:18 /tmp/querylogs_4/1985/apr
drwxr-xr-x   - root root  2 2016-06-13 10:18 /tmp/querylogs_4/1985/jan 

SELECT * FROM `dfs.tmp`.`querylogs_4` WHERE dir0 = 
MINDIR('dfs.tmp','querylogs_4');
+---+---+--+---++++---+---+---+
| voter_id  | name  | age  | registration  | contributions  | voterzone  | 
date_time  | dir0  | dir1  | dir2  |
+---+---+--+---++++---+---+---+
+---+---+--+---++++---+---+---+
No rows selected (0.803 seconds)

If the meta cache is removed, expected data is returned.

Here is the physical plan:
{code}
00-00Screen : rowType = RecordType(ANY *): rowcount = 3.75, cumulative cost 
= {54.125 rows, 169.125 cpu, 0.0 io, 0.0 network, 0.0 memory}, id = 664191
00-01  Project(*=[$0]) : rowType = RecordType(ANY *): rowcount = 3.75, 
cumulative cost = {53.75 rows, 168.75 cpu, 0.0 io, 0.0 network, 0.0 memory}, id 
= 664190
00-02Project(T51¦¦*=[$0]) : rowType = RecordType(ANY T51¦¦*): rowcount 
= 3.75, cumulative cost = {53.75 rows, 168.75 cpu, 0.0 io, 0.0 network, 0.0 
memory}, id = 664189
00-03  SelectionVectorRemover : rowType = RecordType(ANY T51¦¦*, ANY 
dir0): rowcount = 3.75, cumulative cost = {53.75 rows, 168.75 cpu, 0.0 io, 0.0 
network, 0.0 memory}, id = 664188
00-04Filter(condition=[=($1, '.drill.parquet_metadata')]) : rowType 
= RecordType(ANY T51¦¦*, ANY dir0): rowcount = 3.75, cumulative cost = {50.0 
rows, 165.0 cpu, 0.0 io, 0.0 network, 0.0 memory}, id = 664187
00-05  Project(T51¦¦*=[$0], dir0=[$1]) : rowType = RecordType(ANY 
T51¦¦*, ANY dir0): rowcount = 25.0, cumulative cost = {25.0 rows, 50.0 cpu, 0.0 
io, 0.0 network, 0.0 memory}, id = 664186
00-06Scan(groupscan=[ParquetGroupScan 
[entries=[ReadEntryWithPath 
[path=/tmp/querylogs_4/2005/May/voter25.parquet/0_0_0.parquet]], 
selectionRoot=/tmp/querylogs_4, numFiles=1, usedMetadataFile=true, 
columns=[`*`]]]) : rowType = (DrillRecordRow[*, dir0]): rowcount = 25.0, 
cumulative cost = {25.0 rows, 50.0 cpu, 0.0 io, 0.0 network, 0.0 memory}, id = 
664185
{code}

Here is the plan for the same query against the same directory structure 
without meta data cache:
{code}
00-00Screen : rowType = RecordType(ANY *): rowcount = 75.0, cumulative cost 
= {82.5 rows, 157.5 cpu, 0.0 io, 0.0 network, 0.0 memory}, id = 664312
00-01  Project(*=[$0]) : rowType = RecordType(ANY *): rowcount = 75.0, 
cumulative cost = {75.0 rows, 150.0 cpu, 0.0 io, 0.0 network, 0.0 memory}, id = 
664311
00-02Project(*=[$0]) : rowType = RecordType(ANY *): rowcount = 75.0, 
cumulative cost = {75.0 rows, 150.0 cpu, 0.0 io, 0.0 network, 0.0 memory}, id = 
664310
00-03  Scan(groupscan=[ParquetGroupScan [entries=[ReadEntryWithPath 
[path=maprfs:///tmp/querylogs_1/1985/Feb/voter10.parquet/0_0_0.parquet], 
ReadEntryWithPath 
[path=maprfs:///tmp/querylogs_1/1985/jan/voter5.parquet/0_0_0.parquet], 
ReadEntryWithPath 
[path=maprfs:///tmp/querylogs_1/1985/apr/voter65.parquet/0_0_0.parquet]], 
selectionRoot=maprfs:/tmp/querylogs_1, numFiles=3, usedMetadataFile=false, 
columns=[`*`]]]) : rowType = (DrillRecordRow[*, dir0]): rowcount = 75.0, 
cumulative cost = {75.0 rows, 150.0 cpu, 0.0 io, 0.0 network, 0.0 memory}, id = 
664309
{code}



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


[jira] [Commented] (DRILL-4525) Query with BETWEEN clause on Date and Timestamp values fails with Validation Error

2016-06-13 Thread Rahul Challapalli (JIRA)

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

Rahul Challapalli commented on DRILL-4525:
--

Any idea when I can expect this to be resolved?

> Query with BETWEEN clause on Date and Timestamp values fails with Validation 
> Error
> --
>
> Key: DRILL-4525
> URL: https://issues.apache.org/jira/browse/DRILL-4525
> Project: Apache Drill
>  Issue Type: Bug
>  Components: Query Planning & Optimization
>Reporter: Abhishek Girish
>Assignee: Sean Hsuan-Yi Chu
>Priority: Critical
>
> Query: (simplified variant of TPC-DS Query37)
> {code}
> SELECT
>*
> FROM   
>date_dim
> WHERE   
>d_date BETWEEN Cast('1999-03-06' AS DATE) AND  (
>   Cast('1999-03-06' AS DATE) + INTERVAL '60' day)
> LIMIT 10;
> {code}
> Error:
> {code}
> Error: VALIDATION ERROR: From line 6, column 8 to line 7, column 64: Cannot 
> apply 'BETWEEN ASYMMETRIC' to arguments of type ' BETWEEN ASYMMETRIC 
>  AND '. Supported form(s): ' BETWEEN 
>  AND '
> SQL Query null
> [Error Id: 223fb37c-f561-4a37-9283-871dc6f4d6d0 on abhi2:31010] 
> (state=,code=0)
> {code}
> This is a regression from 1.6.0. 



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


[jira] [Commented] (DRILL-4525) Query with BETWEEN clause on Date and Timestamp values fails with Validation Error

2016-06-13 Thread Zelaine Fong (JIRA)

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

Zelaine Fong commented on DRILL-4525:
-

[~jni] - It looks like you're code reviewing this change.  Are the latest 
changes good to go?

> Query with BETWEEN clause on Date and Timestamp values fails with Validation 
> Error
> --
>
> Key: DRILL-4525
> URL: https://issues.apache.org/jira/browse/DRILL-4525
> Project: Apache Drill
>  Issue Type: Bug
>  Components: Query Planning & Optimization
>Reporter: Abhishek Girish
>Assignee: Sean Hsuan-Yi Chu
>Priority: Critical
>
> Query: (simplified variant of TPC-DS Query37)
> {code}
> SELECT
>*
> FROM   
>date_dim
> WHERE   
>d_date BETWEEN Cast('1999-03-06' AS DATE) AND  (
>   Cast('1999-03-06' AS DATE) + INTERVAL '60' day)
> LIMIT 10;
> {code}
> Error:
> {code}
> Error: VALIDATION ERROR: From line 6, column 8 to line 7, column 64: Cannot 
> apply 'BETWEEN ASYMMETRIC' to arguments of type ' BETWEEN ASYMMETRIC 
>  AND '. Supported form(s): ' BETWEEN 
>  AND '
> SQL Query null
> [Error Id: 223fb37c-f561-4a37-9283-871dc6f4d6d0 on abhi2:31010] 
> (state=,code=0)
> {code}
> This is a regression from 1.6.0. 



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


[jira] [Created] (DRILL-4721) Doc "dateDiff" in Drill

2016-06-13 Thread Bridget Bevens (JIRA)
Bridget Bevens created DRILL-4721:
-

 Summary: Doc "dateDiff" in Drill
 Key: DRILL-4721
 URL: https://issues.apache.org/jira/browse/DRILL-4721
 Project: Apache Drill
  Issue Type: Task
  Components: Documentation
Reporter: Bridget Bevens
Assignee: Bridget Bevens
Priority: Minor


Fwd: [mapr-tech-qa:12242]Doc "dateDiff" in Drill
Inbox
x 

Neeraja Rentachintala
3:32 PM (19 minutes ago)

to me 
we should document the datediff function. Cisco was asking about it today.
-- Forwarded message --
From: Bob Rumsby 
Date: Thu, Aug 20, 2015 at 11:56 AM
Subject: Re: [mapr-tech-qa:12242] "dateDiff" in Drill
To: "mapr-tech...@maprtech.com" 


Yes, it should be. We can fix that.

Bob

On Thu, Aug 20, 2015 at 11:46 AM, Joseph Blue  wrote:
Seems as though functions like datediff should be here:
https://drill.apache.org/docs/date-time-functions-and-arithmetic/


On Thu, Aug 20, 2015 at 11:32 AM, Ted Dunning  wrote:
Joe

Do you have a suggestion for the docs?  Perhaps a few cross links would make it 
better?

Sent from my iPhone

On Aug 20, 2015, at 5:36, Joseph Blue  wrote:

OK, duh. Thanks for that. I just went down the wrong path in the documentation. 
This obviously does exactly what I want.

On Wed, Aug 19, 2015 at 10:26 PM, Mehant Baid  wrote:
You can use the datediff function as follows:
 select datediff(date '2008-2-23', date '2008-1-20') from cp.`employee.json` 
limit 1;

+-+

| EXPR$0  |

+-+

| 34  |


+-+



Thanks

Mehant


On Wed, Aug 19, 2015 at 7:00 PM, Joseph Blue  wrote:
Want to get the difference between two dates in Drill. I used the AGE function 
which produces an interval. But I want the answer in days, not months & days. 
Am I missing something from the documentation?

select age(cast('2015-01-01' as timestamp),cast('2014-11-30' as timestamp)) 
from sys.version;
+-+
| EXPR$0  |
+-+
| P1M2D   |
+-+

-- 
Joseph Blue
Data Scientist



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


[jira] [Commented] (DRILL-3149) TextReader should support multibyte line delimiters

2016-06-13 Thread ASF GitHub Bot (JIRA)

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

ASF GitHub Bot commented on DRILL-3149:
---

Github user parthchandra commented on the issue:

https://github.com/apache/drill/pull/500
  
Looks Good. Can you add another test case where a field contains a some of 
the initial bytes of the multibyte line delimiter. 


> TextReader should support multibyte line delimiters
> ---
>
> Key: DRILL-3149
> URL: https://issues.apache.org/jira/browse/DRILL-3149
> Project: Apache Drill
>  Issue Type: Improvement
>  Components: Storage - Text & CSV
>Affects Versions: 1.0.0, 1.1.0
>Reporter: Jim Scott
>Assignee: Arina Ielchiieva
>Priority: Minor
> Fix For: Future
>
>
> lineDelimiter in the TextFormatConfig doesn't support \r\n for record 
> delimiters.



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


[jira] [Commented] (DRILL-4721) Doc "dateDiff" in Drill

2016-06-13 Thread Bridget Bevens (JIRA)

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

Bridget Bevens commented on DRILL-4721:
---

Cool. I believe so, let me check.

On the datediff, it seems like we have it but never documented? I see at least 
one JIRA around this.
https://issues.apache.org/jira/browse/DRILL-4116

On Mon, Jun 13, 2016 at 1:24 PM, Zelaine Fong  wrote:
Alicia Alvarez recently contributed DRILL-4607.  Is that what you're looking 
for, as far as #2?

-- Zelaine

On Mon, Jun 13, 2016 at 1:15 PM, Neeraja Rentachintala 
 wrote:
A customer of ours is interested in using the following functions in Hive with 
Drill.

I was wondering if they can use these functions as Hive UDFs within Drill. Any 
thoughts on if this is possible. Did anyone try to do this.
Additionally would do we have Drill equivalents for these (I am certain that we 
don't have equivalents for the split ones).

-Neeraja


int
datediff(string enddate, string startdate)
Returns the number of days from startdate to enddate: datediff('2009-03-01', 
'2009-02-27') = 2.
array
split(string str, string pat)
Splits str around pat (pat is a regular expression).
map
str_to_map(text[, delimiter1, delimiter2])
Splits text into key-value pairs using two delimiters. Delimiter1 separates 
text into K-V pairs, and Delimiter2 splits each K-V pair. Default delimiters 
are ',' for delimiter1 and '=' for delimiter2.


> Doc "dateDiff" in Drill
> ---
>
> Key: DRILL-4721
> URL: https://issues.apache.org/jira/browse/DRILL-4721
> Project: Apache Drill
>  Issue Type: Task
>  Components: Documentation
>Reporter: Bridget Bevens
>Assignee: Bridget Bevens
>Priority: Minor
>
> Fwd: [mapr-tech-qa:12242]Doc "dateDiff" in Drill
> Inbox
> x 
> Neeraja Rentachintala
> 3:32 PM (19 minutes ago)
> to me 
> we should document the datediff function. Cisco was asking about it today.
> -- Forwarded message --
> From: Bob Rumsby 
> Date: Thu, Aug 20, 2015 at 11:56 AM
> Subject: Re: [mapr-tech-qa:12242] "dateDiff" in Drill
> To: "mapr-tech...@maprtech.com" 
> Yes, it should be. We can fix that.
> Bob
> On Thu, Aug 20, 2015 at 11:46 AM, Joseph Blue  wrote:
> Seems as though functions like datediff should be here:
> https://drill.apache.org/docs/date-time-functions-and-arithmetic/
> On Thu, Aug 20, 2015 at 11:32 AM, Ted Dunning  wrote:
> Joe
> Do you have a suggestion for the docs?  Perhaps a few cross links would make 
> it better?
> Sent from my iPhone
> On Aug 20, 2015, at 5:36, Joseph Blue  wrote:
> OK, duh. Thanks for that. I just went down the wrong path in the 
> documentation. 
> This obviously does exactly what I want.
> On Wed, Aug 19, 2015 at 10:26 PM, Mehant Baid  wrote:
> You can use the datediff function as follows:
>  select datediff(date '2008-2-23', date '2008-1-20') from cp.`employee.json` 
> limit 1;
> +-+
> | EXPR$0  |
> +-+
> | 34  |
> +-+
> Thanks
> Mehant
> On Wed, Aug 19, 2015 at 7:00 PM, Joseph Blue  wrote:
> Want to get the difference between two dates in Drill. I used the AGE 
> function which produces an interval. But I want the answer in days, not 
> months & days. Am I missing something from the documentation?
> select age(cast('2015-01-01' as timestamp),cast('2014-11-30' as timestamp)) 
> from sys.version;
> +-+
> | EXPR$0  |
> +-+
> | P1M2D   |
> +-+
> -- 
> Joseph Blue
> Data Scientist



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


[jira] [Commented] (DRILL-4701) Fix log name and missing lines in logs on Web UI

2016-06-13 Thread ASF GitHub Bot (JIRA)

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

ASF GitHub Bot commented on DRILL-4701:
---

Github user parthchandra commented on the issue:

https://github.com/apache/drill/pull/511
  
LGTM +1


> Fix log name and missing lines in logs on Web UI
> 
>
> Key: DRILL-4701
> URL: https://issues.apache.org/jira/browse/DRILL-4701
> Project: Apache Drill
>  Issue Type: Bug
>Reporter: Arina Ielchiieva
>Assignee: Arina Ielchiieva
> Fix For: 1.7.0
>
>
> 1. When the log files are downloaded from the ui, the name of the downloaded 
> file is "download". We should save the file with the same name as the log 
> file (ie. drillbit.log)
> 2. The last N lines of the log file displayed in the web UI do not match the 
> log file itself. Some lines are missing compared with actual log.



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


[jira] [Commented] (DRILL-4715) Java compilation error for a query with large number of expressions

2016-06-13 Thread Jinfeng Ni (JIRA)

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

Jinfeng Ni commented on DRILL-4715:
---

[~jnadeau], do you know how to run the unit test in 
https://github.com/apache/drill/blob/master/exec/java-exec/src/test/java/org/apache/drill/exec/compile/TestLargeFileCompilation.java?
 I can manually run those testcases in IDE, but I'm wondering if there is a 
switch to make mvn surefire run those testcase as well.

 

> Java compilation error for a query with large number of expressions
> ---
>
> Key: DRILL-4715
> URL: https://issues.apache.org/jira/browse/DRILL-4715
> Project: Apache Drill
>  Issue Type: Bug
>  Components: Execution - Codegen
>Reporter: Jinfeng Ni
>
> The following query would hit compilation error, when Drill generates and 
> compiles the run-time code. 
> Q1 :
> {code}
> select  expr1, expr2, expr3, , exprN
> from table
> {code} 
> In Q1, expr1, expr2, ..., exprN are non-trivial expression (in stead of 
> simply column reference), and N is big enough, then the run-time generated 
> code may have a method which goes beyond the 64k limit imposed by JVM. 
> This seems to be a regression from DRILL-3912 (Common subexpression 
> elimination). CSE tries to put as many expressions in one block as possible, 
> to detect and eliminate as many CSE as possible. However, this implies we may 
> end up with big method with compilation error.
> 



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