camel-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From davscl...@apache.org
Subject [2/2] camel git commit: CAMEL-11390: Fixed camel-maven-plugin:validate to not download camel-catalog if turned off.
Date Fri, 09 Jun 2017 08:07:39 GMT
CAMEL-11390: Fixed camel-maven-plugin:validate to not download camel-catalog if turned off.


Project: http://git-wip-us.apache.org/repos/asf/camel/repo
Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/2a3dd76c
Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/2a3dd76c
Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/2a3dd76c

Branch: refs/heads/camel-2.19.x
Commit: 2a3dd76c54d52507fa40e7e8a9bcca047d281960
Parents: 3e4c782
Author: Claus Ibsen <davsclaus@apache.org>
Authored: Fri Jun 9 10:06:57 2017 +0200
Committer: Claus Ibsen <davsclaus@apache.org>
Committed: Fri Jun 9 10:07:32 2017 +0200

----------------------------------------------------------------------
 .../java/org/apache/camel/maven/ValidateMojo.java    | 15 +++++++--------
 1 file changed, 7 insertions(+), 8 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/camel/blob/2a3dd76c/tooling/maven/camel-maven-plugin/src/main/java/org/apache/camel/maven/ValidateMojo.java
----------------------------------------------------------------------
diff --git a/tooling/maven/camel-maven-plugin/src/main/java/org/apache/camel/maven/ValidateMojo.java
b/tooling/maven/camel-maven-plugin/src/main/java/org/apache/camel/maven/ValidateMojo.java
index 3c8eca2..e217dd9 100644
--- a/tooling/maven/camel-maven-plugin/src/main/java/org/apache/camel/maven/ValidateMojo.java
+++ b/tooling/maven/camel-maven-plugin/src/main/java/org/apache/camel/maven/ValidateMojo.java
@@ -173,6 +173,11 @@ public class ValidateMojo extends AbstractExecMojo {
         // enable caching
         catalog.enableCache();
 
+        String detectedVersion = findCamelVersion(project);
+        if (detectedVersion != null) {
+            getLog().info("Detected Camel version used in project: " + detectedVersion);
+        }
+
         if (downloadVersion) {
             String catalogVersion = catalog.getCatalogVersion();
             String version = findCamelVersion(project);
@@ -186,16 +191,10 @@ public class ValidateMojo extends AbstractExecMojo {
             }
         }
 
-        // if using the same version as the camel-maven-plugin we must still load it
-        if (catalog.getLoadedVersion() == null) {
-            catalog.loadVersion(catalog.getCatalogVersion());
-        }
-
         if (catalog.getLoadedVersion() != null) {
-            getLog().info("Using Camel version: " + catalog.getLoadedVersion());
+            getLog().info("Validating using downloaded Camel version: " + catalog.getLoadedVersion());
         } else {
-            // force load version from the camel-maven-plugin
-            getLog().info("Using Camel version: " + catalog.getCatalogVersion());
+            getLog().info("Validating using Camel version: " + catalog.getCatalogVersion());
         }
 
         List<CamelEndpointDetails> endpoints = new ArrayList<>();


Mime
View raw message