Package org.apache.hadoop.hbase.logging
Class Log4jUtils
java.lang.Object
org.apache.hadoop.hbase.logging.Log4jUtils
A bridge class for operating on log4j, such as changing log level, etc.
Will call the methods in
InternalLog4jUtils
to actually operate on the log4j stuff.-
Field Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic void
Disables Zk- and HBase client loggingstatic void
enableDebug
(Class<?> clazz) Switches the logger for the given class to DEBUG level.static String
getEffectiveLevel
(String loggerName) private static Method
private static void
static void
setAllLevels
(String loggerName, String levelName) static void
setLogLevel
(String loggerName, String levelName) static void
setRootLevel
(String levelName) private static void
throwUnchecked
(Throwable throwable)
-
Field Details
-
INTERNAL_UTILS_CLASS_NAME
- See Also:
-
-
Constructor Details
-
Log4jUtils
private Log4jUtils()
-
-
Method Details
-
getMethod
-
throwUnchecked
-
invoke
- Throws:
AssertionError
-
setAllLevels
-
setLogLevel
-
setRootLevel
-
getEffectiveLevel
-
getActiveLogFiles
- Throws:
IOException
-
disableZkAndClientLoggers
Disables Zk- and HBase client logging -
enableDebug
Switches the logger for the given class to DEBUG level.- Parameters:
clazz
- The class for which to switch to debug logging.
-