Package io.dropwizard.servlets.tasks
Class LogConfigurationTask
- java.lang.Object
-
- io.dropwizard.servlets.tasks.Task
-
- io.dropwizard.servlets.tasks.LogConfigurationTask
-
public class LogConfigurationTask extends Task
Sets the logging level for a number of loggersParameters:
Name Description logger One or more logger names to be configured with the specified log level. level An optional Level
to configure. If not provided, the log level will be set to null.
-
-
Constructor Summary
Constructors Constructor Description LogConfigurationTask()
Creates a new LogConfigurationTask.LogConfigurationTask(org.slf4j.ILoggerFactory loggerContext)
Creates a new LogConfigurationTask with the givenILoggerFactory
instance.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
execute(com.google.common.collect.ImmutableMultimap<String,String> parameters, PrintWriter output)
Executes the task.
-
-
-
Constructor Detail
-
LogConfigurationTask
public LogConfigurationTask()
Creates a new LogConfigurationTask.
-
LogConfigurationTask
public LogConfigurationTask(org.slf4j.ILoggerFactory loggerContext)
Creates a new LogConfigurationTask with the givenILoggerFactory
instance. UseLogConfigurationTask()
instead.- Parameters:
loggerContext
- aILoggerFactory
instance
-
-
Method Detail
-
execute
public void execute(com.google.common.collect.ImmutableMultimap<String,String> parameters, PrintWriter output) throws Exception
Description copied from class:Task
Executes the task.- Specified by:
execute
in classTask
- Parameters:
parameters
- the query string parametersoutput
- aPrintWriter
wrapping the output stream of the task- Throws:
Exception
- if something goes wrong
-
-