You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@drill.apache.org by "Lee Butts (JIRA)" <ji...@apache.org> on 2016/12/15 03:11:58 UTC

[jira] [Commented] (DRILL-4117) Ensure proper null outcome handling during FileSelection creation and its subclasses.

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

Lee Butts commented on DRILL-4117:
----------------------------------

We're trying to upgrade to 1.9.0 and hitting the following NPE due to this issue (setHadWildcard called on null FileSelection):

{code}
Caused by: java.lang.NullPointerException: null
	at org.apache.drill.exec.store.dfs.FileSelection.create(FileSelection.java:291)
	at org.apache.drill.exec.store.dfs.WorkspaceSchemaFactory$WorkspaceSchema.create(WorkspaceSchemaFactory.java:571)
	at org.apache.drill.exec.store.dfs.WorkspaceSchemaFactory$WorkspaceSchema.create(WorkspaceSchemaFactory.java:372)
	at org.apache.drill.exec.planner.sql.ExpandingConcurrentMap.getNewEntry(ExpandingConcurrentMap.java:96)
	at org.apache.drill.exec.planner.sql.ExpandingConcurrentMap.get(ExpandingConcurrentMap.java:90)
	at org.apache.drill.exec.store.dfs.WorkspaceSchemaFactory$WorkspaceSchema.getTable(WorkspaceSchemaFactory.java:526)
	at org.apache.calcite.jdbc.SimpleCalciteSchema.getTable(SimpleCalciteSchema.java:82)
	at org.apache.calcite.prepare.CalciteCatalogReader.getTableFrom(CalciteCatalogReader.java:119)
	at org.apache.calcite.prepare.CalciteCatalogReader.getTable(CalciteCatalogReader.java:102)
	at org.apache.calcite.prepare.CalciteCatalogReader.getTable(CalciteCatalogReader.java:73)
	at org.apache.calcite.sql.validate.EmptyScope.getTableNamespace(EmptyScope.java:75)
	at org.apache.calcite.sql.validate.DelegatingScope.getTableNamespace(DelegatingScope.java:124)
	at org.apache.calcite.sql.validate.IdentifierNamespace.validateImpl(IdentifierNamespace.java:104)
	at org.apache.calcite.sql.validate.AbstractNamespace.validate(AbstractNamespace.java:86)
	at org.apache.calcite.sql.validate.SqlValidatorImpl.validateNamespace(SqlValidatorImpl.java:883)
	at org.apache.calcite.sql.validate.AbstractNamespace.getRowType(AbstractNamespace.java:124)
	at org.apache.calcite.sql.validate.IdentifierNamespace.getRowType(IdentifierNamespace.java:45)
	at org.apache.calcite.sql.validate.ListScope.findQualifyingTableName(ListScope.java:142)
	at org.apache.calcite.sql.validate.DelegatingScope.fullyQualify(DelegatingScope.java:154)
	at org.apache.calcite.sql.validate.SqlValidatorUtil$ExpansionAndDeepCopier.visit(SqlValidatorUtil.java:821)
	at org.apache.calcite.sql.validate.SqlValidatorUtil$ExpansionAndDeepCopier.visit(SqlValidatorUtil.java:799)
	at org.apache.calcite.sql.SqlIdentifier.accept(SqlIdentifier.java:274)
	at org.apache.calcite.sql.util.SqlShuttle$CallCopyingArgHandler.visitChild(SqlShuttle.java:134)
	at org.apache.calcite.sql.util.SqlShuttle$CallCopyingArgHandler.visitChild(SqlShuttle.java:101)
	at org.apache.calcite.sql.SqlOperator.acceptCall(SqlOperator.java:831)
	at org.apache.calcite.sql.validate.SqlValidatorUtil$DeepCopier.visitScoped(SqlValidatorUtil.java:866)
	at org.apache.calcite.sql.validate.SqlScopedShuttle.visit(SqlScopedShuttle.java:50)
	at org.apache.calcite.sql.validate.SqlScopedShuttle.visit(SqlScopedShuttle.java:32)
	at org.apache.calcite.sql.SqlCall.accept(SqlCall.java:130)
	at org.apache.calcite.sql.util.SqlShuttle$CallCopyingArgHandler.visitChild(SqlShuttle.java:134)
	at org.apache.calcite.sql.util.SqlShuttle$CallCopyingArgHandler.visitChild(SqlShuttle.java:101)
	at org.apache.calcite.sql.SqlOperator.acceptCall(SqlOperator.java:831)
	at org.apache.calcite.sql.validate.SqlValidatorUtil$DeepCopier.visitScoped(SqlValidatorUtil.java:866)
	at org.apache.calcite.sql.validate.SqlScopedShuttle.visit(SqlScopedShuttle.java:50)
	at org.apache.calcite.sql.validate.SqlScopedShuttle.visit(SqlScopedShuttle.java:32)
	at org.apache.calcite.sql.SqlCall.accept(SqlCall.java:130)
	at org.apache.calcite.sql.validate.SqlValidatorUtil$DeepCopier.visit(SqlValidatorUtil.java:856)
	at org.apache.calcite.sql.validate.SqlValidatorUtil$DeepCopier.visit(SqlValidatorUtil.java:843)
	at org.apache.calcite.sql.SqlNodeList.accept(SqlNodeList.java:152)
	at org.apache.calcite.sql.validate.SqlValidatorUtil$ExpansionAndDeepCopier.copy(SqlValidatorUtil.java:806)
	at org.apache.calcite.sql.validate.AggregatingSelectScope.<init>(AggregatingSelectScope.java:92)
	at org.apache.calcite.sql.validate.SqlValidatorImpl.registerQuery(SqlValidatorImpl.java:2206)
	at org.apache.calcite.sql.validate.SqlValidatorImpl.registerQuery(SqlValidatorImpl.java:2128)
	at org.apache.calcite.sql.validate.SqlValidatorImpl.validateScopedExpression(SqlValidatorImpl.java:841)
	at org.apache.calcite.sql.validate.SqlValidatorImpl.validate(SqlValidatorImpl.java:557)
	at org.apache.drill.exec.planner.sql.SqlConverter.validate(SqlConverter.java:164)

{code}

> Ensure proper null outcome handling during FileSelection creation and its subclasses.
> -------------------------------------------------------------------------------------
>
>                 Key: DRILL-4117
>                 URL: https://issues.apache.org/jira/browse/DRILL-4117
>             Project: Apache Drill
>          Issue Type: Bug
>            Reporter: Hanifi Gunes
>            Assignee: Hanifi Gunes
>
> Hakim identified the following does not make a null check upon the result of  FileSelection.create(...). This issue is to ensure proper null outcome handling during FileSelection creation and its subclasses or to return a non-null default type.
> {quote}
> onFileSystemPartitionDescriptor.createNewGroupScan() passes the output to FileGroupScan.close() which expects it to be not null
> {quote}



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