本文整理匯總了Java中org.slf4j.bridge.SLF4JBridgeHandler.uninstall方法的典型用法代碼示例。如果您正苦於以下問題:Java SLF4JBridgeHandler.uninstall方法的具體用法?Java SLF4JBridgeHandler.uninstall怎麽用?Java SLF4JBridgeHandler.uninstall使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類org.slf4j.bridge.SLF4JBridgeHandler
的用法示例。
在下文中一共展示了SLF4JBridgeHandler.uninstall方法的13個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: initialize
import org.slf4j.bridge.SLF4JBridgeHandler; //導入方法依賴的package包/類
/**
* Initialize Logging
*
* @param isClient client
*/
public static void initialize(final boolean isClient)
{
if (s_initialized.getAndSet(true))
{
return;
}
//
// Forward all logs from JUL to SLF4J
{
SLF4JBridgeHandler.uninstall();
SLF4JBridgeHandler.install();
}
if (isClient)
{
// FRESH-267: in server mode, do not (re)set the loglevels. They are coming out of logback.xml and/or application properties and were probably fine-tuned.
// resetting them to info might cause the disk to run full.
setLevel(Level.INFO);
}
}
示例2: execute
import org.slf4j.bridge.SLF4JBridgeHandler; //導入方法依賴的package包/類
@Override
public void execute() throws MojoFailureException, MojoExecutionException {
SLF4JBridgeHandler.install();
List<CarnotzetExtension> runtimeExtensions = findRuntimeExtensions();
CarnotzetModuleCoordinates coordinates =
new CarnotzetModuleCoordinates(project.getGroupId(), project.getArtifactId(), project.getVersion());
if (instanceId == null) {
instanceId = Carnotzet.getModuleName(coordinates, Pattern.compile(CarnotzetConfig.DEFAULT_MODULE_FILTER_PATTERN),
Pattern.compile(CarnotzetConfig.DEFAULT_CLASSIFIER_INCLUDE_PATTERN));
}
Path resourcesPath = Paths.get(project.getBuild().getDirectory(), "carnotzet");
if (SystemUtils.IS_OS_WINDOWS) {
// we avoid using ${project.build.directory} because "mvn clean" when the sandbox is running would try to delete mounted files,
// which is not supported on Windows.
resourcesPath = Paths.get("/var/tmp/carnotzet_" + instanceId);
}
CarnotzetConfig config = CarnotzetConfig.builder()
.topLevelModuleId(coordinates)
.resourcesPath(resourcesPath)
.topLevelModuleResourcesPath(project.getBasedir().toPath().resolve("src/main/resources"))
.failOnDependencyCycle(failOnDependencyCycle)
.extensions(runtimeExtensions)
.build();
carnotzet = new Carnotzet(config);
if (bindLocalPorts == null) {
bindLocalPorts = !SystemUtils.IS_OS_LINUX;
}
runtime = new DockerComposeRuntime(carnotzet, instanceId, DefaultCommandRunner.INSTANCE, bindLocalPorts);
executeInternal();
SLF4JBridgeHandler.uninstall();
}
示例3: tearDown
import org.slf4j.bridge.SLF4JBridgeHandler; //導入方法依賴的package包/類
@After
public void tearDown() throws Exception {
// restore
Logger.getRootLogger().removeAllAppenders();
for (Appender appender : appenders) {
Logger.getRootLogger().addAppender(appender);
}
SLF4JBridgeHandler.uninstall();
}
示例4: destroy
import org.slf4j.bridge.SLF4JBridgeHandler; //導入方法依賴的package包/類
@Override
public void destroy() {
super.destroy();
try {
SLF4JBridgeHandler.uninstall();
} catch (Exception e) {
}
if (this.contextLoader != null) {
this.contextLoader.closeWebApplicationContext(getServletContext());
}
}
示例5: stop
import org.slf4j.bridge.SLF4JBridgeHandler; //導入方法依賴的package包/類
@Override
public void stop( BundleContext context ) throws Exception
{
SLF4JBridgeHandler.uninstall();
}
開發者ID:jitsi,項目名稱:jitsi-videobridge-openfire-plugin,代碼行數:6,代碼來源:SLF4JBridgeHandlerBundleActivator.java
示例6: destroy
import org.slf4j.bridge.SLF4JBridgeHandler; //導入方法依賴的package包/類
public void destroy() {
SLF4JBridgeHandler.uninstall();
}
示例7: uninstallSLF4JBridge
import org.slf4j.bridge.SLF4JBridgeHandler; //導入方法依賴的package包/類
static public void uninstallSLF4JBridge() {
SLF4JBridgeHandler.uninstall();
}
示例8: uninstallLogback
import org.slf4j.bridge.SLF4JBridgeHandler; //導入方法依賴的package包/類
public static void uninstallLogback() {
if (SLF4JBridgeHandler.isInstalled()) SLF4JBridgeHandler.uninstall();
}
示例9: stop
import org.slf4j.bridge.SLF4JBridgeHandler; //導入方法依賴的package包/類
@Override
public void stop(BundleContext ctx) {
SLF4JBridgeHandler.uninstall();
}
示例10: unassimilate
import org.slf4j.bridge.SLF4JBridgeHandler; //導入方法依賴的package包/類
/**
* Try to unassimilate the logging frameworks.
*/
public static synchronized void unassimilate()
{
SLF4JBridgeHandler.uninstall();
}
示例11: stop
import org.slf4j.bridge.SLF4JBridgeHandler; //導入方法依賴的package包/類
@Override
public void stop(BundleContext context) throws Exception {
SLF4JBridgeHandler.uninstall();
}
示例12: contextDestroyed
import org.slf4j.bridge.SLF4JBridgeHandler; //導入方法依賴的package包/類
@Override
public void contextDestroyed(final ServletContextEvent sce)
{
SLF4JBridgeHandler.uninstall();
}
示例13: tearDownClass
import org.slf4j.bridge.SLF4JBridgeHandler; //導入方法依賴的package包/類
/**
* Uninstalls the SLF4J-JUL bridge and returns JUL logging to its original
* level.
*/
@AfterClass
public static void tearDownClass() {
SLF4JBridgeHandler.uninstall();
java.util.logging.Logger.getLogger("").setLevel(originalLevel);
}