Class StatusConfiguration
java.lang.Object
org.apache.logging.log4j.core.config.status.StatusConfiguration
Configuration for setting up the
StatusLogger
fallback listener.-
Nested Class Summary
Modifier and TypeClassDescriptionstatic enum
Deprecated.This class is not used anymore and only kept for binary backward compatibility. -
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
Deprecated.UseStatusLogger.getLogger()
and thenAbstractLogger.error(String)
instead.void
Configures and initializes the StatusLogger using the configured options in this instance.withDestination
(String destination) Sets the output of theStatusLogger
fallback listener.withStatus
(String level) Sets the level of theStatusLogger
fallback listener.withStatus
(Level level) Sets the level of theStatusLogger
fallback listener.withVerboseClasses
(String... verboseClasses) Deprecated.This method is ineffective and only kept for binary backward compatibility.withVerbosity
(String verbosity) Deprecated.This method is ineffective and only kept for binary backward compatibility.
-
Constructor Details
-
StatusConfiguration
public StatusConfiguration()
-
-
Method Details
-
error
Deprecated.UseStatusLogger.getLogger()
and thenAbstractLogger.error(String)
instead.Logs an error message to theStatusLogger
.- Parameters:
message
- error message to log
-
withDestination
Sets the output of theStatusLogger
fallback listener.Accepted values are as follows:
out
(i.e.,System.out
)err
(i.e.,System.err
)- a URI (e.g.,
file:///path/to/log4j-status-logs.txt
)
Invalid values will be ignored.
- Parameters:
destination
- destination whereStatusLogger
messages should be output- Returns:
this
-
withStatus
Sets the level of theStatusLogger
fallback listener.- Parameters:
level
- a level name- Returns:
this
-
withStatus
Sets the level of theStatusLogger
fallback listener.- Parameters:
level
- a level- Returns:
this
-
withVerbosity
Deprecated.This method is ineffective and only kept for binary backward compatibility.Specifies the verbosity level to log at. This only applies to classes configured byverboseClasses
.- Parameters:
verbosity
- basic filter for status logger messages.- Returns:
this
-
withVerboseClasses
Deprecated.This method is ineffective and only kept for binary backward compatibility.Specifies which class names to filter if the configured verbosity level is QUIET.- Parameters:
verboseClasses
- names of classes to filter if not using VERBOSE.- Returns:
this
-
initialize
public void initialize()Configures and initializes the StatusLogger using the configured options in this instance.
-