tuscany-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jboy...@apache.org
Subject svn commit: r419891 - /incubator/tuscany/sandbox/jboynes/sca/commands/launcher/src/main/java/org/apache/tuscany/launcher/MainLauncherBooter.java
Date Fri, 07 Jul 2006 13:53:13 GMT
Author: jboynes
Date: Fri Jul  7 06:53:13 2006
New Revision: 419891

URL: http://svn.apache.org/viewvc?rev=419891&view=rev
Log:
do not cache the classloader as this should only be called once

Modified:
    incubator/tuscany/sandbox/jboynes/sca/commands/launcher/src/main/java/org/apache/tuscany/launcher/MainLauncherBooter.java

Modified: incubator/tuscany/sandbox/jboynes/sca/commands/launcher/src/main/java/org/apache/tuscany/launcher/MainLauncherBooter.java
URL: http://svn.apache.org/viewvc/incubator/tuscany/sandbox/jboynes/sca/commands/launcher/src/main/java/org/apache/tuscany/launcher/MainLauncherBooter.java?rev=419891&r1=419890&r2=419891&view=diff
==============================================================================
--- incubator/tuscany/sandbox/jboynes/sca/commands/launcher/src/main/java/org/apache/tuscany/launcher/MainLauncherBooter.java
(original)
+++ incubator/tuscany/sandbox/jboynes/sca/commands/launcher/src/main/java/org/apache/tuscany/launcher/MainLauncherBooter.java
Fri Jul  7 06:53:13 2006
@@ -37,8 +37,6 @@
         }
     };
 
-    protected static ClassLoader tuscanyClassLoader;
-
     /**
      * Main method.
      *
@@ -94,22 +92,19 @@
     }
 
     protected static ClassLoader getTuscanyClassLoader() {
-        if (null == tuscanyClassLoader) {
-            // assume that even though the the rest of tuscany jars are not loaded
-            // it co-located with the rest of the tuscany jars.
-            File tuscanylib = findLoadLocation();
-            String[] jars = tuscanylib.list(FILE_FILTER);
-            String[] urls = new String[jars.length];
-            int i = 0;
-            for (String jar : jars) {
-
-                urls[i++] = tuscanylib.getAbsolutePath() + "/" + jar;
+        // assume that even though the the rest of tuscany jars are not loaded
+        // it co-located with the rest of the tuscany jars.
+        File tuscanylib = findLoadLocation();
+        String[] jars = tuscanylib.list(FILE_FILTER);
+        String[] urls = new String[jars.length];
+        int i = 0;
+        for (String jar : jars) {
 
-            }
+            urls[i++] = tuscanylib.getAbsolutePath() + "/" + jar;
 
-            tuscanyClassLoader = createClassLoader(MainLauncherBooter.class.getClassLoader(),
urls);
         }
-        return tuscanyClassLoader;
+
+        return createClassLoader(MainLauncherBooter.class.getClassLoader(), urls);
     }
 
     protected static File findLoadLocation() {



---------------------------------------------------------------------
To unsubscribe, e-mail: tuscany-commits-unsubscribe@ws.apache.org
For additional commands, e-mail: tuscany-commits-help@ws.apache.org


Mime
View raw message