Skip to content

Commit

Permalink
Revert "[SPARK-2970] [SQL] spark-sql script ends with IOException whe…
Browse files Browse the repository at this point in the history
…n EventLogging is enabled"

Revert apache#1891 due to issues with hadoop 1 compatibility.

Author: Michael Armbrust <michael@databricks.com>

Closes apache#2007 from marmbrus/revert1891 and squashes the following commits:

68706c0 [Michael Armbrust] Revert "[SPARK-2970] [SQL] spark-sql script ends with IOException when EventLogging is enabled"
  • Loading branch information
marmbrus authored and conviva-zz committed Sep 4, 2014
1 parent 7fb7151 commit ff10c53
Showing 1 changed file with 2 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,6 @@ import jline.{ConsoleReader, History}
import org.apache.commons.lang.StringUtils
import org.apache.commons.logging.LogFactory
import org.apache.hadoop.conf.Configuration
import org.apache.hadoop.fs.FileSystem
import org.apache.hadoop.util.ShutdownHookManager
import org.apache.hadoop.hive.cli.{CliDriver, CliSessionState, OptionsProcessor}
import org.apache.hadoop.hive.common.LogUtils.LogInitializationException
import org.apache.hadoop.hive.common.{HiveInterruptCallback, HiveInterruptUtils, LogUtils}
Expand Down Expand Up @@ -118,17 +116,13 @@ private[hive] object SparkSQLCLIDriver {
SessionState.start(sessionState)

// Clean up after we exit
/**
* This should be executed before shutdown hook of
* FileSystem to avoid race condition of FileSystem operation
*/
ShutdownHookManager.get.addShutdownHook(
Runtime.getRuntime.addShutdownHook(
new Thread() {
override def run() {
SparkSQLEnv.stop()
}
}
, FileSystem.SHUTDOWN_HOOK_PRIORITY - 1)
)

// "-h" option has been passed, so connect to Hive thrift server.
if (sessionState.getHost != null) {
Expand Down

0 comments on commit ff10c53

Please sign in to comment.