tomee-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rmannibu...@apache.org
Subject tomee git commit: explicitely reset or not load set of url
Date Thu, 04 Dec 2014 18:19:14 GMT
Repository: tomee
Updated Branches:
  refs/heads/tomee-1.7.x 4b7538493 -> 16683d6da


explicitely reset or not load set of url


Project: http://git-wip-us.apache.org/repos/asf/tomee/repo
Commit: http://git-wip-us.apache.org/repos/asf/tomee/commit/16683d6d
Tree: http://git-wip-us.apache.org/repos/asf/tomee/tree/16683d6d
Diff: http://git-wip-us.apache.org/repos/asf/tomee/diff/16683d6d

Branch: refs/heads/tomee-1.7.x
Commit: 16683d6dac003b67bf40b34087165307c057de57
Parents: 4b75384
Author: Romain Manni-Bucau <rmannibucau@apache.org>
Authored: Thu Dec 4 19:19:02 2014 +0100
Committer: Romain Manni-Bucau <rmannibucau@apache.org>
Committed: Thu Dec 4 19:19:02 2014 +0100

----------------------------------------------------------------------
 .../src/main/java/org/apache/openejb/Extensions.java           | 4 ++--
 .../java/org/apache/openejb/assembler/classic/Assembler.java   | 4 ++--
 .../java/org/apache/openejb/config/ConfigurationFactory.java   | 6 +++---
 3 files changed, 7 insertions(+), 7 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/tomee/blob/16683d6d/container/openejb-core/src/main/java/org/apache/openejb/Extensions.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/Extensions.java b/container/openejb-core/src/main/java/org/apache/openejb/Extensions.java
index 9b6a85a..25bbe86 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/Extensions.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/Extensions.java
@@ -104,9 +104,9 @@ public final class Extensions {
     }
 
     public static class Finder extends ResourceFinder {
-        public Finder(final String path, final URL... urls) {
+        public Finder(final String path, final boolean useLoader, final URL... urls) {
             super(path, urls);
-            if (urls == null || urls.length == 0) {
+            if (!useLoader && (urls == null || urls.length == 0)) {
                 Reflections.set(this, "urls", new URL[0]);
             }
         }

http://git-wip-us.apache.org/repos/asf/tomee/blob/16683d6d/container/openejb-core/src/main/java/org/apache/openejb/assembler/classic/Assembler.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/assembler/classic/Assembler.java
b/container/openejb-core/src/main/java/org/apache/openejb/assembler/classic/Assembler.java
index 011b33b..7c431e5 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/assembler/classic/Assembler.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/assembler/classic/Assembler.java
@@ -325,14 +325,14 @@ public class Assembler extends AssemblerTool implements org.apache.openejb.spi.A
     private void installExtensions() {
         try {
             final Collection<URL> urls = NewLoaderLogic.applyBuiltinExcludes(new UrlSet(Assembler.class.getClassLoader()).excludeJvm()).getUrls();
-            Extensions.installExtensions(new Extensions.Finder("META-INF", urls.toArray(new
URL[urls.size()])));
+            Extensions.installExtensions(new Extensions.Finder("META-INF", false, urls.toArray(new
URL[urls.size()])));
             return;
         } catch (final IOException e) {
             // no-op
         }
 
         // if an error occurred do it brutely
-        Extensions.installExtensions(new Extensions.Finder("META-INF"));
+        Extensions.installExtensions(new Extensions.Finder("META-INF", true));
     }
 
     private void setConfiguration(final OpenEjbConfiguration config) {

http://git-wip-us.apache.org/repos/asf/tomee/blob/16683d6d/container/openejb-core/src/main/java/org/apache/openejb/config/ConfigurationFactory.java
----------------------------------------------------------------------
diff --git a/container/openejb-core/src/main/java/org/apache/openejb/config/ConfigurationFactory.java
b/container/openejb-core/src/main/java/org/apache/openejb/config/ConfigurationFactory.java
index b23f9d0..678cc2e 100644
--- a/container/openejb-core/src/main/java/org/apache/openejb/config/ConfigurationFactory.java
+++ b/container/openejb-core/src/main/java/org/apache/openejb/config/ConfigurationFactory.java
@@ -928,7 +928,7 @@ public class ConfigurationFactory implements OpenEjbConfigurationFactory
{
 
         final List<URL> libs = appModule.getAdditionalLibraries();
         if (libs != null && libs.size() > 0) {
-            final Extensions.Finder finder = new Extensions.Finder("META-INF", libs.toArray(new
URL[libs.size()]));
+            final Extensions.Finder finder = new Extensions.Finder("META-INF", false, libs.toArray(new
URL[libs.size()]));
             extensions.addAll(Extensions.findExtensions(finder));
             notLoaded.addAll(finder.getResourcesNotLoaded());
         }
@@ -938,7 +938,7 @@ public class ConfigurationFactory implements OpenEjbConfigurationFactory
{
                 if (uri.isAbsolute()) {
                     final URL url = uri.toURL();
                     if (libs != null && !libs.contains(url)) {
-                        final Extensions.Finder finder = new Extensions.Finder("META-INF",
url);
+                        final Extensions.Finder finder = new Extensions.Finder("META-INF",
false , url);
                         extensions.addAll(Extensions.findExtensions(finder));
                         notLoaded.addAll(finder.getResourcesNotLoaded());
                     }
@@ -954,7 +954,7 @@ public class ConfigurationFactory implements OpenEjbConfigurationFactory
{
         for (final WebModule web : appModule.getWebModules()) {
             final List<URL> webLibs = web.getScannableUrls();
             if (webLibs != null && webLibs.size() > 0) {
-                final Extensions.Finder finder = new Extensions.Finder("META-INF", webLibs.toArray(new
URL[webLibs.size()]));
+                final Extensions.Finder finder = new Extensions.Finder("META-INF", false,
webLibs.toArray(new URL[webLibs.size()]));
                 extensions.addAll(Extensions.findExtensions(finder));
                 notLoaded.addAll(finder.getResourcesNotLoaded());
             }


Mime
View raw message