Github user piaozhexiu commented on a diff in the pull request:

    https://github.com/apache/spark/pull/4771#discussion_r25484558
  
    --- Diff: 
sql/hive-thriftserver/src/main/scala/org/apache/spark/sql/hive/thriftserver/HiveThriftServer2.scala
 ---
    @@ -57,12 +60,15 @@ object HiveThriftServer2 extends Logging {
         logInfo("Starting SparkContext")
         SparkSQLEnv.init()
     
    -    Runtime.getRuntime.addShutdownHook(
    -      new Thread() {
    +    // Clean up after we exit. Use higher priority than FileSystem.
    +    assert(SHUTDOWN_HOOK_PRIORITY > FileSystem.SHUTDOWN_HOOK_PRIORITY)
    --- End diff --
    
    No, it doesn't. In fact, ShutdownHookManager does not exist in Hadoop 1.x. 
So we can't do this, can we? I actually tried to compile Spark with Hadoop 1.x, 
and it failed with the following errors-
    
    -----
    object ShutdownHookManager is not a member of package org.apache.hadoop.util
    value SHUTDOWN_HOOK_PRIORITY is not a member of object 
org.apache.hadoop.fs.FileSystem
    -----
    
    So we're back to ground zero. :(


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to