Package org.apache.hadoop.util
Enum Class SignalLogger
- All Implemented Interfaces:
Serializable,Comparable<SignalLogger>,Constable
This class logs a message whenever we're about to exit on a UNIX signal.
This is helpful for determining the root cause of a process' exit.
For example, if the process exited because the system administrator
ran a standard "kill," you would see 'EXITING ON SIGNAL SIGTERM' in the log.
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>> -
Enum Constant Summary
Enum Constants -
Method Summary
Modifier and TypeMethodDescriptionvoidregister(org.slf4j.Logger log) Register some signal handlers.static SignalLoggerReturns the enum constant of this class with the specified name.static SignalLogger[]values()Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
INSTANCE
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum class has no constant with the specified nameNullPointerException- if the argument is null
-
register
public void register(org.slf4j.Logger log) Register some signal handlers.- Parameters:
log- The log4j logfile to use in the signal handlers.
-