Package org.apache.activemq.broker.jmx
Interface Log4JConfigViewMBean
-
- All Known Implementing Classes:
Log4JConfigView
public interface Log4JConfigViewMBean
Log4J Configuration Management MBean used to alter the runtime log levels or force a reload of the Log4J configuration file.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description List<String>
getLoggers()
list of all the logger names and their levelsString
getLogLevel(String loggerName)
Get the log level for a given loggerString
getRootLogLevel()
Get the log level for the root loggervoid
reloadLog4jProperties()
Reloads log4j.properties from the classpath.void
setLogLevel(String loggerName, String level)
Set the log level for a given loggervoid
setRootLogLevel(String level)
Get the log level for the root logger
-
-
-
Method Detail
-
getRootLogLevel
String getRootLogLevel() throws Exception
Get the log level for the root logger- Throws:
Exception
- if an error occurs while getting the root level.
-
setRootLogLevel
void setRootLogLevel(String level) throws Exception
Get the log level for the root logger- Parameters:
level
- the new level to assign to the root logger.- Throws:
Exception
- if an error occurs while setting the root level.
-
getLoggers
List<String> getLoggers() throws Exception
list of all the logger names and their levels- Returns:
- a List of all known loggers names.
- Throws:
Exception
- if an error occurs while getting the loggers.
-
getLogLevel
String getLogLevel(String loggerName) throws Exception
Get the log level for a given logger- Parameters:
loggerName
- the name of the logger whose level should be queried.- Returns:
- the current log level of the given logger.
- Throws:
Exception
- if an error occurs while getting the log level.
-
setLogLevel
void setLogLevel(String loggerName, String level) throws Exception
Set the log level for a given logger- Parameters:
loggerName
- the name of the logger whose level is to be adjusted.level
- the new level to assign the given logger.- Throws:
Exception
- if an error occurs while setting the log level.
-
-