[camel] branch master updated: [CAMEL-13177] Improve build speed - do not rewrite velocity generated files

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

[camel] branch master updated: [CAMEL-13177] Improve build speed - do not rewrite velocity generated files

davsclaus-2
This is an automated email from the ASF dual-hosted git repository.

davsclaus pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/camel.git


The following commit(s) were added to refs/heads/master by this push:
     new 22863e3  [CAMEL-13177] Improve build speed - do not rewrite velocity generated files
22863e3 is described below

commit 22863e3868768ec6b12e400b0ef93d0180b7399c
Author: Claus Ibsen <[hidden email]>
AuthorDate: Tue Feb 12 07:50:52 2019 +0100

    [CAMEL-13177] Improve build speed - do not rewrite velocity generated files
---
 .../src/main/java/org/apache/camel/maven/GenerateMojo.java          | 6 ++----
 .../java/org/apache/camel/maven/CamelSalesforceMojoOutputTest.java  | 3 +--
 .../src/test/resources/generated/Asset.java                         | 1 -
 .../src/test/resources/generated/Asset_LocalDateTime.java           | 1 -
 .../src/test/resources/generated/Case.java                          | 1 -
 .../src/test/resources/generated/Case.java-Java9                    | 1 -
 .../src/test/resources/generated/Case_PickListAccentMarkEnum.java   | 1 -
 .../test/resources/generated/Case_PickListQuotationMarkEnum.java    | 1 -
 .../src/test/resources/generated/Case_PickListSlashEnum.java        | 1 -
 .../src/test/resources/generated/ComplexCalculatedFormula.java      | 1 -
 .../test/resources/generated/ComplexCalculatedFormula.java-Java9    | 1 -
 .../src/test/resources/generated/QueryRecordsCase.java              | 1 -
 .../resources/generated/QueryRecordsComplexCalculatedFormula.java   | 1 -
 .../src/test/resources/generated/With_External_Id__c_Lookup.java    | 1 -
 .../src/test/resources/generated/With_Reference__c.java             | 1 -
 15 files changed, 3 insertions(+), 19 deletions(-)

diff --git a/components/camel-salesforce/camel-salesforce-maven-plugin/src/main/java/org/apache/camel/maven/GenerateMojo.java b/components/camel-salesforce/camel-salesforce-maven-plugin/src/main/java/org/apache/camel/maven/GenerateMojo.java
index 2c7ad92..69158d6 100644
--- a/components/camel-salesforce/camel-salesforce-maven-plugin/src/main/java/org/apache/camel/maven/GenerateMojo.java
+++ b/components/camel-salesforce/camel-salesforce-maven-plugin/src/main/java/org/apache/camel/maven/GenerateMojo.java
@@ -338,8 +338,7 @@ public class GenerateMojo extends AbstractSalesforceMojo {
     @Parameter(property = "camelSalesforce.useStringsForPicklists", defaultValue = "false")
     private Boolean useStringsForPicklists;
 
-    void processDescription(final File pkgDir, final SObjectDescription description, final GeneratorUtility utility,
-        final String generatedDate) throws IOException {
+    void processDescription(final File pkgDir, final SObjectDescription description, final GeneratorUtility utility) throws IOException {
 
         // generate a source file for SObject
         final VelocityContext context = new VelocityContext();
@@ -347,7 +346,6 @@ public class GenerateMojo extends AbstractSalesforceMojo {
         context.put("utility", utility);
         context.put("esc", StringEscapeUtils.class);
         context.put("desc", description);
-        context.put("generatedDate", generatedDate);
         context.put("useStringsForPicklists", useStringsForPicklists);
 
         final String pojoFileName = description.getName() + JAVA_EXT;
@@ -483,7 +481,7 @@ public class GenerateMojo extends AbstractSalesforceMojo {
                 continue;
             }
             try {
-                processDescription(pkgDir, description, utility, generatedDate);
+                processDescription(pkgDir, description, utility);
             } catch (final IOException e) {
                 throw new MojoExecutionException("Unable to generate source files for: " + description.getName(), e);
             }
diff --git a/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/java/org/apache/camel/maven/CamelSalesforceMojoOutputTest.java b/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/java/org/apache/camel/maven/CamelSalesforceMojoOutputTest.java
index 55d350f..45098ed 100644
--- a/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/java/org/apache/camel/maven/CamelSalesforceMojoOutputTest.java
+++ b/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/java/org/apache/camel/maven/CamelSalesforceMojoOutputTest.java
@@ -54,7 +54,6 @@ import static org.mockito.Mockito.mock;
 
 @RunWith(Parameterized.class)
 public class CamelSalesforceMojoOutputTest {
-    private static final String FIXED_DATE = "Thu Mar 09 16:15:49 ART 2017";
     private static final String TEST_CALCULATED_FORMULA_FILE = "complex_calculated_formula.json";
     private static final String TEST_CASE_FILE = "case.json";
 
@@ -86,7 +85,7 @@ public class CamelSalesforceMojoOutputTest {
 
         mojo.descriptions = new ObjectDescriptions(client, 0, null, null, null, null, mojo.getLog());
 
-        mojo.processDescription(pkgDir, description, utility, FIXED_DATE);
+        mojo.processDescription(pkgDir, description, utility);
 
         for (final String source : sources) {
             String expected = fileNameAdapter.apply(source);
diff --git a/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/Asset.java b/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/Asset.java
index de25141..0bfdfc3 100644
--- a/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/Asset.java
+++ b/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/Asset.java
@@ -1,6 +1,5 @@
 /*
  * Salesforce DTO generated by camel-salesforce-maven-plugin
- * Generated on: Thu Mar 09 16:15:49 ART 2017
  */
 package $packageName;
 
diff --git a/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/Asset_LocalDateTime.java b/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/Asset_LocalDateTime.java
index 1d9d17a..4a9c546 100644
--- a/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/Asset_LocalDateTime.java
+++ b/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/Asset_LocalDateTime.java
@@ -1,6 +1,5 @@
 /*
  * Salesforce DTO generated by camel-salesforce-maven-plugin
- * Generated on: Thu Mar 09 16:15:49 ART 2017
  */
 package $packageName;
 
diff --git a/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/Case.java b/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/Case.java
index e7f4e12..57e9287 100644
--- a/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/Case.java
+++ b/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/Case.java
@@ -1,6 +1,5 @@
 /*
  * Salesforce DTO generated by camel-salesforce-maven-plugin
- * Generated on: Thu Mar 09 16:15:49 ART 2017
  */
 package $packageName;
 
diff --git a/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/Case.java-Java9 b/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/Case.java-Java9
index 5915eaa..f0f4bf6 100644
--- a/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/Case.java-Java9
+++ b/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/Case.java-Java9
@@ -1,6 +1,5 @@
 /*
  * Salesforce DTO generated by camel-salesforce-maven-plugin
- * Generated on: Thu Mar 09 16:15:49 ART 2017
  */
 package $packageName;
 
diff --git a/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/Case_PickListAccentMarkEnum.java b/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/Case_PickListAccentMarkEnum.java
index 6af6914..7a1f166 100644
--- a/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/Case_PickListAccentMarkEnum.java
+++ b/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/Case_PickListAccentMarkEnum.java
@@ -1,6 +1,5 @@
 /*
  * Salesforce DTO generated by camel-salesforce-maven-plugin
- * Generated on: Thu Mar 09 16:15:49 ART 2017
  */
 package $packageName;
 
diff --git a/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/Case_PickListQuotationMarkEnum.java b/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/Case_PickListQuotationMarkEnum.java
index 7719fa2..1f8d7ea 100644
--- a/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/Case_PickListQuotationMarkEnum.java
+++ b/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/Case_PickListQuotationMarkEnum.java
@@ -1,6 +1,5 @@
 /*
  * Salesforce DTO generated by camel-salesforce-maven-plugin
- * Generated on: Thu Mar 09 16:15:49 ART 2017
  */
 package $packageName;
 
diff --git a/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/Case_PickListSlashEnum.java b/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/Case_PickListSlashEnum.java
index 4ad2758..ce9858d 100644
--- a/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/Case_PickListSlashEnum.java
+++ b/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/Case_PickListSlashEnum.java
@@ -1,6 +1,5 @@
 /*
  * Salesforce DTO generated by camel-salesforce-maven-plugin
- * Generated on: Thu Mar 09 16:15:49 ART 2017
  */
 package $packageName;
 
diff --git a/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/ComplexCalculatedFormula.java b/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/ComplexCalculatedFormula.java
index fd6da8a..fade972 100644
--- a/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/ComplexCalculatedFormula.java
+++ b/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/ComplexCalculatedFormula.java
@@ -1,6 +1,5 @@
 /*
  * Salesforce DTO generated by camel-salesforce-maven-plugin
- * Generated on: Thu Mar 09 16:15:49 ART 2017
  */
 package $packageName;
 
diff --git a/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/ComplexCalculatedFormula.java-Java9 b/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/ComplexCalculatedFormula.java-Java9
index 025c5b2..6866395 100644
--- a/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/ComplexCalculatedFormula.java-Java9
+++ b/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/ComplexCalculatedFormula.java-Java9
@@ -1,6 +1,5 @@
 /*
  * Salesforce DTO generated by camel-salesforce-maven-plugin
- * Generated on: Thu Mar 09 16:15:49 ART 2017
  */
 package $packageName;
 
diff --git a/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/QueryRecordsCase.java b/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/QueryRecordsCase.java
index 7b23a8f..1e1a38d 100644
--- a/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/QueryRecordsCase.java
+++ b/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/QueryRecordsCase.java
@@ -1,6 +1,5 @@
 /*
  * Salesforce Query DTO generated by camel-salesforce-maven-plugin
- * Generated on: Thu Mar 09 16:15:49 ART 2017
  */
 package $packageName;
 
diff --git a/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/QueryRecordsComplexCalculatedFormula.java b/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/QueryRecordsComplexCalculatedFormula.java
index 951a70a..d9dcb19 100644
--- a/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/QueryRecordsComplexCalculatedFormula.java
+++ b/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/QueryRecordsComplexCalculatedFormula.java
@@ -1,6 +1,5 @@
 /*
  * Salesforce Query DTO generated by camel-salesforce-maven-plugin
- * Generated on: Thu Mar 09 16:15:49 ART 2017
  */
 package $packageName;
 
diff --git a/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/With_External_Id__c_Lookup.java b/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/With_External_Id__c_Lookup.java
index da90919..bb31ba4 100644
--- a/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/With_External_Id__c_Lookup.java
+++ b/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/With_External_Id__c_Lookup.java
@@ -1,6 +1,5 @@
 /*
  * Salesforce DTO generated by camel-salesforce-maven-plugin
- * Generated on: Thu Mar 09 16:15:49 ART 2017
  */
 package $packageName;
 
diff --git a/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/With_Reference__c.java b/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/With_Reference__c.java
index c5a9dc5..5d8f269 100644
--- a/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/With_Reference__c.java
+++ b/components/camel-salesforce/camel-salesforce-maven-plugin/src/test/resources/generated/With_Reference__c.java
@@ -1,6 +1,5 @@
 /*
  * Salesforce DTO generated by camel-salesforce-maven-plugin
- * Generated on: Thu Mar 09 16:15:49 ART 2017
  */
 package $packageName;