From f258b373610cad2743c12d723968621265012e25 Mon Sep 17 00:00:00 2001 From: gjoranv Date: Mon, 9 May 2022 17:57:24 +0200 Subject: Reapply setup of vespalog in jdisc_core (#22509) Revert "Merge pull request #22515 from vespa-engine/revert-22509-setup-vespalog-in-jdisc_core" --- jdisc_core/src/main/java/com/yahoo/jdisc/core/ApplicationLoader.java | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'jdisc_core/src/main/java/com/yahoo/jdisc/core') diff --git a/jdisc_core/src/main/java/com/yahoo/jdisc/core/ApplicationLoader.java b/jdisc_core/src/main/java/com/yahoo/jdisc/core/ApplicationLoader.java index 952e8dd5f00..601a96da24d 100644 --- a/jdisc_core/src/main/java/com/yahoo/jdisc/core/ApplicationLoader.java +++ b/jdisc_core/src/main/java/com/yahoo/jdisc/core/ApplicationLoader.java @@ -16,6 +16,8 @@ import com.yahoo.jdisc.application.OsgiHeader; import com.yahoo.jdisc.service.ContainerNotReadyException; import com.yahoo.jdisc.service.CurrentContainer; import com.yahoo.jdisc.statistics.ContainerWatchdogMetrics; +import com.yahoo.log.impl.InitializeLog; +import com.yahoo.log.LogSetup; import org.osgi.framework.Bundle; import org.osgi.framework.BundleContext; import org.osgi.framework.BundleException; @@ -46,6 +48,7 @@ public class ApplicationLoader implements BootstrapLoader, ContainerActivator, C private ApplicationInUseTracker applicationInUseTracker; public ApplicationLoader(OsgiFramework osgiFramework, Iterable guiceModules) { + InitializeLog.init(); this.osgiFramework = osgiFramework; this.guiceModules.install(new ApplicationEnvironmentModule(this)); this.guiceModules.installAll(guiceModules); @@ -198,6 +201,7 @@ public class ApplicationLoader implements BootstrapLoader, ContainerActivator, C try { watchdog.close(); osgiFramework.stop(); + LogSetup.cleanup(); } catch (BundleException | InterruptedException e) { e.printStackTrace(); } -- cgit v1.2.3