Package org.apache.flink.util
Class LogLevelExtension
- java.lang.Object
-
- org.apache.flink.util.LogLevelExtension
-
- All Implemented Interfaces:
org.junit.jupiter.api.extension.AfterAllCallback
,org.junit.jupiter.api.extension.BeforeAllCallback
,org.junit.jupiter.api.extension.Extension
public class LogLevelExtension extends Object implements org.junit.jupiter.api.extension.BeforeAllCallback, org.junit.jupiter.api.extension.AfterAllCallback
A extension that sets the log level for specific class/package loggers for a test. Logging configuration will only be extended when logging is enabled at all (so root logger is not OFF).
-
-
Field Summary
Fields Modifier and Type Field Description static boolean
LOGGING_ENABLED
-
Constructor Summary
Constructors Constructor Description LogLevelExtension()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
afterAll(org.junit.jupiter.api.extension.ExtensionContext context)
void
beforeAll(org.junit.jupiter.api.extension.ExtensionContext context)
LogLevelExtension
set(Class<?> clazz, org.slf4j.event.Level level)
LogLevelExtension
set(Package logPackage, org.slf4j.event.Level level)
LogLevelExtension
set(String classOrPackageName, org.slf4j.event.Level level)
-
-
-
Method Detail
-
beforeAll
public void beforeAll(org.junit.jupiter.api.extension.ExtensionContext context) throws Exception
- Specified by:
beforeAll
in interfaceorg.junit.jupiter.api.extension.BeforeAllCallback
- Throws:
Exception
-
afterAll
public void afterAll(org.junit.jupiter.api.extension.ExtensionContext context) throws Exception
- Specified by:
afterAll
in interfaceorg.junit.jupiter.api.extension.AfterAllCallback
- Throws:
Exception
-
set
public LogLevelExtension set(Class<?> clazz, org.slf4j.event.Level level)
-
set
public LogLevelExtension set(Package logPackage, org.slf4j.event.Level level)
-
set
public LogLevelExtension set(String classOrPackageName, org.slf4j.event.Level level)
-
-