You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@spark.apache.org by "Michael Armbrust (JIRA)" <ji...@apache.org> on 2014/08/03 21:37:11 UTC
[jira] [Resolved] (SPARK-2814) HiveThriftServer throws NPE when
executing native commands
[ https://issues.apache.org/jira/browse/SPARK-2814?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Michael Armbrust resolved SPARK-2814.
-------------------------------------
Resolution: Fixed
Fix Version/s: 1.1.0
Assignee: Cheng Lian
> HiveThriftServer throws NPE when executing native commands
> ----------------------------------------------------------
>
> Key: SPARK-2814
> URL: https://issues.apache.org/jira/browse/SPARK-2814
> Project: Spark
> Issue Type: Bug
> Components: SQL
> Affects Versions: 1.1.0
> Reporter: Cheng Lian
> Assignee: Cheng Lian
> Fix For: 1.1.0
>
>
> After [PR #1686|https://github.com/apache/spark/pull/1686], {{HiveThriftServer2}} throws exception when executing native commands.
> The reason is that initialization of {{HiveContext.sessionState.out}} and {{HiveContext.sessionState.err}} were made lazy, while {{HiveThriftServer2}} uses an overriden version of {{HiveContext}} that doesn't know how to initialize these two streams. When {{HiveContext.runHive}} tries to write to {{HiveContext.sessionState.out}}, an NPE is throw.
> Reproduction steps:
> # Start HiveThriftServer2
> # Connect to it via beeline
> # Execute `set;`
> Exception thrown:
> {code}
> ======================
> HIVE FAILURE OUTPUT
> ======================
> ======================
> END HIVE FAILURE OUTPUT
> ======================
> 14/08/03 21:30:55 ERROR SparkSQLOperationManager: Error executing query:
> java.lang.NullPointerException
> at org.apache.spark.sql.hive.HiveContext.runHive(HiveContext.scala:210)
> at org.apache.spark.sql.hive.HiveContext.runSqlHive(HiveContext.scala:173)
> at org.apache.spark.sql.hive.HiveContext.set(HiveContext.scala:144)
> at org.apache.spark.sql.execution.SetCommand.sideEffectResult$lzycompute(commands.scala:59)
> at org.apache.spark.sql.execution.SetCommand.sideEffectResult(commands.scala:50)
> ...
> {code}
--
This message was sent by Atlassian JIRA
(v6.2#6252)
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@spark.apache.org
For additional commands, e-mail: issues-help@spark.apache.org