You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@impala.apache.org by "Alexander Behm (JIRA)" <ji...@apache.org> on 2017/06/16 06:12:00 UTC
[jira] [Created] (IMPALA-5524) NullPointerException during planning
with DISABLE_UNSAFE_SPILLS=TRUE
Alexander Behm created IMPALA-5524:
--------------------------------------
Summary: NullPointerException during planning with DISABLE_UNSAFE_SPILLS=TRUE
Key: IMPALA-5524
URL: https://issues.apache.org/jira/browse/IMPALA-5524
Project: IMPALA
Issue Type: Bug
Components: Frontend
Affects Versions: Impala 2.8.0, Impala 2.6.0, Impala 2.7.0
Reporter: Alexander Behm
Setting the DISABLE_UNSAFE_SPILLS query option to TRUE leads to a NullPointerException during query planning if all tables of the query have stats.
Repro:
{code}
create table t (i int);
compute stats t;
set disable_unsafe_spills=true;
select * from t;
ERROR: NullPointerException: null
{code}
Stack:
{code}
I0615 23:06:54.581377 11228 jni-util.cc:176] java.lang.NullPointerException
at org.apache.impala.service.Frontend.createExecRequest(Frontend.java:1027)
at org.apache.impala.service.Frontend.createExecRequest(Frontend.java:1104)
at org.apache.impala.service.JniFrontend.createExecRequest(JniFrontend.java:156)
{code}
The problem is here:
{code}
boolean disableSpilling =
queryCtx.client_request.query_options.isDisable_unsafe_spills()
&& !queryCtx.tables_missing_stats.isEmpty() <-- tables_missing_stats can be null
&& !analysisResult.getAnalyzer().hasPlanHints();
queryCtx.setDisable_spilling(disableSpilling);
{code}
The reason why "tables_missing_stats" is null can be found in Frontend.createPlanExecInfo():
{code}
...
// Clear pre-existing lists to avoid adding duplicate entries in FE tests.
queryCtx.unsetTables_missing_stats(); <-- sets to null
queryCtx.unsetTables_with_corrupt_stats();
for (TTableName tableName: tablesMissingStats) {
queryCtx.addToTables_missing_stats(tableName);
}
for (TTableName tableName: tablesWithCorruptStats) {
queryCtx.addToTables_with_corrupt_stats(tableName);
}
for (TTableName tableName: tablesWithMissingDiskIds) {
queryCtx.addToTables_missing_diskids(tableName);
}
...
{code}
--
This message was sent by Atlassian JIRA
(v6.4.14#64029)