tomee-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rmannibu...@apache.org
Subject tomee git commit: don't use auto resolution in local mode
Date Thu, 08 Jan 2015 18:04:39 GMT
Repository: tomee
Updated Branches:
  refs/heads/develop 22985def0 -> 361f7fbca


don't use auto resolution in local mode


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

Branch: refs/heads/develop
Commit: 361f7fbcacb93286ef6747059c66f7e2f6b93b81
Parents: 22985de
Author: Romain Manni-Bucau <rmannibucau@apache.org>
Authored: Thu Jan 8 19:04:27 2015 +0100
Committer: Romain Manni-Bucau <rmannibucau@apache.org>
Committed: Thu Jan 8 19:04:27 2015 +0100

----------------------------------------------------------------------
 .../org/apache/openejb/loader/provisining/MavenResolver.java     | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/tomee/blob/361f7fbc/container/openejb-loader/src/main/java/org/apache/openejb/loader/provisining/MavenResolver.java
----------------------------------------------------------------------
diff --git a/container/openejb-loader/src/main/java/org/apache/openejb/loader/provisining/MavenResolver.java
b/container/openejb-loader/src/main/java/org/apache/openejb/loader/provisining/MavenResolver.java
index 033320e..6b40539 100644
--- a/container/openejb-loader/src/main/java/org/apache/openejb/loader/provisining/MavenResolver.java
+++ b/container/openejb-loader/src/main/java/org/apache/openejb/loader/provisining/MavenResolver.java
@@ -150,7 +150,7 @@ public class MavenResolver implements ArchiveResolver, ProvisioningResolverAware
 
         String base = snapshotBase == null || snapshotBase.isEmpty() ? "" : (snapshotBase
+ (!snapshotBase.endsWith("/") ? "/" : ""));
 
-        if ("LATEST".equals(version) || "LATEST-SNAPSHOT".equals(version)) {
+        if (("LATEST".equals(version) || "LATEST-SNAPSHOT".equals(version)) && base.startsWith("http"))
{
             final String meta = base + group + "/" + artifact + "/maven-metadata.xml";
             final URL url = new URL(meta);
             final ByteArrayOutputStream out = new ByteArrayOutputStream();
@@ -170,7 +170,7 @@ public class MavenResolver implements ArchiveResolver, ProvisioningResolverAware
         }
 
         String artifactVersion;
-        if (version.endsWith("-SNAPSHOT")) {
+        if (version.endsWith("-SNAPSHOT") && base.startsWith("http")) {
             final String meta = base + group + "/" + artifact + "/" + version + "/maven-metadata.xml";
             final URL url = new URL(meta);
             final ByteArrayOutputStream out = new ByteArrayOutputStream();


Mime
View raw message