drill-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Khurram Faraaz (JIRA)" <j...@apache.org>
Subject [jira] [Created] (DRILL-4058) NPE - we need a better error message
Date Tue, 10 Nov 2015 18:40:10 GMT
Khurram Faraaz created DRILL-4058:
-------------------------------------

             Summary: NPE - we need a better error message
                 Key: DRILL-4058
                 URL: https://issues.apache.org/jira/browse/DRILL-4058
             Project: Apache Drill
          Issue Type: Bug
          Components: Execution - Flow
    Affects Versions: 1.3.0
            Reporter: Khurram Faraaz


I am seeing an NPE, we need a better error message. It seems to be coming from DrillBufInputStream.getStream(DrillBufInputStream.java:57)

here is the data used in test
{code}
[root@centos-01 ~]# cat test.json
{
"c1":{"key":"value1"}
}
[root@centos-01 ~]#
{code}

Failing query that gives NPE.

{code}
0: jdbc:drill:schema=dfs.tmp> select convert_from(t,'JSON') jsn FROM `test.json` t;
Error: SYSTEM ERROR: NullPointerException

Fragment 0:0

[Error Id: 3f6a652a-8db1-4dcc-ae0d-db27dac1675e on centos-04.qa.lab:31010] (state=,code=0)
{code}

Stack trace from drillbit.log

{code}
2015-11-10 03:14:12,512 [29be9efb-1900-176c-5c40-84b9506f8440:frag:0:0] ERROR o.a.d.e.w.fragment.FragmentExecutor
- SYSTEM ERROR: NullPointerException

Fragment 0:0

[Error Id: 3f6a652a-8db1-4dcc-ae0d-db27dac1675e on centos-04.qa.lab:31010]
org.apache.drill.common.exceptions.UserException: SYSTEM ERROR: NullPointerException

Fragment 0:0

[Error Id: 3f6a652a-8db1-4dcc-ae0d-db27dac1675e on centos-04.qa.lab:31010]
        at org.apache.drill.common.exceptions.UserException$Builder.build(UserException.java:534)
~[drill-common-1.3.0.jar:1.3.0]
        at org.apache.drill.exec.work.fragment.FragmentExecutor.sendFinalState(FragmentExecutor.java:321)
[drill-java-exec-1.3.0.jar:1.3.0]
        at org.apache.drill.exec.work.fragment.FragmentExecutor.cleanup(FragmentExecutor.java:184)
[drill-java-exec-1.3.0.jar:1.3.0]
        at org.apache.drill.exec.work.fragment.FragmentExecutor.run(FragmentExecutor.java:290)
[drill-java-exec-1.3.0.jar:1.3.0]
        at org.apache.drill.common.SelfCleaningRunnable.run(SelfCleaningRunnable.java:38)
[drill-common-1.3.0.jar:1.3.0]
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
[na:1.7.0_85]
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
[na:1.7.0_85]
        at java.lang.Thread.run(Thread.java:745) [na:1.7.0_85]
Caused by: org.apache.drill.common.exceptions.DrillRuntimeException: Error while converting
from JSON.
        at org.apache.drill.exec.test.generated.ProjectorGen3.doEval(ProjectorTemplate.java:121)
~[na:na]
        at org.apache.drill.exec.test.generated.ProjectorGen3.projectRecords(ProjectorTemplate.java:62)
~[na:na]
        at org.apache.drill.exec.physical.impl.project.ProjectRecordBatch.doWork(ProjectRecordBatch.java:174)
~[drill-java-exec-1.3.0.jar:1.3.0]
        at org.apache.drill.exec.record.AbstractSingleRecordBatch.innerNext(AbstractSingleRecordBatch.java:93)
~[drill-java-exec-1.3.0.jar:1.3.0]
        at org.apache.drill.exec.physical.impl.project.ProjectRecordBatch.innerNext(ProjectRecordBatch.java:131)
~[drill-java-exec-1.3.0.jar:1.3.0]
        at org.apache.drill.exec.record.AbstractRecordBatch.next(AbstractRecordBatch.java:156)
~[drill-java-exec-1.3.0.jar:1.3.0]
        at org.apache.drill.exec.physical.impl.BaseRootExec.next(BaseRootExec.java:104) ~[drill-java-exec-1.3.0.jar:1.3.0]
        at org.apache.drill.exec.physical.impl.ScreenCreator$ScreenRoot.innerNext(ScreenCreator.java:80)
~[drill-java-exec-1.3.0.jar:1.3.0]
        at org.apache.drill.exec.physical.impl.BaseRootExec.next(BaseRootExec.java:94) ~[drill-java-exec-1.3.0.jar:1.3.0]
        at org.apache.drill.exec.work.fragment.FragmentExecutor$1.run(FragmentExecutor.java:256)
~[drill-java-exec-1.3.0.jar:1.3.0]
        at org.apache.drill.exec.work.fragment.FragmentExecutor$1.run(FragmentExecutor.java:250)
~[drill-java-exec-1.3.0.jar:1.3.0]
        at java.security.AccessController.doPrivileged(Native Method) ~[na:1.7.0_85]
        at javax.security.auth.Subject.doAs(Subject.java:415) ~[na:1.7.0_85]
        at org.apache.hadoop.security.UserGroupInformation.doAs(UserGroupInformation.java:1595)
~[hadoop-common-2.7.0-mapr-1506.jar:na]
        at org.apache.drill.exec.work.fragment.FragmentExecutor.run(FragmentExecutor.java:250)
[drill-java-exec-1.3.0.jar:1.3.0]
        ... 4 common frames omitted
Caused by: java.lang.NullPointerException: null
        at org.apache.drill.exec.vector.complex.fn.DrillBufInputStream.getStream(DrillBufInputStream.java:57)
~[drill-java-exec-1.3.0.jar:1.3.0]
        at org.apache.drill.exec.vector.complex.fn.JsonReader.setSource(JsonReader.java:107)
~[drill-java-exec-1.3.0.jar:1.3.0]
        at org.apache.drill.exec.test.generated.ProjectorGen3.doEval(ProjectorTemplate.java:117)
~[na:na]
        ... 18 common frames omitted
{code}



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

Mime
View raw message