spark-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Michael Armbrust (JIRA)" <j...@apache.org>
Subject [jira] [Resolved] (SPARK-2814) HiveThriftServer throws NPE when executing native commands
Date Sun, 03 Aug 2014 19:37:11 GMT

     [ 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


Mime
View raw message