geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sppa...@apache.org
Subject svn commit: r464514 - in /geronimo/devtools/eclipse-plugin/trunk/plugins: org.apache.geronimo.st.v1.core/src/org/apache/geronimo/st/v1/core/ org.apache.geronimo.st.v11.core/src/org/apache/geronimo/st/v11/core/
Date Mon, 16 Oct 2006 15:12:52 GMT
Author: sppatel
Date: Mon Oct 16 08:12:47 2006
New Revision: 464514

URL: http://svn.apache.org/viewvc?view=rev&rev=464514
Log:
GERONIMODEVTOOLS-110 fix internalKernelException on IModulePublishHelper.getPublishDirectory()

Modified:
    geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v1.core/src/org/apache/geronimo/st/v1/core/GeronimoServerBehaviour.java
    geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v11.core/src/org/apache/geronimo/st/v11/core/GeronimoServerBehaviour.java

Modified: geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v1.core/src/org/apache/geronimo/st/v1/core/GeronimoServerBehaviour.java
URL: http://svn.apache.org/viewvc/geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v1.core/src/org/apache/geronimo/st/v1/core/GeronimoServerBehaviour.java?view=diff&rev=464514&r1=464513&r2=464514
==============================================================================
--- geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v1.core/src/org/apache/geronimo/st/v1/core/GeronimoServerBehaviour.java
(original)
+++ geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v1.core/src/org/apache/geronimo/st/v1/core/GeronimoServerBehaviour.java
Mon Oct 16 08:12:47 2006
@@ -149,8 +149,10 @@
 	public IPath getPublishDirectory(IModule[] module) {
 		if (module == null || module.length == 0)
 			return null;
-
+		
+		ClassLoader old = Thread.currentThread().getContextClassLoader();
 		try {
+			Thread.currentThread().setContextClassLoader(getContextClassLoader());
 			String configId = getConfigId(module[0]);
 			ObjectName on = Configuration.getConfigurationObjectName(URI.create(configId));
 			GBeanData data = kernel.getGBeanData(on);
@@ -162,6 +164,8 @@
 			e.printStackTrace();
 		} catch (InternalKernelException e) {
 			e.printStackTrace();
+		} finally {
+			Thread.currentThread().setContextClassLoader(old);
 		}
 
 		return null;

Modified: geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v11.core/src/org/apache/geronimo/st/v11/core/GeronimoServerBehaviour.java
URL: http://svn.apache.org/viewvc/geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v11.core/src/org/apache/geronimo/st/v11/core/GeronimoServerBehaviour.java?view=diff&rev=464514&r1=464513&r2=464514
==============================================================================
--- geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v11.core/src/org/apache/geronimo/st/v11/core/GeronimoServerBehaviour.java
(original)
+++ geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v11.core/src/org/apache/geronimo/st/v11/core/GeronimoServerBehaviour.java
Mon Oct 16 08:12:47 2006
@@ -153,7 +153,9 @@
 			// container should be returned
 			return module[module.length - 1].getProject().getLocation();
 		} else {
+			ClassLoader old = Thread.currentThread().getContextClassLoader();
 			try {
+				Thread.currentThread().setContextClassLoader(getContextClassLoader());
 				String configId = getConfigId(module[0]);
 				Artifact artifact = Artifact.create(configId);
 				AbstractName name = Configuration.getConfigurationAbstractName(artifact);
@@ -166,6 +168,8 @@
 				e.printStackTrace();
 			} catch (InternalKernelException e) {
 				e.printStackTrace();
+			} finally {
+				Thread.currentThread().setContextClassLoader(old);
 			}
 		}
 



Mime
View raw message