Class ServerCommandLine

java.lang.Object
org.apache.hadoop.conf.Configured
org.apache.hadoop.hbase.util.ServerCommandLine
All Implemented Interfaces:
org.apache.hadoop.conf.Configurable, org.apache.hadoop.util.Tool
Direct Known Subclasses:
HMasterCommandLine, HRegionServerCommandLine

@Private public abstract class ServerCommandLine extends org.apache.hadoop.conf.Configured implements org.apache.hadoop.util.Tool
Base class for command lines that start up various HBase daemons.
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    private static final Set<String>
     
    private static final org.slf4j.Logger
     
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    doMain(String[] args)
    Parse and run the given command line.
    protected abstract String
    Implementing subclasses should return a usage string to print out.
    private static void
    logHBaseConfigs(org.apache.hadoop.conf.Configuration conf)
    Print into log some of the important hbase attributes.
    static void
    Log information about the currently running JVM.
    static void
    logProcessInfo(org.apache.hadoop.conf.Configuration conf)
    Logs information about the currently running JVM process including the environment variables.
    protected void
    usage(String message)
    Print usage information for this command line.

    Methods inherited from class org.apache.hadoop.conf.Configured

    getConf, setConf

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

    Methods inherited from interface org.apache.hadoop.conf.Configurable

    getConf, setConf

    Methods inherited from interface org.apache.hadoop.util.Tool

    run
  • Field Details

  • Constructor Details

  • Method Details

    • getUsage

      protected abstract String getUsage()
      Implementing subclasses should return a usage string to print out.
    • usage

      protected void usage(String message)
      Print usage information for this command line.
      Parameters:
      message - if not null, print this message before the usage info.
    • logJVMInfo

      public static void logJVMInfo()
      Log information about the currently running JVM.
    • logHBaseConfigs

      private static void logHBaseConfigs(org.apache.hadoop.conf.Configuration conf)
      Print into log some of the important hbase attributes.
    • logProcessInfo

      public static void logProcessInfo(org.apache.hadoop.conf.Configuration conf)
      Logs information about the currently running JVM process including the environment variables. Logging of env vars can be disabled by setting "hbase.envvars.logging.disabled" to "true".

      If enabled, you can also exclude environment variables containing certain substrings by setting "hbase.envvars.logging.skipwords" to comma separated list of such substrings.

    • doMain

      public void doMain(String[] args)
      Parse and run the given command line. This will exit the JVM with the exit code returned from run(). If return code is 0, wait for atmost 30 seconds for all non-daemon threads to quit, otherwise exit the jvm