changeset 1350:ff5a4032f35f

Fix agent proxy startup issue This patch fixes a bug where the agent proxy cannot start due to the recent addition of the CommonPaths OSGi service. Since the agent proxy is not running under OSGi, CommonPaths is not set in NativeLibraryResolver as it normally is in Thermostat itself. Reviewed-by: omajid Review-thread: http://icedtea.classpath.org/pipermail/thermostat/2013-November/008844.html
author Elliott Baron <ebaron@redhat.com>
date Wed, 20 Nov 2013 12:26:53 -0500
parents f9cc82ff24b6
children b7c6db90e034
files agent/proxy/server/src/main/java/com/redhat/thermostat/agent/proxy/server/AgentProxyNativeUtils.java
diffstat 1 files changed, 3 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/agent/proxy/server/src/main/java/com/redhat/thermostat/agent/proxy/server/AgentProxyNativeUtils.java	Tue Nov 19 19:54:34 2013 -0500
+++ b/agent/proxy/server/src/main/java/com/redhat/thermostat/agent/proxy/server/AgentProxyNativeUtils.java	Wed Nov 20 12:26:53 2013 -0500
@@ -37,10 +37,13 @@
 package com.redhat.thermostat.agent.proxy.server;
 
 import com.redhat.thermostat.shared.config.NativeLibraryResolver;
+import com.redhat.thermostat.shared.config.internal.CommonPathsImpl;
 
 class AgentProxyNativeUtils {
     
     void loadLibrary() {
+        // TODO if this used OSGi, then we wouldn't need this line
+        NativeLibraryResolver.setCommonPaths(new CommonPathsImpl());
         String libPath = NativeLibraryResolver.getAbsoluteLibraryPath("AgentProxy");
         System.load(libPath);
     }