@Override
    public boolean removeShutdownHook(Runnable shutdownHook) {
      Thread shutdownHookThread = null;
      if (!(shutdownHook instanceof Thread)) {
        shutdownHookThread = new Thread(shutdownHook);
      } else shutdownHookThread = (Thread) shutdownHook;

      return Runtime.getRuntime().removeShutdownHook(shutdownHookThread);
    }
This class provides ShutdownHookManager shims for HBase to interact with the Hadoop 1.0.x and the
Hadoop 2.0+ series. NOTE: No testing done against 0.22.x, or 0.21.x.
hbase-server/src/main/java/org/apache/hadoop/hbase/util/ShutdownHookManager.java